Repository navigation
Controls batch 11: meters, observation taps, delay lines and sends carry across a plan swap (#1633, #1282, #1327, #1283, #1284, #1381) - #1673
Merged
Conversation
…#1633) effect_control_lane builds no carried slots; graph::install_effect_carry installs them on the control thread for the successor sites in the carry program only, charged through effect_carry_retained_bytes, and can_carry_from refuses a lane without them. Browser boot growth 20,971,520 -> 20,447,232 bytes (8 pages under the 20 MiB pin); the first-compile graph rows fall 6,048 bytes each at eight lanes; every carry gate unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
# Conflicts: # crates/capi/tests/resource_lifecycle.rs
A live-controlled per-node effect instance that survives a swap with the same layout, control kind, cell and shunt shape moves by pointer: its control lane carries (carried slots, bypass ramp) and its processor and shunt are exchanged, so a delay tail rings on through the swap; pending Observe records go through the existing marked drain. Node-to-node moves are no longer refused. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The one combined engine edit for the carry chain (root ruling, accepted on its
attempt): ObserverKind {Meter, Observation, Spectrum}, ObserverCarry,
observer_carries on the executor and the plan, and
HostAttachment::adopt_predecessor called from PreparedRenderPlan::carry_from;
plus its mod.rs re-export and a doc-only link fix (root accepted both). A meter
whose strip, tap, metrics and config are unchanged carries its observer
through the swap; fresh meters join the carried window grid; host-core pairs
carried meter readers allocation-free. Known red until #1381b in this batch:
host-web structural_apply meter test (recorded in the spec).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A tap whose effect instance carries (any of the four lane/node forms) moves with it: the tap tables, armed count and publisher swap by pointer after the pending-Observe drain, so a subscribe acknowledged before the swap is armed on the successor and its open window continues; host-core pairs the carried readers (pair_carried_observations), allocation-free on the swap block. A restarted owner's tap starts fresh (#1584 D6 arms successors at preparation). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…block (#1381b) The browser plan attachment's adopt_predecessor pairs the readers the core carried (pair_carried_meters, pair_carried_observations) and the host's plan tables follow them, so a swap keeps meter delivery and an acknowledged subscription running instead of restarting; allocation-free in the swap block. The structural_apply meter test, red since #1327a, now proves the carry. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Every PDC compensation line whose delayed edge keeps its endpoints carries its pending audio into the successor, at the output and inside submixes: equal lengths swap the rings, other lengths copy head-aligned; a re-pointed route does not carry. Allocation-free on the swap block; the line table is charged in the carry program. Two capi live-test oracles compare from the block after the lines flush. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A strip's delay lane carries when its length is unchanged; a live send whose source and destination are unchanged carries its ramp, position and mute after the predecessor's pending cell value is applied; a carried send with a live difference is retargeted (route_record_between serves the classifier and the join). Allocation-free on the swap block. LiveRoute::drain is renamed apply_pending (it reads a latest-target cell and pops nothing). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… per-node instance now carries across the audit's swap) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Controls batch 11: the carry chain continues. A plan swap now also carries per-node effect instances (a delay tail rings on), meters and effect observation taps (an acknowledged subscribe stays armed on the successor), PDC compensation lines, strip delay lines and live send ramps (a carried send retargets to its new value), and the browser pairs the carried meter and observation readers in the swap block. An effect lane holds no carry storage until a swap carries it, so the browser's boot budget regains 8 pages of margin. The stored-automation program's 38 filed specs move into ISSUE_SPECS.
Closes #1633
Closes #1282
Closes #1327
Closes #1283
Closes #1284
Closes #1381
What changed
effect_control_lanebuilds no carried slots;graph::install_effect_carryinstalls them on the control thread for the successor sites of the carry program only, charged througheffect_carry_retained_bytes;can_carry_fromrefuses a lane without them. Browser boot growth 20,971,520 -> 20,447,232 bytes (8 pages under the 20 MiB pin).crates/engine/src/realtime/plan.rs, accepted on its attempt, with itsmod.rsre-export and a doc-only link fix, both root-accepted):ObserverKind,ObserverCarry,observer_carrieson the executor and the plan, andHostAttachment::adopt_predecessorcalled fromPreparedRenderPlan::carry_from. A meter whose strip, tap, metrics and config are unchanged carries its observer; fresh meters join the carried window grid; host-core pairs the carried readers allocation-free.route_record_betweenserves the classifier and the join).LiveRoute::drainis renamedapply_pending: it reads one latest-target cell and pops nothing (root accepted the rename).adopt_predecessorpairs the carried meter and observation readers and the host's plan tables follow them, so a browser swap keeps meter delivery and an acknowledged subscription running..github/ISSUE_SPECS, with every draft reference replaced by its issue number.Evidence
batch-gates.sh, now also running the bench and realtime policies, the host-core feature matrix with-D warningsand the host-core loom step) plustrace-graph-audit.sh(1,000,000 blocks): all green; SDK headless 528 pass, 0 fail. Browser qualification (run.mjs --check-matrix --self-test-mutations): chromium, firefox and webkit each "all qualification gates passed".audit capipcm_digestmoves from9bc5ec3d8a4c223ctobf7dcedd1d92621fwith Carry per-node effect instances across a plan swap #1282. Cause: the audit commits one structural transaction after its first call (adds a muted track), and its session holds a per-node live effect instance that restarted at that swap before Carry per-node effect instances across a plan swap #1282 and now moves by pointer with its state. Checked by building the audit at Carry per-node effect instances across a plan swap #1282's parent405221f8d(9bc5ec3d8a4c223c) and at067d145ec(bf7dcedd1d92621f); the later slices leave it unchanged. 0 allocations, 0 frees, 0 render errors.scripts/check-web-audioworklet-callgraph.py):enter_block2 -> 4 indirect sites (#1327a: the attachment hook and theobserver_carriesread),render_next0 -> 2 (#1381b: the downcast that hands the paired readers to the host tables), each with its reason.#1266gate-3 test replaces the multiband under a new ID to keep its restart expectation (Carry per-node effect instances across a plan swap #1282), and two capi live tests compare six blocks after the compensation lines flush (Carry compensation lines across a plan swap #1283, widened in the fold); the review measured that each still turns red on the defect it names.Review
One opus-high review of the batch diff: PASS with findings, no blocker. Folded: both capi oracles compare six blocks after the lines flush; the render-thread pairing helpers are in realtime-policy regions; host-web's tap hand-over uses an explicit "commanded since commit" bit instead of the arm-sample-0 sentinel (new test red on the sentinel); doc fixes. The review confirmed that
apply_pendingpops nothing and that every changed oracle still tests its claim.Known defect (pre-existing), fixed by #1584 D6 as the first slice of batch 12: an acknowledged subscribe on an effect owner that restarts (a prepared change) or is removed at a swap is dropped: Observe records left in that owner's predecessor queue are never applied, and its tap starts unarmed on the successor. An ack can precede a drop. #1584 D6 arms the successor's taps at preparation, with this case as a gate.
Issues to file
None new from this batch beyond the review's successor list in the boundary report (C ABI reader pairing when capi gains meter/observation readers; #1584 D6 with the dropped-subscription gate).
Spec changes: decision records and folds on #1633, #1282, #1327, #1283, #1284, #1381; #1635-#1672 moved in; #1626-#1629, #1306, #1567, #1632 references renumbered.
🤖 Generated with Claude Code
Need help on this PR? Tag
@codesmith-botwith what you need.