#1 [high] Change: what PR #742 does, size, and how the cap flows
PR #742 "selene,helios: bound pool-only capture buffer to max_sequence_pages", author fakoli (FIRST_TIME_CONTRIBUTOR), open, ready for review, opened 2026-12-05, head 02990da, base main f46a99220a. 9 files, +115/-10. No comments/reviews, no CI checks.
Change in code (verified in diff, result 1):
- selene/src/offload.rs:165-171 headroom_inner (pool-only capture branch) now computes
chain_pages = match inputs.max_sequence_pages { Some(limit) if limit > 0 => pages.min(limit), _ => pages }before addinglayout.row_slots().Some(0)andNonestay uncapped (= previous behaviour). - selene/src/offload.rs:340-346 new field
pub max_sequence_pages: Option<u64>on PrepareInputs with doc comment. - selene/src/offload.rs:628 destructuring in prepare_with_inputs_budget_with_progress ignores the field (
max_sequence_pages: _) — it only reaches sizing through headroom_inner(effective.headroom_inner(..., inputs, local_pages, host_budget)) at offload.rs:704-710, which both sizes the slab bytes (offload.rs:711-714) and validates the "host budget cannot hold a full pool capture" check (offload.rs:176-178). - helios/src/runtime_core/memory.rs:996
max_sequence_pages = context.div_ceil(contract.cache.page_tokens as u64)where context = server_config["max_sequence_tokens"] (required, errors if absent). - memory.rs:1130 passes Some(max_sequence_pages); memory.rs:1132
capture.then_some(minimum_pages.min(max_sequence_pages))replacescapture.then_some(minimum_pages)(this local_pages arg is the pool-capturelocal_pagesin headroom_inner). - memory.rs:1486
capture_growth(layout, pages.min(max_sequence_pages), ...)in the capacities() growth callback. - memory.rs:1552-1555
planned_offload_hostchain_bytes usespages.min(max_sequence_pages). - helios/src/runtime_core/model.rs:1155-1157
max_sequence_tokens.as_u64().map(|c| c.div_ceil(page_tokens))— NOTE: Option here, so if server_config lacks max_sequence_tokens the runtime attach path stays uncapped, unlike memory.rs which hard-errors. - docs/prefix-cache-offload.md pool-only capture buffer section rewritten to document
min(GPU page capacity, ceil(max_sequence_tokens / page_tokens))+ one row, keeping GLM-5.3-Flash TP4 11.0 GiB/1,664 slots and 7.1 GiB floor example andhost budget cannot hold a full pool capturefailure text. - Tests: selene/src/offload/tests.rs:566-620 pool_only_caps_capture_buffer_to_max_sequence_pages; helios memory.rs:2440-2457 pool_capture_growth_caps_at_max_sequence_pages_without_throttling_gpu_pages; plus
max_sequence_pages: Noneadded to 8 existing PrepareInputs fixtures (helios/src/offload/pool/tests.rs:134, helios memory.rs:2031, selene/src/offload/tests.rs:14,51, sharded/tests.rs x4, selene-manager/tests/client.rs:3255,3509, offload.rs:139).
#2 [high] Related work: closed #718 is superseded by #742; #742 takes only its pool_only() part
#718 "helios,selene,selene-manager: add prefill-only KV handoff, announce barrier, and bounded pool-only capture" by fakoli, +1134/-57 over 32 files, opened 2026-12-04, CLOSED (not merged) 2026-12-05 08:52. Labels: area:api, area:memory, area:selene, enhancement, performance, triage:design-review. #742's body says "Supersedes the bundled pool_only() change previously included in closed #718." and the local index records #742 as referring to #718 ("this closes").
#718's scope that #742 does NOT carry (so those parts are currently unlanded/abandoned):
- helios/src/server/http.rs +232:
X-Flare-Prefill-Onlyheader on /v1/chat/completions, /v1/completions, /v1/messages, /v1/responses (400 on duplicate/malformed, 400 on count_tokens and multi-prompt batches), JSONobject: "prefill"response with X-Flare-Pool-Announced / X-Flare-Checkpoint-Key, docs/api.md +39. - helios/src/scheduler.rs, scheduler/checkpoints.rs:
prefill_onlyon runtime::Prompt/RequestSpec/LiveRequest, checkpoint_anchor() = prompt_tokens, checkpoint_key(CheckpointId), pending_prefill_finishes, GenerationEvent::Finished reason "prefill". - selene/src/pool/*, selene-manager/src/pool/lookup.rs: HostStore::announce_gpu, HostStore::announce_barrier/AnnounceTicket, PoolClient::announce_barrier with ANNOUNCE_BARRIER_TIMEOUT=5s, empty-boundary WireLookupRequest sentinel, gpu_index_entry refactor.
- docs/prefix-cache-offload.md note in #718 was about selene-manager Arena power-of-two
--staging(e.g.--staging 16Gto avoid NoWindows) — a DIFFERENT doc edit from #742's.
#718's own claimed pool_only() numbers differ from #742's: on JMNI-Labs/Inkling-2-Mini-FLARE, 1M ctx, RTX PRO 6000 96 GiB, capture went from ~33 GiB to 9.1 GiB / 8,293 slots, combined RSS 46.02 -> 41.77 GiB. #742 claims 11.8 GiB / 16,475 slots for Qwen4-35B-A3B with 24 GiB container limit. Different model/hardware, so not directly contradictory, but the two bodies report different hardware/container limits for what is described as the same patch.
#718 discussion: two flare-autobot comments only — (1) case file opened; (2) "Review Stopped: Auto-Review halted due to finding: It is low value or does not align with the project charter" with a Value Proposition Report link (autobot.eidonix.com/p/1cf7d0ca...). #718 referred to #714 (closed), #716 (merged), #720 (merged), #721 (merged); referred to by #715 (open) and #742 (open).
#3 [high] Community: #160 scope thread — maintainer ruled disaggregation out of scope; #742 is presented as the in-scope remnant
#160 "Roadmap question: prefill/decode disaggregation roles, now that the prefix cache pool exists?" by JCTaz9, opened 2026-10-31, CLOSED 2026-11-18 by yatesdr: "prefill/decode disaggregation is outside Flare's design. docs/core-design.md (lines 347-348) states 'Disaggregated prefill ... outside this design', and request routing across instances ... is cluster orchestration, which AGENTS.md ... reserves for an explicit maintainer decision. To reopen, attach the benchmark and request a scope decision from the project owner, Luke Alonso."
The same thread was REOPENED-in-substance by fakoli on 2026-12-05 08:52 (same day #742 opened) with 1P1D measurements and an explicit scope question to @lukealonso, including the line: "(Note: I closed #718 and split out the charter-aligned #455 pool_only() capture-buffer bound by itself into https://github.com/NVIDIA/hyperflare-inference/pull/742.)" and three options (announce-barrier primitive only / minimal prefill-only mode / out of scope, keep selene contributions to pool sizing and shared prefix caching).
So: the author frames #742 as the deliberately narrow, charter-aligned remnant of the disaggregation work. The maintainer's stated preference (option 3 territory) is "keep upstream selene contributions scoped to pool sizing and shared prefix caching" — that is exactly what #742 does.
Link: #160 mentions #455, #718 (closes) and #742; #718 and #742 both mention #160.
#5 [high] People: fakoli first-time contributor; yatesdr owns the code and raised this exact cost in #455 review; lukealonso is project owner
- fakoli: FIRST_TIME_CONTRIBUTOR. In the last 180 days in this repo: 0 merged, 0 closed, 1 open — #718 (closed 2026-12-05) and #742 (the PR under review). No commits on main in selene/src, helios/src or docs (authors there: Luke Alonso 249 helios commits, yatesdr 38 selene commits/52 helios, Martin Vit, Joshua Cartu).
- fakoli is the author of both #718 (closed) and #742 and of the 2026-12-05 reply on closed #160. Discord: fakoli (per AGENTS.md contact-line rule).
- Area owners who will recognize the code: yatesdr wrote #455 (the pool-only capture buffer this PR modifies: offload.rs:77-83 at the time,
capture.then_some(minimum_pages)), #497 (planned_offload_host / pool-only restore-only), #674, #92 (the pool itself). Luke Alonso is named as "the project owner" by yatesdr in #160; he owns AsyncTransfer/#711/#721/#737 which touch the same host-budget functions (host_pool_budget_and_total, planned_host_future). - yatesdr's #455 review (2026-11-21) is the direct origin of the concern this PR answers: "Pool-only now reserves host memory, and can now fail to start. The capture buffer holds the largest GPU page capacity plus one row ... so it is about the size of the GPU KV cache in registered host memory." #455 resolved it by documenting the size and the failure, not by capping; #742 caps.
- Engagement on #742 so far: none — 0 comments, 0 reviews, no labels, no CI checks (orientation packet; pr_comments returned "No comments").
- Prior art of the same author being halted: flare-autobot "Review Stopped: It is low value or does not align with the project charter" on #718 (2026-12-04 17:28). #742 has no autobot case file comment yet at head 02990da.
#6 [high] Claims and evidence: intake floor not capped; RSS numbers not A/B'd on the head commit; no CI; model.rs path untested
Claims in #742's description and what backs them (verified against the diff and repo):
- "host capture memory stays proportional to one max_sequence_tokens chain" — true for the chain term only. The slab is
chain.max(intake_slots(layout, max_active)).min(budget)(selene/src/offload.rs:179-181), so automatic intake (2max_activerow_slots + 2*WINDOW_PAGES, offload.rs:227-229) is a floor that is NOT capped, exactly as docs/prefix-cache-offload.md:1593-1600 now says ("the larger of automatic intake and one full single-sequence capture chain"). For high max_active the buffer can still exceed one chain. - Table: "Allocated GPU KV capacity 99,008 pages (70.9 GiB) unchanged" — the diff does not change KV sizing inputs other than the headroom local_pages clamp (memory.rs:1132) and capture_growth clamp (memory.rs:1486), both of which can only relax the host-driven limit, so "unchanged/unthrottled" is consistent with the code direction. The helios test
pool_capture_growth_caps_at_max_sequence_pages_without_throttling_gpu_pages(memory.rs:2440-2457) asserts onlypages > max_sequence_pageson one synthetic core, not EQ of page counts. - "18.74–19.06 GiB vs 7.83–8.04 GiB container RSS" delta matched to slab delta — the PR itself discloses these were observed "on a v0.6.0 (f705086) build carrying this exact patch rather than re-measured via an A/B restart on f46a99220a". So the live evidence is not an A/B on the PR head against base.
- Six-crate release test counts (12/650/448/2041/255/254) — described as executed on head 02990da in rust:1.94.1-slim-trixie; not independently visible (no CI checks on the head commit). helios run required FLARE_TEST_TEMPLATE_DIR prepared for 7 model aliases; eos was re-run single-threaded after a timing flake (
adaptive_mid_mapping_fallback_merges_into_single_vma), which the PR discloses. - Unrun: hardware CUDA tests, tests/server/test_prefix_cache_offload.py, qualify/host_cache.py, integrated/unified-memory hosts, multi-host sharded/RoCE, native Windows, Kani and TLA+ (argued not applicable: PR does not touch scheduler/cache_memory, lifecycle state machines or Kani-proven validators — consistent with .github/workflows/helios-lifecycle.yml which runs TLA+/Kani on helios/, selene/, selene-manager/** changes; that workflow's paths filter does match this PR, so CI would run it on the head commit if triggered).
- No test exercises the helios
model.rswiring (theOption-mapped value) nor asserts thepool only: capture buffer …log line; the two new tests exercise headroom_inner and capture_growth in isolation. - Description says it supersedes the pool_only() change from closed #718 — #718 carried a near-identical capture bound (its own text:
local_pages.min(limit)whenlimit > 0) plus HTTP/scheduler/pool primitives that #742 does not carry.
#7 [high] Project fit: charter goal 24 (host prefix cache via Selene) and AGENTS.md evidence rules; maintainer request origin in #455 review
Charter (read_charter) status line 24: goal "* Store prefix-cache checkpoints in host memory and share them across Flare instances via Selene." Charter "What gets merged": PRs addressing a maintainer request, roadmap item, reproducible bug, measured performance/memory issue, or bad docs. This PR is framed as a measured memory issue (host RSS) and as the follow-up to a maintainer review comment (yatesdr in #455), and is deliberately restricted to pool sizing after #718's prefill-only HTTP surface was pushed back as out-of-scope disaggregation (#160 close reason; #718 close comment).
Charter/docs tensions:
- AGENTS.md:165-169 "Every contribution must address an explicit maintainer request, a demonstrated defect, a measured performance or memory problem, or inaccurate documentation." The explicit maintainer request is yatesdr's #455 review item 2 (2026-11-21) — it asks to give the buffer's size and state the failure case in docs, not to cap. The cap itself is the author's proposal.
- AGENTS.md:95-101 (claimed benefit) and :103-112 (evidence, "Never invent evidence") — #742 discloses its provenance/non-A/B nature, which lines up with :105-108 (state what remains untested) and with docs/design-review.md:153-155.
- AGENTS.md:171-175 "Reject unapproved scope expansion ... general-purpose cluster orchestration require an explicit maintainer decision." #742 contains no routing/API surface, so it does not itself expand scope; the surrounding disaggregation programme is still pending the @lukealonso decision requested in #160 (2026-12-05).
- Self-consistency with docs: the repo doc treating "known limitations" is docs/prefix-cache-offload.md:1847-1858 and "designed, not implemented" :1860+; the PR updates only the 2.15 pool section (lines ~1593-1608). Remaining stale statement: docs/prefix-cache-offload.md:612 mentions pool-only capture buffers drop ... (not a sizing statement) — no contradiction found.
- Single-host constraint: capture only applies when
self.cluster().is_none()(memory.rs:998) andshard.is_none()(offload.rs:700), so multi-host behaviour is unchanged by design, consistent with docs/prefix-cache-offload.md:1608 "With separate rank processes, a pool without a local disk tier only restores." - No per-model branches, no new flags, no new defaults: the change is model-agnostic and introduces no user-visible option (PrepareInputs is an internal Rust struct). This matches charter "No per-model special cases or flags".
#8 [high] Reach: pool-only single-process users only; may now admit MORE GPU pages and pass startup where main failed; internal API field added
Reach / impact of #742:
- Users affected: single-process (one process, all ranks) deployments using
--prefix-cache-poolwith--prefix-cache-memory 0and no local disk tier, i.e.PrefixCacheOffload::pool_only()(selene/src/offload.rs:116-118). With a pool + any memory or disk tier, nothing changes (the cap is insideheadroom_inner'scapturebranch only, offload.rs:163-181; disk branch :182-196 untouched). - Effect on GPU KV capacity:
capture.then_some(minimum_pages.min(max_sequence_pages))(memory.rs:1132) feedsheadroom_inneras local_pages for the pool capture, andcapture_growth(layout, pages.min(max_sequence_pages), …)(:1486) is the host-budget term incapacities()(:749-760). Reducing those terms can only let the capacity search admit MORE pages, never fewer: it removes host budget as a KV throttle once one sequence chain fits. So operators may see a larger KV allocation on hosts whose budget previously limited pages - visible in thePlan cachesummaryper GPU: … KV pagesline. - Startup behaviour change: the
host budget cannot hold a full pool capturefailure (selene/src/offload.rs:176-178) now triggers only if the capped chain (max_sequence_pages + one row) does not fit the host budget, instead of the full GPU page capacity. Startup that failed on main can now succeed — a user-visible behaviour change beyond "smaller buffer". - New startup log expectation: summary line
pool only: capture buffer N GiB (… slots, populate …, register …)(selene/src/offload.rs:450-461, mode chosen when intake_slots()==0). The PR's evidence quotes exactly this line. - API/compat:
PrepareInputsgains a public field (selene/src/offload.rs:340-346). selene is not published ("crates aren't published yet", charter roadmap #6), so no external semver break; all in-repo callers were updated (8 fixtures + 2 production sites). Any out-of-tree caller constructing PrepareInputs without..Default::default()breaks at compile time. - No config-file/CLI/documented-default change; no dependency change; no docs/defaults touched outside docs/prefix-cache-offload.md:1593-1608.
- Deployment: matters for container memory limits (PR's 24 GiB cgroup example) and for hosts where the GPU holds multiple full sequences (quantized models, 96 GiB workstation cards, 1M contexts) — exactly the compact-workstation audience the charter names.
- Edge cases:
Some(0)/Nonekeep old unbounded sizing (offload.rs:165-168, documented in the field doc comment);max_sequence_pagesderives from max_sequence_tokens which for a small runtime override (e.g.--max-sequence-tokenssmaller than the core's) shrinks the buffer; server_config value is the prepared ceiling (helios/src/server/config.rs:131-148).
#9 [high] Related work: builds on #455/#497; overlaps open #737 in the same budget functions; #718 superseded; #705 Slabs path relevant
Related / overlapping work on the same code (all in helios/src/runtime_core/memory.rs + selene/src/offload.rs, host-budget and capture sizing):
- #455 (merged 2026-11-22, yatesdr): created the pool-only capture buffer,
capture.then_some(minimum_pages)in memory.rs and the pool-only branch in offload.rs; its review is the origin of this PR (see people note). #742 edits exactly the lines #455 added. - #497 (merged, FujitsuPolycom/PCCessna): "pool-only capture retain the pre-planned planned_offload_host budget without post-KV-allocation shrinkage" — #742 also edits planned_offload_host (memory.rs:1550-1556). Need to check for conflict: #742 only adds
.min(max_sequence_pages)to the existing expression, so it is additive. - #737 (OPEN, lukealonso, +1769/-268, opened 2026-12-05 03:33): adds
host_pool_budget_and_total_with_reservein selene/src/offload.rs (+7/-1), rewritesasync_transfer_host_ram/--pool-ram-memoryhost-wide and peer-UVA accounting in helios/src/runtime_core/memory.rs (+88/-29) and model.rs (+29/-1). Same files, adjacent functions (host budget helpers used by headroom_inner'sbudget_overridepath, memory.rs:972-982host_budget_for). Real merge-conflict/merge-order risk with #742, and it changes what "host budget" means for the same capture buffer. #737 is also the only other open PR touching these files for the same reason (host memory budgeting). - #711, #721, #727 (lukealonso, merged): AsyncTransfer + device pools, planned_host_future / host_future coordination — the host budget that bounds this capture buffer is computed through those paths (memory.rs:1266, 1339-1370).
- #674 (merged, yatesdr): prefix-cache hit rate / L1 retention / GPU snapshot packing — touched offload.rs and memory.rs
capture_growth/planned_offload_hostarea; #455's later work built on it. - #625 (merged): offload startup timings (
PrepareTimings: slab_populate / cuda_register) — the timings quoted in the PR's log line come from it. - #705 (merged 2026-12-05, Joshua Cartu): Retry(Slabs) CPU storm fix — relevant because a too-small capture buffer surfaces as Retry(StoreReason::Slabs) (selene/src/memory.rs:857-860, composite.rs:2027/2053), the path a cap could stress under concurrent captures.
- #694 (merged, yatesdr): spill profitability gate, in the same selene offload area.
- #589 (merged, lukealonso): Selene unified-memory budgeting + host_pool_budget* helpers.
- Superseded/competing proposals by the same author: #718 (closed; carried the same cap inside a much larger diff; autobot stopped review as out-of-charter). No other PR proposes the same cap.
- Nothing found that is undone by #742: no other open PR caps the capture buffer; no revert pending.
#12 [high] Why: slab sized to whole-GPU KV, flagged in #455 review 2026-11-21; no issue filings; single author driving it
The why, and its history:
- Concrete defect #742 targets: with
--prefix-cache-pool+--prefix-cache-memory 0+ no disk, selene sizes the CPU-readable capture slab tolocal_pages + row_slotswhere local_pages = largest GPU page capacity in the process (selene/src/offload.rs:163-181 vialocal_pagesfrom offload.rs:700, max across ranks). Helios then charges that slab as host memory and, if it does not fit the host budget, either limits GPU page capacity (memory.rs capture_growth in capacities()) or fails startup with "host budget cannot hold a full pool capture" (offload.rs:176-178). - Where the requirement came from: yatesdr's #455 review item 2 (2026-11-21) — "Pool-only now reserves host memory, and can now fail to start ... it is about the size of the GPU KV cache in registered host memory ... Please give the buffer's size for the measured configuration, and state the failure case". #455 then documented size (11.0 GiB / 1,664 slots, 7.1 GiB floor for GLM-5.3-Flash NVFP4 TP4) and the failure in docs. So the problem has been visible since 2026-11-21 (≈2 weeks before this PR) and the doc text #742 rewrites was written in #455 (merged 2026-11-22).
- The author's own statement of the problem: #718 body item 3 (~33 GiB on an RTX PRO 6000 96 GiB for 1M-context cores) and #742 body (24 GiB container limit for Qwen4-35B-A3B; 70.7 GiB capture vs 11.8 GiB bounded).
- No user-filed issue reports this failure: searches for pool-only capture size ("pool only capture buffer host budget", "host budget cannot hold a full pool capture", "pool_only capture slab oversized host memory pool only" as issue kind) returned only PRs — #455, #718, #742, #497, #737. The only issue in the neighbourhood is #160 (disaggregation, closed/out of scope).
- How widely wanted: one author, one prior attempt (#718, closed), one maintainer remark. Not a recurring community request in the last 30+ days of local search.
- Why it matters more now: #711/#721/#737 moved host-budget accounting (UVA page tables, host-wide --pool-ram-memory), so registered host memory is contested on the same hosts; a slab sized to whole-GPU KV competes with those pools. Charter names SM120/SM121 workstation and DGX Spark as the target hardware, where host RAM is the constraint.
#13 [high] Research summary
Case file for PR #742 (fakoli, open, ready for review, head 02990da on base f46a9922, 9 files +115/−10, no CI checks, no comments or reviews). Twelve scratchpad entries cover all eight angles.
Key findings: (1) The PR is a one-commit extraction of the pool_only() capture-buffer bound that was bundled into #718, which the author closed on 2026-12-05 after autobot stopped its review for charter fit; #742 deliberately drops #718's HTTP/scheduler/pool-announce surface, which is still the subject of an open scope request to @lukealonso on closed issue #160. (2) The concern is not new: yatesdr's #455 review (2026-11-21) item 2 named exactly this cost ("about the size of the GPU KV cache in registered host memory") and asked for documentation, which #455 delivered; #742 changes that documented behaviour by capping. (3) Undeclared-in-headline effects I verified in code: the automatic-intake floor is not capped (offload.rs:179-181), and the clamps at memory.rs:1132/1486 can only relax host-driven KV throttling, so operators may see more GPU pages and startup succeeding where main failed (host budget cannot hold a full pool capture). (4) Real overlap/conflict risk with open #737 (lukealonso), which rewrites the same host-budget helpers and async_transfer_host_ram in the same two files. (5) Evidence gaps the PR itself discloses: the 18.7 vs 7.8 GiB RSS figures were not re-measured A/B on the head commit, no hardware CUDA/multi-host/Windows/Kani runs, and no test covers the new model.rs wiring.
Scratchpad holds the diff/file:line map, the #455→#718→#742 chronology, related-PR conflict notes (#455/#497/#737/#705/#711/#721), people and area-owner facts, charter/AGENTS.md mappings, reach/impact, claims-versus-evidence breakdown, and process state.
#14 [high] The change: description vs diff — precise on files/tests, understates the local_pages semantics and the model.rs Option asymmetry
Checked the #742 description against the diff; the description is unusually accurate for this PR, with these precise refinements a reader should know:
- Description: "Updated
prepare_with_inputs_budget_with_progressfor the new field." The diff does the minimum: the destructuring at selene/src/offload.rs:623-629 binds it asmax_sequence_pages: _, i.e. it is ignored there. The field only takes effect througheffective.headroom_inner(..., inputs, local_pages, host_budget)at selene/src/offload.rs:703-710, which both sizes the slab (bytesat :711-714) and performs thehost budget cannot hold a full pool capturecheck. So there is exactly ONE place the cap is applied in selene. - Description does not mention that the second helios call site handles a missing value differently from the first: helios/src/runtime_core/memory.rs:992-996 hard-errors when
server_config["max_sequence_tokens"]is absent ("model requires a prepared context ceiling") and always passesSome(...), while helios/src/runtime_core/model.rs:1155-1157 uses.as_u64().map(...)and passesNone(uncapped) if absent. In practice both read the same server_config (helios/src/server/config.rs:131-148), so None should not occur on the model path; it is still an undeclared asymmetry. - Description's "clamped the
minimum_pagesheadroom check asminimum_pages.min(max_sequence_pages)" is accurate but understates it: that argument is thelocal_pagesthatheadroom_innertreats as GPU page capacity for the capture branch, so the clamp changes both the slab size and the startup-failure threshold, not only "the check". - Description's claim "Passed
max_sequence_pagesin bothmemory.rsplanning andmodel.rshost offload preparation" is accurate (memory.rs:1130, model.rs:1168). - Description's test inventory matches the diff exactly: 1 new selene test, 1 new helios test, 8
max_sequence_pages: Nonefixture additions (helios/src/offload/pool/tests.rs:134; helios/src/runtime_core/memory.rs:2031; selene/src/offload/tests.rs:14,51; selene/src/offload/sharded/tests.rs:118,261,392,558; selene-manager/tests/client.rs:3255,3509; selene-manager/tests/offload.rs:139 — 11 insertion points across those files). - The description does not say, and the diff does not do, anything about the
intake_slotsfloor:chain.max(intake_slots(layout, max_active)).min(budget)(selene/src/offload.rs:179-181) means the buffer can still be larger than one sequence chain when max_active is high. The docs sentence ("larger of automatic intake and one full single-sequence capture chain") does say it; the PR's headline table does not show an intake-dominated case. - No public CLI/config/default changes and no dependency changes;
PrepareInputs(selene/src/offload.rs:330-347) is internal Rust API.
#17 [high] Amendments 2026-12-05 (head 66d6af3, +94/−21): what changed since the run-3699 report and what still stands
AMENDMENTS to report #16 (PR #742), after fakoli pushed 66d6af33 on 2026-12-05 ~09:19 and replied.
- Head/size/state changed.
- Head 02990da -> 66d6af3 (2 commits). Diff now +94/−21 across the same 9 files (was +115/−10): docs/prefix-cache-offload.md +15/−12, helios/src/runtime_core/memory.rs +32/−1, model.rs +12/−3, selene/src/offload.rs +9/−1, selene/src/offload/tests.rs +18/−4, plus 8
max_sequence_pages: Nonefixtures. PR description rewritten; evidence section now says tests were run on head 66d6af3. - Discussion count on the PR is now 3 (case-file notice 08:55, autobot review "Changes Requested" 09:11, author reply 09:19). Still no maintainer comment. Labels: area:memory, area:preparation, area:selene, performance, triage:review.
- FIXED — the memory.rs/model.rs
Optionasymmetry (old report finding 5).
PlannedHostBudgetsnow carriespub max_sequence_pages: std::num::NonZeroU64(helios/src/runtime_core/memory.rs:34), is filled at memory.rs:1595, and is threaded intoprepare_offload(..., Some(planned.max_sequence_pages))(model.rs:1047-1053) as a new parameter (model.rs:1125) passed straight intoPrepareInputs(model.rs:1167-1173). The secondserver_config["max_sequence_tokens"]lookup fromprepare_offloadis gone. Residual: the parameter is stillOption<_>and the two model.rs tests passNone(model.rs:1562, :1574); no production path suppliesNone.
- FIXED —
Some(0)/context == 0(was autobot's only "should fix", my report noted the dead branch and the intake floor).
contextis now.filter(|&tokens| tokens > 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 thelimit > 0guard in selene is redundant.- Residual, defense-in-depth only: the divisor
contract.cache.page_tokensat memory.rs:999 is still not checked locally, butPreparedContract::validaterejectspage_tokens == 0(helios/src/model/contract.rs:536) and both server entry points run it (helios/src/server/config.rs:214, helios/src/server/runtime.rs:956) beforeallocate_caches;capacities()also rejectspage_tokens == 0(memory.rs:697). Note the cap derives fromcontract.cache.page_tokenswhilecapacitiesis driven byserver_config["page_tokens"](memory.rs:896) — two fields, same value in valid cores.
- CHANGED —
minimum_pages.min(max_sequence_pages)at the headroom call was removed.
- Now
capture.then_some(minimum_pages)(memory.rs:1136); the only clamp ischain_pages = inputs.max_sequence_pages.map_or(pages, |limit| pages.min(limit.get()))(selene/src/offload.rs:165-167), so both the slab size (offload.rs:168-180) and thehost budget cannot hold a full pool captureadmission test (offload.rs:171-177) see the capped chain from one point. The first-passdevice/tier_host(memory.rs:1126-1138) therefore also charge the capped chain. Other clamps unchanged:capture_growth(layout, pages.min(max_sequence_pages.get()), ...)(memory.rs:1490) andplanned_offload_hostchain (memory.rs:1556-1557).
- STRENGTHENED evidence for "GPU pages unchanged".
- helios test
pool_capture_growth_caps_at_max_sequence_pages_without_throttling_gpu_pages(memory.rs:2445-2465) now assertspages == uncapped_pages(memory.rs:2463) pluspages > max_sequence_pages(:2464); previously only>. Still one synthetic core, and nothing assertsplanned_offload_hostor the selene slab in an integrated path.
- CHANGED tests.
- The standalone selene test
pool_only_caps_capture_buffer_to_max_sequence_pagesis gone; the bounded case is folded intopool_only_sizes_registered_capture_and_headroom_for_local_ranks(selene/src/offload/tests.rs:525-576) with (10, None), (512, None), (512, Some(64)) (:531-535) and the extra assertionslots < intake_slots(layout,4).max(pages+row_slots)(:558-560).prepare_with_inputs_budget_with_progressnow destructures with..(selene/src/offload.rs:622-628), so futurePrepareInputsfields won't break it.
- PARTIALLY addressed — intake floor (my "undeclared effect" (a)).
- Still uncapped in code:
chain.max(intake_slots(layout, inputs.max_active) as u64).min(budget)(selene/src/offload.rs:178-180, intake_slots :226-229). But it is now stated in prose both in the doc (docs/prefix-cache-offload.md:1594-1597) and in the PR body ("intake_slots ... remains intentionally uncapped so concurrent active transfers are not starved"). The impact table still has no intake-dominated row, so a wide-max_activedeployment can still size the slab above one chain — disclosed, not quantified.
-
STILL OPEN — direction of the change (unchanged): every clamp only shrinks the charge (offload.rs:165-168, memory.rs:1490, :1556-1557), so pool-only operators may see more GPU KV pages and startup succeeding where main errored with
host budget cannot hold a full pool capture. Doc now says so (docs/prefix-cache-offload.md:1599-1602). Not in the title. -
#737 overlap — author's claim checked against pr/737 head 46e6a3b, and it is accurate in the narrow sense but not the wide one.
- #737 does NOT touch
headroom_inner(selene/src/offload.rs:150-200 identical in pr/737) norhost_pool_budget's semantics (host_pool_budgetstill delegates tohost_pool_budget_with_reserve(future, true), selene/src/offload.rs:973-994 in pr/737; it only addshost_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 pr/737) and henceasync_transfer_host_total, which is an input tohost_growth(memory.rs:1483-1492) — i.e. the free-host boundcapture_growthis charged against. So merge order affects the buffer's bound, just not the two functions #742 edits. - Conflict is textual and small:
PlannedHostBudgetsgains #742's field next to #737's unchanged two (memory.rs:32-35), and line offsets in the shared regions differ by ~14 lines (e.g. headroom call 1126 here vs 1140 in #737; capture_growth callback 1490 vs 1505; struct literal 1593 vs 1607). Mechanical rebase.
- STILL OPEN — evidence provenance. RSS telemetry is still the v0.6.0 (f705086) build, not an A/B on the new head (PR Evidence, "Live startup and memory telemetry provenance"); hardware CUDA / tests/server/test_prefix_cache_offload.py / qualify/host_cache.py / integrated / multi-host / Windows / Kani / TLA+ still unrun and disclosed; the six-crate runs are now claimed on 66d6af3 (selene 649 = 648 unit + 1 doctest, was 650 in the previous claim). No CI results are referenced for 66d6af3. A re-review is due ~90 min after the 09:19 push.
#20 [high] Research summary
Amendments to report #16 — PR #742, head 02990da → 66d6af3
New: branch push 66d6af33 (2026-12-05 09:19) plus an author reply; and main has advanced under the branch.
1. Scale/state. 2 commits now, +94/−21 in the same 9 files (was +115/−10): docs/prefix-cache-offload.md +15/−12, helios/src/runtime_core/memory.rs +32/−1, model.rs +12/−3, selene/src/offload.rs +9/−1, selene/src/offload/tests.rs +18/−4, 8 max_sequence_pages: None fixtures. Labels area:memory, area:preparation, area:selene, performance, triage:review. 3 discussion entries: case-file 08:55, autobot review Changes Requested 09:11 (0 blockers / 1 should-fix / 3 subtract / 4 nits), author reply 09:19. Still no maintainer comment and no CI results on the head.
2. Fixed — the memory.rs vs model.rs Option asymmetry (old finding 5). PlannedHostBudgets now carries pub max_sequence_pages: NonZeroU64 (memory.rs:34), set at :1595, threaded into a new prepare_offload parameter (model.rs:1047-1053, :1125) and straight into PrepareInputs (model.rs:1167-1173). The duplicate server_config["max_sequence_tokens"] lookup is gone. Residual: the parameter stays Option, and the two prepare_offload tests pass None (model.rs:1562, :1574).
3. Fixed — Some(0)/context == 0 (autobot's only should-fix, and my dead-branch note). context is filtered > 0 (memory.rs:993-996); the bound is NonZeroU64::new(context.div_ceil(contract.cache.page_tokens as u64)) (memory.rs:998-1000), so Some(0) is unrepresentable and selene's limit > 0 guard is redundant. The divisor is still unchecked at :999, but PreparedContract::validate rejects page_tokens == 0 (helios/src/model/contract.rs:536) at both entry points (helios/src/server/config.rs:214, helios/src/server/runtime.rs:956) and capacities() re-checks (memory.rs:697) — defended, so this is now a nit, not a should-fix.
4. Changed — the double clamp is gone. minimum_pages.min(max_sequence_pages) at the headroom call was removed (memory.rs:1136). The single clamp is chain_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 bytes (:168-180) and the host budget cannot hold a full pool capture admission test (:171-177), including the first-pass device/tier_host charge (memory.rs:1126-1138). capture_growth (:1490) and planned_offload_host (:1556-1557) clamps unchanged.
5. Strengthened — "GPU pages unchanged". The helios test now asserts pages == uncapped_pages (memory.rs:2463) as well as pages > max_sequence_pages (:2464). Still one synthetic core; nothing asserts planned_offload_host or an integrated path.
6. Changed tests. The standalone selene bounded test is folded into pool_only_sizes_registered_capture_and_headroom_for_local_ranks (selene/src/offload/tests.rs:525-576), cases (10,None) (512,None) (512,Some(64)) (:531-535) plus slots < … (:558-560); destructure now uses .. (selene/src/offload.rs:622-628). Test count claim drops 650 → 649 (648 unit + 1 doctest).
7. Partially addressed — the intake floor (my undeclared effect (a)). Still uncapped in code: chain.max(intake_slots(layout, inputs.max_active) as u64).min(budget) (selene/src/offload.rs:178-180, intake_slots :226-229), but now stated in the doc (docs/prefix-cache-offload.md:1594-1597) and the PR body. The impact table still has no intake-dominated row, so wide max_active can still size the slab above one chain — disclosed, not quantified.
8. Still open — direction of the 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 not in the title.
9. Revised — #737 overlap: right narrowly, wrong broadly. 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 (:973-994; it only adds host_pool_budget_from/_and_total_with_reserve/_with_reserve). But it does change async_transfer_host_ram(host_future, apply_reserve) (helios/src/runtime_core/memory.rs:41-44 in #737), and async_transfer_host_total feeds host_growth (memory.rs:1483-1492) — the free-host bound this buffer is charged against. So merge order moves the buffer's bound even though the two edited functions don't. Conflict is textual and small: PlannedHostBudgets fields (memory.rs:32-35) plus ~14-line offsets (headroom call 1126 vs 1140; capture_growth callback 1490 vs 1505; struct literal 1593 vs 1607) — mechanical, risk stays Low.
10. New — base drift; the PR body's base label is stale. Head is 2 commits on f46a9922, but main fast-forwarded to 012219a1 (#713, Joshua Cartu, merged 2026-12-04 23:47). #713 added LinuxMemInfo/append_integrated_meminfo at main helios/src/runtime_core/memory.rs:193-300 and wired it into the Plan cache summary (main :1562-1563) — the same summary this PR's docs/log discussion touches, ~+161 lines of drift above #742's hunks. PlannedHostBudgets is unchanged on main (:32-35) and capture_growth is still at :667, so the rebase is mechanical but non-trivial, and the body's "Executed on … base f46a99220a" plus the six-crate counts now describe a pre-#713 tree.
11. Still open — evidence provenance. Unchanged except the head label: RSS 18.74–19.06 vs 7.83–8.04 GiB is still the v0.6.0 (f705086) build, not an A/B on 66d6af3; 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 due ~90 min after 09:19.
12. New small doc nit. 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 min(GPU page capacity, ceil(max_sequence_tokens / page_tokens)) ceiling (:1595-1597). Harmless in behaviour (an over-long chain would drop as StoreOutcome::Oversize, selene/src/memory.rs:4183-4190 (not opened)) but reads as unbounded KV. The retained GLM-5.3-Flash example (:1598-1599) is also not recomputed under the cap.
Unchanged conclusions: charter fit (goal 24 host prefix cache; #718's HTTP/routing surface not carried) and the #160 scope caveat both stand; the cap remains the author's extrapolation of yatesdr's #455 documentation request.
#21 [high] AMENDMENT TEXT (final) — supersedes parts of note #16; use this for the report's amendment section
PR #742 amendments after head 02990da -> 66d6af3 (pushed 2026-12-05 09:19) and main drift. Details in notes #17 (delta), #18 (doc nit), #19 (base drift). This note is the authoritative text; where it disagrees with #16, this wins.
-
SCALE/STATE. 2 commits, +94/-21 in the same 9 files (was +115/-10): 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, 8
max_sequence_pages: Nonefixtures (helios/src/offload/pool/tests.rs:134, selene/src/offload/sharded/tests.rs x4, selene-manager/tests/client.rs x2, selene-manager/tests/offload.rs x1). Labels area:memory, area:preparation, area:selene, performance, triage:review. 3 discussion entries: case-file 08:55, autobot review "Changes Requested" 09:11 (0 blockers / 1 should-fix / 3 subtract / 4 nits), author reply 09:19. No maintainer comment; no CI results on the head. -
VOID: old finding 5 (memory.rs vs model.rs
Optionasymmetry).PlannedHostBudgetscarriespub max_sequence_pages: NonZeroU64(memory.rs:34), set at :1595, threaded into new paramprepare_offload(..., max_sequence_pages)(model.rs:1047-1053, :1125) ->PrepareInputs(model.rs:1167-1173). Residual nit: parameter stillOption, and the two prepare_offload tests passNone(model.rs:1562, :1574). -
VOID:
Some(0)/context == 0(autobot's only should-fix).contextfiltered> 0(memory.rs:993-996);NonZeroU64::new(context.div_ceil(contract.cache.page_tokens as u64))(memory.rs:998-1000) -> Some(0) unrepresentable, selene'slimit > 0guard redundant. Divisor still unchecked at :999 butPreparedContract::validaterejects page_tokens==0 (helios/src/model/contract.rs:536) at both entry points (helios/src/server/config.rs:214, helios/src/server/runtime.rs:956) and capacities() re-checks (memory.rs:697): defended -> nit, not should-fix. -
CHANGED: double clamp removed.
capture.then_some(minimum_pages)(memory.rs:1136); single clampchain_pages = inputs.max_sequence_pages.map_or(pages, |limit| pages.min(limit.get()))(selene/src/offload.rs:165-167) feeds slab bytes (:168-180) and thehost budget cannot hold a full pool capturetest (:171-177), incl. first-pass device/tier_host (memory.rs:1126-1138). capture_growth clamp memory.rs:1490; planned_offload_host memory.rs:1556-1557 — unchanged. -
STRENGTHENED: helios test pool_capture_growth_caps_at_max_sequence_pages_without_throttling_gpu_pages now asserts
pages == uncapped_pages(memory.rs:2463) pluspages > max_sequence_pages(:2464). Still one synthetic core; planned_offload_host and integrated path unasserted. -
CHANGED TESTS: standalone selene bounded test folded into pool_only_sizes_registered_capture_and_headroom_for_local_ranks (selene/src/offload/tests.rs:525-576), cases (10,None)/(512,None)/(512,Some(64)) at :531-535, extra
slots < ...assert :558-560; destructure uses..(selene/src/offload.rs:622-628). Test-count claim 650 -> 649 (648 unit + 1 doctest). -
PARTIALLY ADDRESSED: intake floor still uncapped in code
chain.max(intake_slots(layout, inputs.max_active) as u64).min(budget)(selene/src/offload.rs:178-180; intake_slots :226-229) but now stated in doc (docs/prefix-cache-offload.md:1594-1597) and PR body. Impact table still has no intake-dominated row: disclosed, not quantified. -
STANDS: direction of change. All clamps only shrink the charge -> 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. -
REVISED: #737 overlap. 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 semantics (:973-994; only adds host_pool_budget_from/_and_total_with_reserve/_with_reserve). But it does change async_transfer_host_ram(host_future, apply_reserve) (helios/src/runtime_core/memory.rs:41-44 in pr/737), and async_transfer_host_total feeds host_growth (memory.rs:1483-1492) — the free-host bound for this buffer. So merge order moves the bound even though the edited functions don't. Textual conflict small: PlannedHostBudgets fields (memory.rs:32-35) + ~14-line offsets (headroom call 1126 vs 1140; capture_growth callback 1490 vs 1505; struct literal 1593 vs 1607). Risk stays Low.
-
NEW: base drift; PR body base label stale. Head = f46a9922 + 66d6af33, but main fast-forwarded to 012219a1 (#713, Joshua Cartu, merged 2026-12-04 23:47). #713 added LinuxMemInfo/append_integrated_meminfo at main helios/src/runtime_core/memory.rs:193-300, wired into the
Plan cachesummary (main :1562-1563) — the summary this PR's doc/log discussion touches; ~+161 lines above #742's hunks. PlannedHostBudgets unchanged on main (:32-35), capture_growth still :667 -> mechanical but non-trivial rebase. Body's "Executed on ... base f46a99220a" and the six-crate counts now describe a pre-#713 tree. Supersedes #16 "Recent activity" line "single commit on f46a9922 ... mechanical rebase". -
STANDS: evidence provenance. RSS 18.74-19.06 vs 7.83-8.04 GiB still the v0.6.0 (f705086) build, not an A/B on 66d6af3; hardware CUDA, tests/server/test_prefix_cache_offload.py, qualify/host_cache.py, integrated, multi-host/RoCE, Windows, Kani, TLA+ unrun and disclosed. Push closed code findings, not the evidence gap. Re-review due ~90 min after 09:19.
-
NEW doc nit: 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 (:1595-1597). Harmless (over-long chain would drop as StoreOutcome::Oversize, selene/src/memory.rs:4183-4190) but reads unbounded. GLM-5.3-Flash example (:1598-1599) not recomputed under the cap.
UNCHANGED from #16 (do not amend): charter fit (goal 24; #718's HTTP/routing surface not carried), the #160 scope caveat, the defect's origin in yatesdr's #455 review (2026-11-21, documentation ask), first-time-contributor status, autobot's precedent on #718.
#4 [medium] Change: verified mechanics of the cap and what happens if a chain exceeds it
Facts from the code read (not opinions):
- The property "no single captured sequence chain exceeds max_sequence_tokens" is what the cap relies on. In helios/src/runtime_core/memory.rs:992-996,
context= server_config["max_sequence_tokens"] (hard error if missing: "model requires a prepared context ceiling") andmax_sequence_pages = context.div_ceil(page_tokens). helios/src/core/cache.rs:130-131 derives max_sequence_tokens from the model metadata; helios/src/model.rs:268 clampslimits.max_sequence_tokens = prepared_sequence_tokens.min(...); helios/src/scheduler.rs:1594 and policy.rs clamp request lengths to limits.max_sequence_tokens, so a live sequence cannot exceed it. - Chain-size failure path if the assumption ever breaks: selene/src/memory.rs:4183-4190 (
PooledStore::store): if the chain does not fit (record_slots(tail.len(), row)> pool), it returnsStoreOutcome::Oversizeafter bumping stats.store_skipped / dropped[1] — i.e. the capture is silently dropped, not a crash. Also selene/src/memory.rs:857-860 refill_row returns Retry(Slabs) on no slots; composite.rs maps full slabs to Retry(StoreReason::Slabs) (composite.rs:2027,2053). - Selene docs still describe "roughly the size of the GPU KV cache" in stale places? Not verified; the doc file updated at docs/prefix-cache-offload.md:1593-1608 is the only pool-only capture sizing description found.
- Note the doc text says the slot count is "the larger of automatic intake and one full single-sequence capture chain ... bounded by the host budget", and the headroom code takes
chain.max(intake_slots(layout, max_active)).min(budget)(selene/src/offload.rs:179-181) — so the automatic-intake floor is NOT capped by max_sequence_pages; the min() applies only to the chain term, exactly as documented. - helios/src/runtime_core/model.rs:1155-1157 uses
.map(...)(i.e.Nonewhen max_sequence_tokens is absent) whereas memory.rs:992 hard-errors. Two different behaviours for the same value in the two call sites; in practice both read the same server_config built by helios/src/server/config.rs:131-148, so None should not occur when memory planning succeeded. max_sequence_pagesis used only inheadroom_inner's pool-only capture branch (selene/src/offload.rs:165) and is explicitly ignored in prepare_with_inputs_budget_with_progress (offload.rs:628) — it does not affect disk/intake tiers, so disk-only and memory tiers are untouched by construction.
#10 [medium] Recent activity: #705/#694/#674/#625 in the same files; single-commit head on f46a9922, mechanical rebase expected
Recent activity in the touched areas (default branch, last ~60 days) and how #742 sits against it:
- selene/src: 5d11354d 2026-12-05 (#705 Joshua Cartu) Retry(Slabs) CPU storm — the failure mode a tight capture buffer produces; cfb72093 2026-12-04 (#723 Luke Alonso) codec/R580/packed dedup changes; 7bbc6707 (#694 yatesdr) pool spill profitability gate; def91796 (#674 yatesdr) hit rate/L1/NVMe/packing; a4720050 (#625 autobot) THP/offload startup timings; bf7562ae (#646 Luke Alonso) rank cache/GB10 sizing; 3801ff1d (#612) selene-manager hardening.
- helios/src: heavily Luke Alonso (249 commits/180d), Martin Vit (52), yatesdr (52). Recent: #705, #723, #729 (grammar KV), #711/#721/#727 (AsyncTransfer), #691/#692/#621 by Joshua Cartu (server metrics/admission), #621 validates scheduler admission against core parameter declarations (relevant: max_sequence_tokens now admission-checked).
- docs: Luke Alonso 404 commits, Martin Vit 55, yatesdr 52 — docs/prefix-cache-offload.md is maintained mostly by yatesdr/Luke Alonso; the PR edits a section (2.15, pooling) that yatesdr authored in #455 (#455 itself rewrote +36/-22 lines of that file).
- Base drift: #742's base f46a9922 is 2026-12-04; main has moved since (5d11354d on 2026-12-05, cfb72093, 6efbd126, be4092d7, 624c6e43…), but none of those touched the exact hunks #742 edits, so a rebase should be mechanical.
- The PR head 02990da is a single commit on top of f46a9922 (search_history pr/742), i.e. no fixup/rebase churn; the description's "base f46a99220a" matches.
Not relevant after checking: #314 (diffusion tensor execution, touches memory.rs but unrelated), #585/#486/#477/#492 (compression work, older), #613 (deferred_prefill checkpoints), #646/#659/#669 (GB10/VMM sizing).
#11 [medium] Community/process: ready for review, zero engagement, no CI checks, autobot precedent on #718
Community / process facts:
- PR #742: open, marked "ready for review" (not draft), opened and last updated 2026-12-05 (same day), 1 commit (02990da) on base f46a9922. Labels: none. Reviews: none. Comments: none (pr_comments → "No comments"). No autobot case-file comment on #742 yet (unlike #718 and #737, which got one within minutes of opening).
- CI on the head commit: no checks (orientation packet). Workflows that would apply: .github/workflows/native-serving.yml (selene, selene-manager, helios test jobs) and .github/workflows/helios-lifecycle.yml (paths include selene/, selene-manager/, helios/**; runs TLA+ check.py, then kani on helios --features runtime-core).
- Precedent for how such a PR is handled here: the maintainers' review culture is detailed and itemized (see yatesdr's #455 review with 4 numbered items and a follow-up sign-off; #737's autobot review with Should Fix list). The author's #718 was stopped by autobot for charter fit; #742 is the author's response to that, self-described as "the charter-aligned #455 pool_only() capture-buffer bound" (#160 comment).
- Evidence of interest: none organic yet — no reactions, no maintainer comment, no linked issue asking for the cap. The demand signal is the author's own measurements plus yatesdr's #455 review remark that the buffer "is about the size of the GPU KV cache in registered host memory".
- Age: <1 day at the time of this case file, so absence of review is expected rather than meaningful.
#15 [medium] Change: file map of the 9 changed files and the doc before/after wording in section 2.15
Per-file map of PR #742 (9 files, +115/−10) with each file's role, for quick orientation:
- selene/src/offload.rs (+10/−1): the only enforcement point.
PrepareInputs::max_sequence_pages: Option<u64>(:340-346), cap inheadroom_inner(chain_pages, :165-171), field ignored inprepare_with_inputs_budget_with_progress(:628).headroom_inneralso servesheadroom_with_inputs(:126-134) andheadroom_with_inputs_for_budget(:139-148). - selene/src/offload/tests.rs (+53):
pool_only_caps_capture_buffer_to_max_sequence_pages(:566-621) — two ranks of page_capacity 512,max_sequence_pages: Some(64)→ buffer slotsintake_slots(layout,4).max(64+row_slots), headroom(2*STORE_DEVICE_MARGIN_BYTES + capped_bytes.div_ceil(512), capped_bytes);Some(0)andNoneboth give the uncapped512+row_slotsfigure. Alsomax_sequence_pages: Nonein theinputs()helper (:14) andprepare_with_inputs()helper (:51). - helios/src/runtime_core/memory.rs (+~30/−4): derives
max_sequence_pages(:996), passes it (:1130) and clampslocal_pages(:1132), clamps thecapture_growthcallback (:1486), clampsplanned_offload_hostchain bytes (:1552-1555); testpool_capture_growth_caps_at_max_sequence_pages_without_throttling_gpu_pages(:2440-2457) assertingcapture_growth(...) == Some(0)when the reserved bytes already cover the capped chain, thenpages > max_sequence_pagesfromcapacities(); fixture at :2031. - helios/src/runtime_core/model.rs (+5): derives the same value with
.map()(:1155-1157) and passes it intoprepare_with_inputs_budget_with_progress(:1168), which is called from the load path at model.rs:1047 withplanned.offload_host. - helios/src/offload/pool/tests.rs (+1): fixture.
- selene/src/offload/sharded/tests.rs (+4): four fixtures (sharded = multi-host, where capture never applies).
- selene-manager/tests/client.rs (+2), selene-manager/tests/offload.rs (+1): fixtures in the tier-matrix and startup tests.
- docs/prefix-cache-offload.md (+9/−7, section 2.15 "Sharing through a pool", :1593-1608): before — slot count is "larger of automatic intake and the largest GPU page capacity plus one row's slots, bounded by the host budget"; after — "the larger of automatic intake and one full single-sequence capture chain (
min(GPU page capacity, ceil(max_sequence_tokens / page_tokens))plus one row's slots)", and "Helios limits GPU page capacity so one sequence chain plus one row fits the host budget. If even the capped minimum page capacity plus one row does not fit, startup fails withhost budget cannot hold a full pool capture." The GLM-5.3-Flash TP4 example (11.0 GiB / 1,664 slots, 7.1 GiB floor) is retained unchanged from #455. - Unchanged but load-bearing for the reader:
PrefixCacheOffload::pool_only()(selene/src/offload.rs:116-118),intake_slots(:227-229),capture_growth/capacities(helios memory.rs:667-681, 683-760), theOversize/Retry(Slabs)drop paths (selene/src/memory.rs:4183-4190, :857-860).
#19 [medium] Base drift: main is now 012219a1 (#713), not f46a9922 as the PR body claims
BASE DRIFT (new since report #16, verified):
- PR #742 head 66d6af3 is 2 commits: f46a9922 (base at open, 2026-12-04) + 66d6af33. But main fast-forwarded past f46a9922:
helios/src/runtime_core/memory.rson main is now at 012219a1 (Joshua Cartu, "fix(flare-cli,helios): release page cache with O_DIRECT peer serving, inherit orbit memory reserve, and log integrated MemInfo (#713)", merged 2026-12-04 23:47). - Consequence: the PR body's "Executed on PR head (66d6af3, base ... f46a99220a)" is now a stale base label, and the six-crate test counts were measured against a pre-#713 tree. #713 added
LinuxMemInfo/append_integrated_meminfoat main-side helios/src/runtime_core/memory.rs:193-300 and wired it into thePlan cachesummary (main :1562-1563), i.e. exactly the summary line #742's doc/log discussion touches, ~+161 lines of drift above #742's hunks. - No textual conflict with #742's own hunks: on main
PlannedHostBudgetsis still{ offload_host, async_transfer_host_caps }(memory.rs:32-35) andcapture_growthis still at :667; #742 inserts its field into that struct literal, so the rebase is mechanical but non-trivial (struct literal line moved ~1593 -> ~1750s on main). - Net effect on my report: "single commit on f46a9922, mechanical rebase expected" (report #16, Recent activity) is superseded — it is 2 commits, base f46a9922, main now 012219a1, and the evidence base label needs refreshing for the crate runs.
- #737 (open, lukealonso, 46e6a3b) remains the higher-cost conflict; #713 is already merged so it shows up as ordinary forward drift, not a merge-order risk.
- Also unchanged/confirmed: main's
host_budget_foris still a closure defined insideallocate_caches(main :972, was :973 at head 02990da) and is not a named fn, so #737'sasync_transfer_host_ram(host_future, apply_reserve)change to thehost_growthinput stands as the only structural #737/#742 interaction.
#18 [low] Doc nit: 'copies the full GPU chain' still unbounded-sounding beside the new cap sentence
Minor residual nit found while re-reading the reflowed doc (post-66d6af3):
- docs/prefix-cache-offload.md:1605-1606 still says "If a capture has no resident ancestor, it copies the full GPU chain and offers its ancestors for linking at the manager." In the same paragraph that now introduces the
min(GPU page capacity, ceil(max_sequence_tokens / page_tokens))cap (:1595-1597), "the full GPU chain" reads as unbounded KV capacity. In practice no single captured chain can exceedmax_sequence_tokens, so a chain always fits the capped slab (selene/src/memory.rs:4183-4190 returnsStoreOutcome::Oversizeif it ever does not). Wording, not behavior; worth one sentence in the amendment. - Docs now correctly say startup fails only when "even the capped minimum page capacity plus one row does not fit" (:1600-1602), matching selene/src/offload.rs:171-177.
- The doc's GLM-5.3-Flash TP4 example (:1598-1599, 11.0 GiB / 1,664 slots intake-dominated, 7.1 GiB full-chain floor) is still carried verbatim from #455 and is not recomputed under the new cap; it happens to illustrate the intake floor dominating, which is the point now disclosed in prose.