diff options
| author | Kostya Serebryany <kcc@google.com> | 2019-04-19 01:39:14 +0000 |
|---|---|---|
| committer | Kostya Serebryany <kcc@google.com> | 2019-04-19 01:39:14 +0000 |
| commit | bbb8522bdeff73488b772bcf71c450559b9d5626 (patch) | |
| tree | f0519be1e9acc6f6feb871799e9439431a818d66 /compiler-rt/lib/fuzzer/FuzzerFork.cpp | |
| parent | 6ab51de08e7c6b1dae8875bd5fb70354100e1116 (diff) | |
| download | bcm5719-llvm-bbb8522bdeff73488b772bcf71c450559b9d5626.tar.gz bcm5719-llvm-bbb8522bdeff73488b772bcf71c450559b9d5626.zip | |
[libFuzzer] in fork mode, make sure the child stats are always collected. This should fix the flakiness in fork-ubsan.test
llvm-svn: 358726
Diffstat (limited to 'compiler-rt/lib/fuzzer/FuzzerFork.cpp')
| -rw-r--r-- | compiler-rt/lib/fuzzer/FuzzerFork.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/compiler-rt/lib/fuzzer/FuzzerFork.cpp b/compiler-rt/lib/fuzzer/FuzzerFork.cpp index 3d85beb7538..9d338aa4708 100644 --- a/compiler-rt/lib/fuzzer/FuzzerFork.cpp +++ b/compiler-rt/lib/fuzzer/FuzzerFork.cpp @@ -150,6 +150,9 @@ struct GlobalEnv { } void RunOneMergeJob(FuzzJob *Job) { + auto Stats = ParseFinalStatsFromLog(Job->LogPath); + NumRuns += Stats.number_of_executed_units; + Vector<SizedFile> TempFiles, MergeCandidates; // Read all newly created inputs and their feature sets. // Choose only those inputs that have new features. @@ -189,8 +192,6 @@ struct GlobalEnv { PrintPC(" NEW_FUNC: %p %F %L\n", "", TPC.GetNextInstructionPc(TE->PC)); - auto Stats = ParseFinalStatsFromLog(Job->LogPath); - NumRuns += Stats.number_of_executed_units; if (!FilesToAdd.empty() || Job->ExitCode != 0) Printf("#%zd: cov: %zd ft: %zd corp: %zd exec/s %zd " "oom/timeout/crash: %zd/%zd/%zd time: %zds\n", NumRuns, |

