]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - lib/Fuzzer/FuzzerOptions.h
Vendor import of llvm trunk r291274:
[FreeBSD/FreeBSD.git] / lib / Fuzzer / FuzzerOptions.h
1 //===- FuzzerOptions.h - Internal header for the Fuzzer ---------*- C++ -* ===//
2 //
3 //                     The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 // fuzzer::FuzzingOptions
10 //===----------------------------------------------------------------------===//
11
12 #ifndef LLVM_FUZZER_OPTIONS_H
13 #define LLVM_FUZZER_OPTIONS_H
14
15 #include "FuzzerDefs.h"
16
17 namespace fuzzer {
18
19 struct FuzzingOptions {
20   int Verbosity = 1;
21   size_t MaxLen = 0;
22   bool ExperimentalLenControl = false;
23   int UnitTimeoutSec = 300;
24   int TimeoutExitCode = 77;
25   int ErrorExitCode = 77;
26   int MaxTotalTimeSec = 0;
27   int RssLimitMb = 0;
28   bool DoCrossOver = true;
29   int MutateDepth = 5;
30   bool UseCounters = false;
31   bool UseIndirCalls = true;
32   bool UseMemcmp = true;
33   bool UseMemmem = true;
34   bool UseCmp = false;
35   bool UseValueProfile = false;
36   bool Shrink = false;
37   int ReloadIntervalSec = 1;
38   bool ShuffleAtStartUp = true;
39   bool PreferSmall = true;
40   size_t MaxNumberOfRuns = -1L;
41   int ReportSlowUnits = 10;
42   bool OnlyASCII = false;
43   std::string OutputCorpus;
44   std::string ArtifactPrefix = "./";
45   std::string ExactArtifactPath;
46   std::string ExitOnSrcPos;
47   std::string ExitOnItem;
48   bool SaveArtifacts = true;
49   bool PrintNEW = true; // Print a status line when new units are found;
50   bool OutputCSV = false;
51   bool PrintNewCovPcs = false;
52   bool PrintFinalStats = false;
53   bool PrintCorpusStats = false;
54   bool PrintCoverage = false;
55   bool DumpCoverage = false;
56   bool DetectLeaks = true;
57   int  TraceMalloc = 0;
58   bool HandleAbrt = false;
59   bool HandleBus = false;
60   bool HandleFpe = false;
61   bool HandleIll = false;
62   bool HandleInt = false;
63   bool HandleSegv = false;
64   bool HandleTerm = false;
65   bool HandleXfsz = false;
66 };
67
68 }  // namespace fuzzer
69
70 #endif  // LLVM_FUZZER_OPTIONS_H