Page MenuHomePhabricator

[test] Speed up fuzzing by ~200x when using afl-fuzz
ClosedPublic

Authored by Fabien on Fri, Nov 29, 13:21.

Details

Reviewers
deadalnix
Group Reviewers
Restricted Project
Commits
rABC6cec48af5cc3: [test] Speed up fuzzing by ~200x when using afl-fuzz
Summary
Enable the `afl-clang-fast++` features deferred forkserver
(`__AFL_INIT`) and persistent mode (`__AFL_LOOP(1000)`).

Backport of core PR10415:
https://github.com/bitcoin/bitcoin/pull/10415/files

Test Plan

Follow the fuzzing.md to run the fuzzer.
Check that the performance are improved by using afl-clang-fast.
My numbers:

  • Before: ~60/s
  • After: ~7300/s

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.