Amendments to the PR #742 case file — head 02990da → 66d6af3 (+ base drift)
These are amendments only. The prior report (head 02990da, 9 files +115/−10, base f46a9922) stands except where an item below voids or revises it. Every citation re-verified against the current head this run.
Key findings (the amendments)
- New head, new size, first real discussion.
66d6af33was pushed 2026-12-05 09:19, making the branch 2 commits, +94/−21 in the same 9 files (was +115/−10). The PR now has 3 discussion entries: a case-file notice 08:55, a flare-autobot review Changes Requested 09:11 (0 blockers / 1 should-fix / 3 subtract / 4 nits), and the author's reply 09:19 which closes the should-fix. Labels:area:memory, area:preparation, area:selene, performance, triage:review. Still no maintainer comment and no CI results on the head. - VOID — old finding 5 (the
memory.rsvsmodel.rsOptionasymmetry). The value is now computed once and threaded:pub max_sequence_pages: std::num::NonZeroU64onPlannedHostBudgets(helios/src/runtime_core/memory.rs:32-36, filled at :1593-1597), passed asSome(planned.max_sequence_pages)(model.rs:1047-1053) into a newprepare_offloadparameter (model.rs:1125) and straight intoPrepareInputs(model.rs:1167-1173). The secondserver_config["max_sequence_tokens"]lookup is gone. Residual nit: the parameter is stillOption<_>, and the twoprepare_offloadtests passNone(model.rs:1562, :1574); no production path suppliesNone. - VOID —
Some(0)/context == 0(also autobot's only should-fix).contextis filtered> 0(memory.rs:993-996) and the bound isNonZeroU64::new(context.div_ceil(contract.cache.page_tokens as u64))(memory.rs:998-1000), soSome(0)is unrepresentable and selene'slimit > 0guard is redundant. The divisor is still unchecked locally at :999, butPreparedContract::validaterejectspage_tokens == 0(helios/src/model/contract.rs:536) at both entry points (helios/src/server/config.rs:214, helios/src/server/runtime.rs:956), andcapacities()re-checks (memory.rs:697) — defence in depth, so a nit, not a should-fix. - CHANGED — the double clamp is gone, so the whole charge is now capped at one point.
capture.then_some(minimum_pages)(memory.rs:1136) replaces the old.min(max_sequence_pages). The single clamp ischain_pages = inputs.max_sequence_pages.map_or(pages, |limit| pages.min(limit.get()))(selene/src/offload.rs:165-167), which now feeds both the slab sizing and the admission testif chain > budget { return Err("host budget cannot hold a full pool capture") }(offload.rs:171-177), including the first-passdevice/tier_hostcharge (memory.rs:1126-1138).capture_growth(memory.rs:1490) andplanned_offload_host(memory.rs:1554-1560) clamps are unchanged. - STRENGTHENED — the "GPU pages unchanged" claim now has an equality assertion.
pool_capture_growth_caps_at_max_sequence_pages_without_throttling_gpu_pagesassertspages == uncapped_pages(memory.rs:2463) as well aspages > max_sequence_pages(:2464). Still one synthetic core; nothing assertsplanned_offload_hostor an integrated path. - PARTIALLY ADDRESSED — the intake floor. Still uncapped in code:
chain.max(intake_slots(layout, inputs.max_active) as u64).min(budget)(offload.rs:178-180,intake_slotsoffload.rs:226-229), but now stated in prose in the doc (docs/prefix-cache-offload.md:1593-1597) and in the PR body ("remains intentionally uncapped so multi-request transfer bursts are not throttled"). The impact table still has no intake-dominated row, so a widemax_activedeployment can still size the slab above one sequence chain — disclosed, not quantified. - NEW — base drift; the PR body's base label is stale. Head is
f46a9922+66d6af33, but main fast-forwarded to012219a1(#713, Joshua Cartu, merged 2026-12-04 23:47). #713 addedLinuxMemInfo/append_integrated_meminfoand wired it into thePlan cachesummary — the same summary this PR's doc/log discussion touches, ≈+161 lines above #742's hunks.PlannedHostBudgetsis unchanged on main (:32-36) andcapture_growthis still at :667, so the rebase is mechanical but non-trivial; the body's "Executed on … basef46a99220a" and its six-crate counts now describe a pre-#713 tree. This supersedes the prior report's "single commit onf46a9922, mechanical rebase expected". - STANDS — evidence provenance, direction of change, charter fit, #160 caveat, first-time-contributor status. The RSS figures are still a
v0.6.0(f705086) build, not an A/B on the head; hardware CUDA,tests/server/test_prefix_cache_offload.py(not opened),qualify/host_cache.py(not opened), integrated, multi-host/RoCE, Windows, Kani and TLA+ remain unrun and disclosed. The push closed code findings, not the evidence gap; re-review auto-runs ~90 min after 09:19.
Detail
Scale, state and discussion (amendment 1)
- Diff now +94/−21 across the same 9 files:
docs/prefix-cache-offload.md+15/−12,helios/src/runtime_core/memory.rs+32/−1,helios/src/runtime_core/model.rs+12/−3,selene/src/offload.rs+9/−1,selene/src/offload/tests.rs+18/−4, plus 8max_sequence_pages: Nonefixtures (helios/src/offload/pool/tests.rs(not opened),selene/src/offload/sharded/tests.rs(not opened) ×4,selene-manager/tests/{client,offload}.rs). - Author reply (2026-12-05 09:19) itemises exactly four changes — thread
PlannedHostBudgets::max_sequence_pages, type the bound asNonZeroU64, single-point clamping + test cleanup, and clarifications on intake floor /selene/src/geometry.rs(not opened) / #737 — and ends with@flare-autobotto trigger a re-review.
Void items (amendments 2–3) — why they are gone
- The asymmetry existed because
prepare_offloadre-readserver_config["max_sequence_tokens"]and used.as_u64().map(..); the value is now a planned budget field, somemory.rsandmodel.rscannot disagree. context == 0producedSome(0), which selene treated as "uncapped" (limit > 0guard) — a silent semantic flip.NonZeroU64makes the state unrepresentable rather than validated.
Changed mechanism (amendments 4–5)
- One clamp, one place:
selene/src/offload.rs:165-167; the doc comment on the field states the invariant — "WhenSome(limit),pool_only()bounds its capture chain tolocal_pages.min(limit.get())because no single sequence chain exceedsmax_sequence_tokens" (selene/src/offload.rs:342-345). - Remaining clamps are the same as before:
capture_growth(layout, pages.min(max_sequence_pages.get()), …)(helios memory.rs:1490) and theplanned_offload_hostchainpages.min(max_sequence_pages.get()) + row_slots(memory.rs:1554-1560). - Test cleanup: the standalone bounded selene test is folded into
pool_only_sizes_registered_capture_and_headroom_for_local_ranks(selene/src/offload/tests.rs:525-576) with cases(10, None),(512, None),(512, Some(64))(:531-535) and a strictly-smaller assertion only in the bounded case (:558-560);prepare_with_inputs_budget_with_progressnow destructures with..(selene/src/offload.rs:622-628), so futurePrepareInputsfields will not break it. Author-reply test-count claim drops 650 → 649 (648 unit + 1 doctest).
What still stands (amendment 8)
- Direction of change: every clamp only shrinks the charge, so pool-only operators may see more GPU KV pages and startup succeeding where main failed with
host budget cannot hold a full pool capture. Now documented (docs/prefix-cache-offload.md:1599-1602), still absent from the title. - Scope/reach: pool-only single-process only — capture requires
self.cluster().is_none()(memory.rs:1002) andshard.is_none()(offload.rs:163, :700); no CLI/config/wire/core-format surface;PrepareInputsis internal Rust API. - Charter fit: line-24 goal (host prefix-cache checkpoints shared via Selene); #718's HTTP
X-Flare-Prefill-Only, scheduler checkpoint anchoring and Selene announce-barrier surface are not carried and remain unlanded. The #160 scope caveat (yatesdr ruled disaggregation out of design; the reopen request sits with @lukealonso) still frames the surrounding programme but not this diff. - Provenance of the idea: yatesdr's #455 review (2026-11-21, item 2) named the cost and asked for documentation; the cap is the author's extrapolation. AGENTS.md (not opened) evidence rules are respected in the disclosure, not in re-measurement.
Revised: #737 overlap (was finding 7 in the prior report)
Verified at pr/737 head 46e6a3b: #737 does not touch headroom_inner (selene/src/offload.rs:150-200 identical) and does not change host_pool_budget's semantics (it only adds host_pool_budget_from / _and_total_with_reserve / _with_reserve). It does change async_transfer_host_ram(host_future, apply_reserve) (helios memory.rs:41-44 in #737) and hence async_transfer_host_total, an input to host_growth (memory.rs:1483-1492) — the free-host bound this buffer is charged against. So merge order can still move the buffer's bound even though the edited functions differ. Textual conflict is small: PlannedHostBudgets fields (memory.rs:32-36) plus ~14-line offsets (headroom call 1126 vs 1140; capture_growth callback 1490 vs 1505; struct literal 1593 vs 1607). Rating stays Low, but it is not zero, and the author's "adjacent field line only" phrasing is right only about the textual conflict.
New: doc nit (amendment 12 / low)
docs/prefix-cache-offload.md:1605-1606 still says a capture with no resident ancestor "copies the full GPU chain", two sentences below the new ceiling min(GPU page capacity, ceil(max_sequence_tokens / page_tokens)) (:1595-1597) — reads as unbounded KV. Behaviour is safe (an over-long chain would drop as StoreOutcome::Oversize). The retained GLM-5.3-Flash TP4 example (:1598-1599, 11.0 GiB / 1,664 slots intake-dominated, 7.1 GiB full-chain floor) is carried verbatim from #455 and not recomputed under the cap — it incidentally illustrates the intake floor dominating.
Autobot-comment note for downstream readers
The 09:11 autobot review's merge-risk section is labelled "up to 02990da" and quotes +115/−10, i.e. it reviews the pre-66d6af3 tree; its "0 blockers / 1 should-fix" therefore does not describe the current head, where the should-fix is closed. The review did confirm charter and security screens passed and correctly flagged #737.
Open questions / not found
- No organic demand: no issue reports
host budget cannot hold a full pool capture; the only nearby issue is #160 (disaggregation, closed). Unchanged by this push. - No maintainer review of the new head, no CI check runs, no re-review result yet — the ~90-minute auto re-review after 09:19 had not appeared at the time of writing.
- Not verified: whether the capped slab is large enough for the widest in-repo local
max_activedeployment (intake floor still dominates and is unquantified in the PR's impact table), and whether the stale base label affects the six-crate test claims (#713 landed before those runs were reported, so the claim is plausible but not independently checkable).