Repository navigation
Description
Finding
PR #1387's new benchmark harness (pkgs/id/benches/world_bench.rs, head commit b6f5b720e9fc7d117f44b46181818d114dbad3aa) ships a guest_replay benchmark that never replays anything through the guest. It builds a journal of N Committed chat events, calls WorldCore::restore, and then pushes restored.replay through its CountingProgram — but on current main, restore does not put committed chat events into replay at all, so the guest pass iterates an empty vec and guest.seen stays 0. The reported guest_replay number is restore-only time, mislabeled as guest replay.
Evidence
- PR: wip(id): F11.8 slice 1 benchmark harness — four world benchmarks + just/nix runners (#539) #1387 (OPEN, slice 1 of id(ci): F11.8 benchmark harness with committed baselines #539)
pkgs/id/benches/world_bench.rs:121—bench_guest_replaybuilds the journal fromchat_event(...)entries (WorldEventKind::Chat).pkgs/id/benches/world_bench.rs:166—for event in &restored.replay { guest.update(event)?; }— the loop that is supposed to be the measured guest workload.- Current main
pkgs/id/src/world/core.rs:347(verified at37418e56): inWorldCore::restore, theJournalEntry::Committedmatch arm isWorldEventKind::System { .. } | WorldEventKind::Chat(_) => {}— chat events are applied to core state viacommit_preparedbut are not pushed toreplay. OnlyInputcommitted events (core.rs:344) and journalSystementries (core.rs:317) land inreplay. - The bench's own inline comment half-notices this ("count the guest pass over the full journal's events as the replay workload when restore() consumed them into core state directly") but the code does not do that — it still iterates
restored.replay.
Why it matters
Slice 2 of #539 commits baselines recorded from this harness, and slice 3's CI job diffs medians against them. A guest_replay baseline that contains zero guest work will (a) understate the real replay cost the benchmark exists to track, and (b) make any future fix to the bench look like a massive regression when the guest pass starts doing real work. The failure is silent: the bench prints a plausible-looking line either way.
Acceptance criteria
-
guest_replayactually pushes the N committed events through the guest (e.g. iterate the journal's committed events / core history, or build the journal from event kinds thatrestorereturns inreplay), OR the benchmark is renamed/re-scoped to state honestly that it measures restore only. - The bench asserts the guest saw the expected count (e.g.
guest.seen == events, orrestored.replay.len()is checked non-empty) so a future restore-semantics change cannot silently re-empty the workload. -
cargo bench --bench world_bench -- --quick --only guest_replay(or the just/nix runner equivalent) completes with the assertion in place.
Refs #539. Found by pr-diff-review-b reviewing PR #1387's diff against current main.
Activity
developing-today commentedon Oct 27, 2026
CODE-494
dezren39 commentedon Oct 27, 2026
🤖 Agent note · filed
guest_replaybenchmark (pkgs/id/benches/world_bench.rs:121,166) pushesrestored.replaythrough its counting guest, but current mainWorldCore::restore(pkgs/id/src/world/core.rs:347, verified at 37418e5) never puts committed Chat events inreplay— only Input committed events (:344) and journal System entries (:317) land there. The bench's journal is all chat events, so the guest sees zero events and the reported number is restore-only. Enqueued as a triage packet to repo-health-code-pilot.dezren39 commentedon Oct 28, 2026
🤖 Agent note · picked up
39 remaining items
dezren39 commentedon Oct 31, 2026
🤖 Agent note · picked up
dezren39 commentedon Oct 31, 2026
🤖 Agent note · parked
054bbfbd4). Fix complete and locally verified on the reference laptop: assertion fires on the old workload (guest replay saw 0 of 200 committed events), quick run passes, full-size baseline regenerated (median=0.170, two runs agreed). Checks had not registered ~4 min after the PR opened; Codex review requested.queue/1742-1403-guest-replay· worktree~/git/fleet/1742-1403-guest-replay(laptop)fix(id): guest_replay bench replays committed input events and assert…
dezren39 commentedon Oct 31, 2026
🤖 Agent note · done