diff options
author | Kostya Serebryany <kcc@google.com> | 2015-10-24 01:16:40 +0000 |
---|---|---|
committer | Kostya Serebryany <kcc@google.com> | 2015-10-24 01:16:40 +0000 |
commit | 9cc3b0ddb60f7515b5216fdb568e71aa7a7596c8 (patch) | |
tree | 6d1fcc00f09413ab0d9308a99f5e5197b01e6185 /llvm/lib/Fuzzer/FuzzerInternal.h | |
parent | edb35d95d1ffa14fca9dfdb97d30cc0f834155ba (diff) | |
download | bcm5719-llvm-9cc3b0ddb60f7515b5216fdb568e71aa7a7596c8.tar.gz bcm5719-llvm-9cc3b0ddb60f7515b5216fdb568e71aa7a7596c8.zip |
[libFuzzer] add -merge flag to merge corpora
llvm-svn: 251168
Diffstat (limited to 'llvm/lib/Fuzzer/FuzzerInternal.h')
-rw-r--r-- | llvm/lib/Fuzzer/FuzzerInternal.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/llvm/lib/Fuzzer/FuzzerInternal.h b/llvm/lib/Fuzzer/FuzzerInternal.h index 2dc44f98def..d6e1cb85a23 100644 --- a/llvm/lib/Fuzzer/FuzzerInternal.h +++ b/llvm/lib/Fuzzer/FuzzerInternal.h @@ -104,6 +104,7 @@ class Fuzzer { void InitializeTraceState(); size_t CorpusSize() const { return Corpus.size(); } void ReadDir(const std::string &Path, long *Epoch) { + Printf("Loading corpus: %s\n", Path.c_str()); ReadDirToVectorOfUnits(Path.c_str(), &Corpus, Epoch); } void RereadOutputCorpus(); @@ -121,6 +122,9 @@ class Fuzzer { void ExecuteCallback(const Unit &U); + // Merge Corpora[1:] into Corpora[0]. + void Merge(const std::vector<std::string> &Corpora); + private: void AlarmCallback(); void MutateAndTestOne(Unit *U); |