Skip to content

chore(benchmarks): drop the dead *-budget reference targets - #1910

Merged
trueadm merged 1 commit into
mainfrom
fix/remove-bench-budget-targets
Oct 8, 2026
Merged

trueadm merged 1 commit into
mainfrom
fix/remove-bench-budget-targets

Conversation

@trueadm

@trueadm trueadm commented Oct 8, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

  • Stop publishing fixed *-budget reference targets from 19 weekly benchmark scripts. ci: remove every byte and work-count budget gate #1907 removed the 366 ratio guards that compared against them, so nothing reads them anymore.
  • Remove the same targets from the checked-in result files ssr-final-replay/measurements.json, view-transitions/measurements.json, and baselines/local/memo-wall.json.
  • Update suite READMEs that described the removed guards or passed --ratios to suites that no longer have any guards.

Why

  • Follow-up to ci: remove every byte and work-count budget gate #1907, which removed every CI budget gate. The scripts kept pushing constant-valued *-budget peers (for example keys-work-budget, state-access-budget, scan-budget/populated-budget/wave-budget, row-budget/render-budget). They were reference values for ratio guards that no longer exist.

Changes

  • Scripts: client-hot-paths/{keys,branches}.mjs, compiler-output/branch-environments.mjs, custom-hook-path/run.mjs, dom-events/spread.mjs, effect-postorder/refs.mjs, effect-scheduling/wave.mjs, hooks-runtime/{optional-arguments,state-access}.mjs, memo-wall/{bail-compare,survivor-work}.mjs, recursive-context/hooks-warm-work.mjs, root-transactions/reorders.mjs, scoped-signals/event-owners.mjs, ssr-final-metadata/audit.mjs, ssr-final-replay/work.mjs, svg-dashboard/work.mjs (the unused BUDGET constant is gone too), universal-materialization/run.mjs, view-transitions/effect-cleanup.mjs.
  • The removed set is exactly the set of names that only the deleted guards referenced. I checked this by diffing ratios.json before and after ci: remove every byte and work-count budget gate #1907.
  • Unchanged on purpose:
    • Live ratio guards still reference ssr-replay-streaming's stream-budget-* and passive-scheduling's budget, so those stay.
    • The trace-limit config names in scoped-signals/run-trace.mjs stay.
    • In-script assertions stay. spread.mjs still checks actual <= budget, wave.mjs checks collections and parent reads, refs.mjs checks zero sibling sorts, and effect-cleanup.mjs checks effect-cleanup-budget.json. Only their dead target output is removed.
    • Time budgets, scheduler/host budgets, context:budget:check, and dated historical records stay.

Validation

  • pnpm format:check (ran pnpm format:files:check on every changed file: pass)
  • pnpm typecheck (not run; the change is .mjs/.md/.json only)
  • pnpm test (not run)
  • targeted tests:
    • git grep -n "\-budget'" benchmarks matches only the three excluded run-trace.mjs config names.
    • node benchmarks/bench.mjs --list works.
    • pnpm ci:workflow:test: 377/377 pass.
    • I ran 15 touched Node-only scripts with BENCH_JSON the way bench.mjs invokes them: branches, branch-environments, state-access, optional-arguments, custom-hook-path/run, hooks-warm-work, wave, refs, bail-compare, survivor-work, reorders, ssr-final-metadata/audit, ssr-final-replay/work, universal-materialization/run, and event-owners. Fourteen exit 0 and emit no target containing budget. scoped-signals/event-owners.mjs exits 1 at line 37 (potential signal bindings, a compiler-output assertion). Main's unmodified copy fails the same way, so the failure predates this PR.
    • node --check passes on the Chromium-only scripts (keys.mjs, spread.mjs, svg-dashboard/work.mjs, effect-cleanup.mjs). I did not run them.
    • pnpm sync produced no changes.
  • perf-review: not applicable. Benchmark scripts and docs only, no runtime, compiler-output, or binding hot paths.

Risk / follow-ups

  • Out of scope here:
    • scoped-signals/event-owners.mjs already fails on main: compiled output no longer matches /enableSignalBindings\(1, true\)/.
    • view-transitions/effect-cleanup.mjs runs in ci.yml's Chromium browser lane on every PR. It still enforces the committed effect-cleanup-budget.json ceilings (measured + 32 calls), which makes it a live CI work-count budget gate that ci: remove every byte and work-count budget gate #1907 did not remove.
    • ci: remove every byte and work-count budget gate #1907 also removed scoped-signals-trace's wrapped-max-budget vs unfilled-max-budget guard. That guard compared two measured configs in the same run, not a fixed value; it was removed only because its name ends in -budget. benchmarks/scoped-signals/README.md still describes it.

Provenance

  • An agent produced this diff (agent-authored)

🤖 Generated with Claude Code


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need. Autofix is disabled.


Note

Low Risk
Benchmark scripts, docs, and frozen JSON only; production runtime and CI work-count assertions called out as retained are untouched.

Overview
Follow-up to #1907: benchmark runners no longer emit fixed *-budget reference targets that existed only for deleted ratio guards in baselines/ratios.json.

Scripts stop appending paired budget rows (e.g. branches-*-work-budget, keys-work-budget, custom-path-budget, scan-budget / populated-budget / wave-budget, svg-dashboard drops the unused BUDGET constant and its -work-budget target). Checked-in artifacts (memo-wall.json, ssr-final-replay/measurements.json, view-transitions/measurements.json) drop the same entries.

Docs reword “ratio guards” to recorded work counts and remove --ratios from several bench.mjs examples where suites no longer have those guards. Unchanged: in-script ceilings (spread.mjs, wave.mjs, refs.mjs, effect-cleanup.mjs + effect-cleanup-budget.json), and live ratio targets like stream-budget-* / passive budget.

Reviewed by Cursor Bugbot for commit 0aa73a7. Bugbot is set up for automated code reviews on this repo. Configure here.

#1907 removed every ratio guard whose reference was a committed `*-budget`
peer, so the fixed reference values those scripts still published had no
reader. Stop emitting them, drop them from the checked-in result files, and
update the READMEs that described the removed guards.

In-script assertions stay: spread.mjs, wave.mjs, refs.mjs and
effect-cleanup.mjs still check their own limits. stream-budget-* and
passive-scheduling's `budget` stay because live ratio guards reference them.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@github-actions github-actions Bot added agent-authored Diff or issue body substantially produced by an AI agent chore PR: tooling, dependencies, repo maintenance labels Oct 8, 2026
@trueadm
trueadm marked this pull request as ready for review October 8, 2026 16:02
@github-actions

github-actions Bot commented Oct 8, 2026

Copy link
Copy Markdown
Contributor

Benchmark report

🟢 No byte growth, no added work, and no timing changes beyond ±3%.

Compares 385d6aba9, the merge commit's first parent with 938762f89 on the same runner. Any increase in a js-framework work counter fails this check; byte changes are a report. Wall time is a report: base and head samples alternate in one browser, and an operation is called slower or faster only when the 95% confidence interval of its ratio excludes ±3%. Workflow run

js-framework: 1k/10k row operations

All 20 timed operations (20 without a verdict)
target operation base ms head ms head/base 95% CI
octane-tsrx run 2.708 2.750 ±0.0% −3.4% … ±0.0% ⚪ within noise
octane-tsrx replace 7.233 7.175 +5.5% −1.5% … +9.8% ⚪ within noise
octane-tsrx add 2.583 2.675 +4.0% +0.0% … +7.7% ⚪ within noise
octane-tsrx update 0.143 0.156 +3.0% −5.7% … +11.2% ⚪ within noise
octane-tsrx select 0.007 0.006 −0.0% −4.3% … +7.3% ⚪ within noise
octane-tsrx swap 0.038 0.037 −2.2% −6.2% … +7.5% ⚪ within noise
octane-tsrx remove 0.019 0.019 +2.1% −10.5% … +7.5% ⚪ within noise
octane-tsrx runlots 27.342 28.367 +1.0% −3.9% … +6.5% ⚪ within noise
octane-tsrx select_lots 0.007 0.007 +2.4% +0.0% … +5.5% ⚪ within noise
octane-tsrx clear 50.850 53.200 +2.1% −4.6% … +4.7% ⚪ within noise
octane-jsx run 3.675 3.933 +4.3% −3.7% … +10.6% ⚪ within noise
octane-jsx replace 7.917 8.333 +7.7% +1.4% … +14.5% ⚪ within noise
octane-jsx add 3.317 3.283 +0.0% −2.9% … +2.9% ⚪ within noise
octane-jsx update 0.275 0.263 −1.7% −4.1% … +0.3% ⚪ within noise
octane-jsx select 0.125 0.123 −0.5% −1.5% … +0.3% ⚪ within noise
octane-jsx swap 0.225 0.217 −0.6% −2.5% … +0.9% ⚪ within noise
octane-jsx remove 0.169 0.170 ±0.0% −1.3% … +0.6% ⚪ within noise
octane-jsx runlots 30.833 30.750 −0.2% −4.1% … +2.4% ⚪ within noise
octane-jsx select_lots 2.070 2.064 +2.9% −12.5% … +7.3% ⚪ within noise
octane-jsx clear 62.283 56.067 −2.2% −7.6% … +7.9% ⚪ within noise

All 64 work counters are unchanged.

Application bundle size (bytes)

No changes across 60 measured values.

Public-import reachability bundles (bytes)

No changes across 111 measured values.

@trueadm
trueadm merged commit 7c780b0 into main Oct 8, 2026
54 checks passed
@trueadm
trueadm deleted the fix/remove-bench-budget-targets branch October 8, 2026 16:34
trueadm added a commit that referenced this pull request Oct 8, 2026
Two pushes that publish at once could each find no open review issue and
open one apiece, splitting the rolling log (Bugbot). Each publish attempt
now writes to the oldest open review issue, folds in the entries of any
newer review issue and closes it, then confirms its entry is in the oldest
open issue. An issue the run just opened stays in view even if the issue
listing lags behind.

The GitHub calls sit behind a small adapter so a test can replay the race:
one publish runs start to finish between the other's read and its create,
and both entries end up in the surviving issue.

Also drop the `*-budget` target filter: #1907 and #1910 removed those
targets, so nothing produces them any more.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
trueadm added a commit that referenced this pull request Oct 8, 2026
* ci: review bundle growth after it lands on main

Replaces pre-merge byte budgets with a post-merge review. Each push to main
builds the bundle-size and reachability scenarios before and after the push.
When a bundle grew by at least 32 gzip bytes, Claude reads the landed diff
with read-only tools and judges whether the growth is earned or slop and how
the change could have been written smaller. benchmarks/size-review.mjs records
that in one rolling "Bundle size review" issue: an open one is edited in
place, newest entry first, and a new one opens only when none is open.

Claude runs only when the ANTHROPIC_API_KEY secret is set; without it the
issue records the measured growth alone.

Co-Authored-By: Claude Opus 5.5 <[email protected]>

* fix(ci): converge concurrent size-review publishes on one issue

Two pushes that publish at once could each find no open review issue and
open one apiece, splitting the rolling log (Bugbot). Each publish attempt
now writes to the oldest open review issue, folds in the entries of any
newer review issue and closes it, then confirms its entry is in the oldest
open issue. An issue the run just opened stays in view even if the issue
listing lags behind.

The GitHub calls sit behind a small adapter so a test can replay the race:
one publish runs start to finish between the other's read and its create,
and both entries end up in the surviving issue.

Also drop the `*-budget` target filter: #1907 and #1910 removed those
targets, so nothing produces them any more.

Co-Authored-By: Claude Opus 5.5 <[email protected]>

* fix(ci): record size reviews as issue comments and survive a Claude timeout

Two publishes that read the same open issue body and edited it could
overwrite each other: the later write still held its own entry and
returned, so the earlier review vanished (Bugbot). Each entry is now its
own comment on the rolling issue. Runs only add comments, so nothing a
concurrent run writes can be lost. A rerun for the same commit edits its
own comment, and the workflow's per-commit concurrency group serializes
reruns. The issue body is a fixed header. Duplicate issues from two runs
that both found none still fold into the oldest one and close.

A 20-minute timeout killed the Claude step before its `||` fallback, so the
job counted as failed and the record step was skipped (Bugbot). The step is
now `continue-on-error`. It writes to analysis.partial.md and moves that to
analysis.md only after a clean exit, so a killed review can't leak a partial
analysis into the issue.

Co-Authored-By: Claude Opus 5.5 <[email protected]>

---------

Co-authored-by: Claude Opus 5.5 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agent-authored Diff or issue body substantially produced by an AI agent chore PR: tooling, dependencies, repo maintenance

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant