Skip to content

Instantly share code, notes, and snippets.

@mablr
Last active June 25, 2026 16:33
Show Gist options
  • Select an option

  • Save mablr/e28689d65389d79194cf4c6dbae0a839 to your computer and use it in GitHub Desktop.

Select an option

Save mablr/e28689d65389d79194cf4c6dbae0a839 to your computer and use it in GitHub Desktop.

Decofe Perf PR Benchmark Plan

Static diff triage for deciding which PRs to combine and run through scfuzzbench. The goal is to avoid benchmarking dozens of tiny AI PRs one-by-one.

Run These scfuzzbench Branches

These are the concrete grouped benchmark candidates, in priority order.

1. Invariant campaign steady-state overhead

Group and benchmark: #15252, #15266, #15285, #15286, #15287, #15290, #15298, #15301

Why: all remove allocations, clones, atomics, or repeated lookups in steady-state invariant execution. This is the highest-confidence scfuzzbench group.

Expected signal: invariant campaigns with non-trivial depth and repeated handler calls.

2. Invariant assertion fast path

Group and benchmark: #15258, #15259, #15265, #15307

Why: all reduce repeated work around invariant checks, can_continue, assertion handling, or invariant calldata construction.

Expected signal: invariant benchmarks where most checks pass and the assertion path runs many times.

3. Fuzz dictionary and collected-value filtering

Group and benchmark: #15303, #15313, #15314, #15315, #15317, #15318, #15319

Why: all reduce empty/no-op work while collecting fuzz dictionary inputs from calls, logs, storage, handlers, and stack values.

Expected signal: fuzz campaigns with dictionary/value collection enabled and contracts that produce logs, storage touches, or stack samples.

4. Corpus and ABI mutation allocation reductions

Group and benchmark: #15300, #15310

Why: both target corpus/mutation allocation behavior. They are small, coherent, and have targeted tests.

Expected signal: fuzz campaigns that heavily use corpus persistence, comparison feedback, or ABI mutation.

5. Conservative edge/cmp coverage bookkeeping

Group and benchmark if scfuzzbench config exercises edge/cmp feedback: #15291, #15293, #15294, #15295, #15302

Why: these are relatively mechanical reductions in edge/cmp coverage data structures and map updates.

Expected signal: only if the benchmark actually uses the relevant coverage/cmp instrumentation path. Otherwise skip this run.

6. Cheatcode inspector step-hook overhead

Group and benchmark if the benchmark contracts run through Foundry cheatcode inspector hooks: #15256, #15296, #15305

Why: #15305 is the real candidate: it skips inactive step / step_end hook work. #15256 and #15296 are compatible smaller hook-path changes.

Expected signal: interpreter-heavy fuzz campaigns where cheatcode inspector exists but most hooks are inactive.

Risk: audit #15305 before relying on results, because broad early returns can skip side effects if the inactive predicate is incomplete.

Optional / Scenario-Specific scfuzzbench Runs

These are relevant, but I would not spend default scfuzzbench time on them unless the scenario is specifically enabled.

Experimental edge coverage tuning

Optional group: #15257, #15260, #15312

Why not default: these are slope. Inline attributes, eager preallocation, and a stateful repeated-site cache are compiler/workload dependent.

Invariant failure replay and shrinking

Optional group: #15308, #15320

Why not default: these optimize failing invariant replay/shrink paths, not normal passing-campaign throughput. Benchmark only with a workload that intentionally triggers invariant failures and measures shrinking/replay.

Invariant setup

#15306

It only reduces setup work while building invariant settings. Unsure the startup/setup time would be captured by benchmark.

Relevant, But Do Not scfuzzbench

These look like legitimate Foundry perf changes, but scfuzzbench is the wrong tool for them.

Keep out of scfuzzbench: #15263, #15264, #15292, #15297, #15304

Why:

  • #15263: JSON serialization cheatcode path, not normal fuzz loop throughput.
  • #15264: trace identifier matching, better validated with trace-specific tests or microbenchmarks.
  • #15292: artifact code lookup cache, setup/deploy-code oriented.
  • #15297: avoids cloning inspector outcomes, generally relevant but too broad/unfocused for a clean scfuzzbench signal.
  • #15304: broadcast result clone avoidance, not a fuzzing benchmark path.

Close / Ignore

#15311

Reason: already closed. It is retained in the JSON only so the accounting remains complete.

Final Benchmark Queue

Run these first:

  1. Invariant campaign steady-state overhead
  2. Invariant assertion fast path
  3. Fuzz dictionary and collected-value filtering
  4. Corpus and ABI mutation allocation reductions
  5. Conservative edge/cmp coverage bookkeeping, only if coverage/cmp feedback is part of the benchmark config
  6. Cheatcode inspector step-hook overhead, only if cheatcode inspector hooks are active in the workload

Skip default scfuzzbench for:

#15257, #15260, #15312, #15308, #15320, #15306, #15263, #15264, #15292, #15297, #15304, #15311

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment