[all-commits] [llvm/llvm-project] bede46: [Fuzzer] Optimize UpdateFeatureFrequency (#65288)
Arseny Kapoulkine via All-commits
all-commits at lists.llvm.org
Thu Sep 7 16:51:18 PDT 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: bede46f57eec7e9b4665a2b0f1df59a2fb1cc74d
https://github.com/llvm/llvm-project/commit/bede46f57eec7e9b4665a2b0f1df59a2fb1cc74d
Author: Arseny Kapoulkine <arseny.kapoulkine at gmail.com>
Date: 2023-09-07 (Thu, 07 Sep 2023)
Changed paths:
M compiler-rt/lib/fuzzer/FuzzerCorpus.h
Log Message:
-----------
[Fuzzer] Optimize UpdateFeatureFrequency (#65288)
Instead of a linear scan, use a bitset to track rarity of features. This
improves fuzzer throughput rather dramatically (close to 2x) in early
exploratory phases; in steady state this seems to improve fuzzing
throughput by ~15% according to perf.
The benchmarks are done on an executable with ~100k features, so the
results may change based on the executable that's being fuzzed.
kFeatureSetSize is 2M so the bitset is adding 256 KB to
sizeof(InputCorpus), but this should be fine since there's already three
arrays indexed by feature index for a total of 200 MB.
More information about the All-commits
mailing list