diff options
author | Kostya Serebryany <kcc@google.com> | 2017-08-25 20:09:25 +0000 |
---|---|---|
committer | Kostya Serebryany <kcc@google.com> | 2017-08-25 20:09:25 +0000 |
commit | 70c68ad58bdc2727782b78eaf06347c77120219e (patch) | |
tree | 12609bd4b3d0ee23f918e3f218d0c8b74d86df89 /lib/fuzzer/FuzzerTracePC.h | |
parent | 62ddf6220c3bc9c7ecc53bceec6d4548827a79e3 (diff) |
[libFuzzer] add -print_funcs=1 (on bey default): print newly discovered functions during fuzzing
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@311797 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/fuzzer/FuzzerTracePC.h')
-rw-r--r-- | lib/fuzzer/FuzzerTracePC.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/fuzzer/FuzzerTracePC.h b/lib/fuzzer/FuzzerTracePC.h index 0c9d4b69b..76aa0748f 100644 --- a/lib/fuzzer/FuzzerTracePC.h +++ b/lib/fuzzer/FuzzerTracePC.h @@ -82,6 +82,7 @@ class TracePC { void SetUseCounters(bool UC) { UseCounters = UC; } void SetUseValueProfile(bool VP) { UseValueProfile = VP; } void SetPrintNewPCs(bool P) { DoPrintNewPCs = P; } + void SetPrintNewFuncs(bool P) { DoPrintNewFuncs = P; } void UpdateObservedPCs(); template <class Callback> void CollectFeatures(Callback CB) const; @@ -133,6 +134,7 @@ private: bool UseCounters = false; bool UseValueProfile = false; bool DoPrintNewPCs = false; + bool DoPrintNewFuncs = false; struct Module { uint32_t *Start, *Stop; @@ -158,6 +160,7 @@ private: uintptr_t *PCs() const; std::set<uintptr_t> ObservedPCs; + std::set<uintptr_t> ObservedFuncs; ValueBitMap ValueProfileMap; uintptr_t InitialStack; |