Skip to content

Reuse sidebar thread rows across count-only bus updates - #4884

Merged
trissim merged 1 commit into
mainfrom
perf/sidebar-goal-reads
Nov 18, 2026
Merged

trissim merged 1 commit into
mainfrom
perf/sidebar-goal-reads

Conversation

@trissim

@trissim trissim commented Nov 18, 2026

Copy link
Copy Markdown
Contributor

Result

  • Six real count-only messages: six extra full roster acquisitions before; zero after the already acquired reader is warm. Counts and channel clocks still advance.
  • 56 focused checks passed, exit0. Covers real pause, rename, activity, name recreation and expiry updates; existing sidebar failures, encoded transport and observation fairness remain green.
  • Alternated equal-warm roster/assembly phase,24 goal-bearing threads,20 repetitions each: median 11.882ms fresh /1.463ms acquired, identical snapshots. This excludes count-cut acquisition and is not a whole-machine CPU claim.

Owner repair

ThreadView.roster still derives the thread rows. CoordinationSnapshot.capture now assembles caller-acquired rows with the current bus cut. SidebarReadStage retains those rows beside the exact revision that supplied them; it only reacquires when RosterView changes.

RosterView inherits ActivityView, so registration, ownership/activity, runtime information, room and expiry dependencies remain declaration-derived. Goal execution feeds the new view directly. SidebarView inherits both the roster and count-cut views. No new source-path list, timer, process or launch authority.

The direct fresh snapshot reader and initial lightweight roster reader still acquire fresh rows. Unread/count/channel clocks keep their existing owners. User windows and all uncertain inputs remain untouched.

Evidence and limits

NRA authored patch_target/ensure_import plan simulated, reviewed and applied with parse checks. Source-selection semantics were chosen from the actual owners, not proved by an empty NRA guard suite. Plans and outputs retained in /home/ts/.cache/agent-scratch/codex-latency/sidebar-roster/.

Before control failed7!=1. First after run exposed initialization of absent derived-store source files; control now settles those real revisions before counting new acquisitions. Two fixture errors (expecting native idle activity to show a synthetic working detail, then deleting a heartbeat thread without stopping it) were corrected through their real owners; failed outputs retained. Final coherent affected run:56 passed,exit0.

Assumed: the existing declared activity/goal wake and expiry sources remain the roster freshness contract. No additional timeout or stale-data allowance is introduced. Existing open Toad windows retain their loaded code until reopened. No physical UI or overall CPU resolution claimed.

P260: derive roster invalidation from RosterView, retaining the original acquired ThreadViews separately from the bus count cut. Count-only updates no longer reread every goal.

Applied authored NRA patch_target/ensure_import plans after simulation and parse validation; semantic source-selection decision checked through the real-store consumer. 56 focused checks passed. Warm alternated 24-goal roster/assembly phase:11.88ms fresh,1.46ms acquired; no total CPU claim.
@trissim
trissim marked this pull request as ready for review November 18, 2026 06:40
@trissim
trissim merged commit 1293a64 into main Nov 18, 2026
3 of 6 checks passed
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