ci: discard earlier Criterion results before the regression gate benches #377

Merged
natsukium merged 1 commit from bench/gate-stale-results into main 2026-09-24 03:29:42 +09:00
Owner

The Criterion regression gate failed on every PR, including docs-only #374 and the #375 fix #376. Both runs reported the same 44 regressions to the decimal.

Cause: criterion.py gate walks every change/estimates.json under $CARGO_TARGET_DIR/criterion, and that directory persists across jobs on the nix runner. The PR gate re-benches only daemon_side, multi_cycle and end_to_end_throughput, so change files left by earlier runs of other benches (socket_write, video_frame, parser_throughput, and more) were read as this PR's regressions. All 9 benches the job actually measured were within noise or faster.

Fix: remove the Criterion root before benching the base SHA.

Rejected alternative: filtering inside the gate would have to repeat the workflow's bench selection and could drift from it.

The Criterion regression gate failed on every PR, including docs-only #374 and the #375 fix #376. Both runs reported the same 44 regressions to the decimal. **Cause:** `criterion.py gate` walks every `change/estimates.json` under `$CARGO_TARGET_DIR/criterion`, and that directory persists across jobs on the nix runner. The PR gate re-benches only daemon_side, multi_cycle and end_to_end_throughput, so change files left by earlier runs of other benches (socket_write, video_frame, parser_throughput, and more) were read as this PR's regressions. All 9 benches the job actually measured were within noise or faster. **Fix:** remove the Criterion root before benching the base SHA. **Rejected alternative:** filtering inside the gate would have to repeat the workflow's bench selection and could drift from it.
ci: discard earlier Criterion results before the regression gate benches
All checks were successful
darwin / publish felis (aarch64-darwin) (pull_request) Has been skipped
fuzz / cargo fuzz smoke (per target) (pull_request) Successful in 1m10s
pr / nix flake check (pull_request) Successful in 25s
pr / cargo build / clippy / test / deny (pull_request) Successful in 1m44s
pr / wire schema is compatible with the base (pull_request) Successful in 13s
pr / frontend smoke (x86_64-linux) (pull_request) Successful in 1m27s
pr / publish felis (x86_64-linux) (pull_request) Has been skipped
windows / detect relevant changes (pull_request) Successful in 4s
windows / windows docs-only no-op (pull_request) Has been skipped
windows / cargo clippy (Windows cross) (pull_request) Successful in 14s
windows / cargo nextest (Windows) (pull_request) Successful in 4m8s
windows / frontend smoke (Windows) (pull_request) Successful in 1m37s
windows / package felis (x86_64-pc-windows-msvc) (pull_request) Has been skipped
fuzz / cargo fuzz nightly long-run (push) Has been skipped
darwin / detect relevant changes (push) Successful in 4s
darwin / darwin docs-only no-op (push) Has been skipped
darwin / build felis (aarch64-darwin) (push) Successful in 14s
darwin / publish felis (aarch64-darwin) (push) Successful in 34s
fuzz / cargo fuzz smoke (per target) (push) Successful in 1m6s
pr / nix flake check (push) Successful in 6s
pr / cargo build / clippy / test / deny (push) Successful in 1m42s
pr / wire schema is compatible with the base (push) Successful in 12s
pr / frontend smoke (x86_64-linux) (push) Successful in 7s
windows / detect relevant changes (push) Successful in 4s
windows / windows docs-only no-op (push) Has been skipped
windows / cargo nextest (Windows) (push) Successful in 4m7s
windows / frontend smoke (Windows) (push) Successful in 1m50s
pr / publish felis (x86_64-linux) (push) Successful in 14s
windows / cargo clippy (Windows cross) (push) Successful in 11s
windows / package felis (x86_64-pc-windows-msvc) (push) Successful in 1m50s
b90ef0936e
The gate walks every change/estimates.json under the Criterion root, and
on the nix runner that root lives in a target directory that persists
across jobs. The PR gate only re-benches daemon_side, multi_cycle and
end_to_end_throughput, so change files left by an earlier run of other
benches were judged as the PR's regressions: every PR failed with the
same 44 stale results (socket_write, video_frame, parser_throughput, ...)
while the benches it actually measured were within noise or faster.

Clearing the root first keeps the gate to what this job measured. A
filter in the gate itself was rejected: it would have to repeat the
workflow's bench selection and drift from it.

Assisted-by: Claude Code
natsukium deleted branch bench/gate-stale-results 2026-09-24 03:29:42 +09:00
Commenting is not possible because the repository is archived.
No description provided.