Skip to content

bench: backport main's benchmarks to release for before/after runs - #6103

Merged
kixelated merged 5 commits into
releasefrom
backport/benchmarks
Oct 21, 2026
Merged

kixelated merged 5 commits into
releasefrom
backport/benchmarks

Conversation

@kixelated

@kixelated kixelated commented Oct 20, 2026 •

Copy link
Copy Markdown
Collaborator

Ports main's benchmarks onto release so just bench origin/release, run from main, has a baseline to compare against. bench/run.sh <base> pairs Criterion cases by manifest, target, and case ID, so every case kept here has the same ID as on main.

When the code a case measures doesn't exist on release, the case is dropped rather than emulated. A missing baseline is better than a misleading one.

Criterion targets (cases listed on release)

Target Cases Change
moq-net track 108 Adapted. Dropped wall-clock staleness, fetch expiry, track::Range/with_ranges, untimed sparse reads, and retired empty runs.
moq-net group 55 Adapted. Dropped group_relay_frames (needs fuzz::object_group).
moq-net stats 10 Dropped request, write, and retag (APIs not on release).
moq-net origin 141 / 153 Adapted. Dropped narrow and narrow_delivery (no session auth on release).
moq-net session 302 / 362 Uses release's tests/support. Dropped the window=64 axis (no constrained mock), session_churn_*/moq-lite-06 (see below), and the SESSION_CPU mode.
moq-mux export (new) 27 Adapted to release's async constructors. Opening the export is untimed, as on main.
moq-mux containers (new) 72 with_max_delay becomes with_max_age (the rename in #4917).
kio contended (new) 30 As-is.
moq-pattern matching (new) 18 As-is.
moq-rtmp chunk_interleaving (new) 24 As-is.
moq-gst catalog (new) 9 As-is.
moq-uring worker_turns (new) n/a Linux only. TxBuf has no extend_from_slice on release, so the bench writes the slice and passes len.

Also:

  • moq-stats gains the aggregate table bench. It keeps only the grace=never, known-epoch rows, because release has no grace and no epochs.
  • JS: main's net/bench/frames.ts stdout fix, plus json/bench/codec.ts and signals/bench/effect.ts with a just js signals-bench recipe. The create-get-close row now yields once before closing, so the effect actually runs and tracks the signal (it closed before its microtask on main too, so main needs the same fix for the rows to pair).
  • criterion is added as a dev-dependency where the new targets need it. Cargo.lock only gains those edges. moq-stats keeps none, since its criterion bench (producer_tick) isn't on release.

Unchanged, because main's version is equivalent to release's or needs main-only code: announce, priority, kio tasks, e2ee protect, uring udp/session_lite, and the other JS benches.

Not ported, because the code they measure isn't on release: moq-net admission, auth, codec, memory, refresh, request-ids, retirement, schedule, synced, tail, viewers; moq-mux catalog, jitter, ts_schedule; moq-relay auth, http_idle; moq-stats producer_tick; moq-archive writer; moq-uring echo_quic, timers, unreachable_dials.

Notes

  • session_churn_*/moq-lite-06 hangs on release. After one open and close, reopening the subscription never reaches the relay. This may be a real release bug and is worth checking separately.
  • Merging this touches rs/**, so release-plz will propose patch bumps for the crates whose bench files changed. Only benchmark code changed.
  • Public API: none. Wire: none.

Verification

  • just check origin/release passes in the Nix dev shell (includes cargo shear and cargo sort).

  • cargo clippy --benches -D warnings and cargo fmt --check are clean on the touched crates. Run on macOS with rustup 1.98.1, outside Nix.

  • Every target above lists its cases. Each one ran briefly without panics; moq-uring ran in a Linux container.

🤖 Generated with Claude Code

(Written by Claude Opus 5.5)

Port main's Criterion targets onto release with main's case IDs, so
`just bench origin/release` on main pairs them. Cases whose subject
doesn't exist on release are dropped rather than emulated.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 20, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-21T20:16:13.310199Z 23b4e75 Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 8f0f1b798f

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

const effect = new Effect((effect) => {
checksum += effect.get(signal) + 1;
});
effect.close();

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Run the tracked effect before closing it

Effect schedules its callback in a microtask, but this closes the instance synchronously, so every scheduled run observes the closed state and returns without executing effect.get(signal). Consequently, the create-get-close row measures scheduling and immediate closure rather than creating and closing an effect with a tracked signal, while the queued callbacks drain outside the timed section and the checksum from the other rows masks the omission.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Valid: the callback never ran, so the row timed scheduling plus an immediate close. Fixed in 465fb4a: the row yields once so the effect tracks the signal before close(), the timing loop awaits only rows that return a promise (the sync rows pay no extra hop), and a separate tracked counter fails the run if the effect never executes. main's js/signals/bench/effect.ts has the same bug and needs the same fix for the before/after rows to pair.

(Written by Claude Opus 5.5)

kixelated and others added 4 commits October 21, 2026 11:12
release has no producer_tick bench, so moq-stats' benches never use criterion
and cargo shear fails. create-get-close closed the effect before its microtask
ran, so it never tracked the signal; yield once before closing.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ness

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@kixelated

Copy link
Copy Markdown
Collaborator Author

@codex review

(Written by Claude Opus 5.5)

@kixelated

Copy link
Copy Markdown
Collaborator Author

@codex review

The previous request on 23b4e75 has shown running for over 90 minutes; re-requesting.

(Written by Claude Opus 5.5)

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Already looking forward to the next diff.

Reviewed commit: 23b4e75916

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@kixelated
kixelated merged commit 36f392f into release Oct 21, 2026
13 checks passed
@kixelated
kixelated deleted the backport/benchmarks branch October 21, 2026 20:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant