#1 [high] Change: what PR #496 actually does in selene/src/disk_store.rs
PR #496 "Coalesce shared ancestor reads across concurrent Selene disk fetches", author FujitsuPolycom, head f9c9191, base main, 2 files: selene/src/disk_store.rs +2803/−913 and docs/prefix-cache-offload.md +5/−1. No comments, no reviews, no CI checks at head.
What it does (verified by reading the diff and file at pr/496):
- The old single
InboundRecord(+Destination::{Device,Host}enum) is split into two pipelines:HostInbound/HostWindow(fieldspages: Vec<usize>,row: Option<Vec<usize>>) = caller-owned host reads, used byStaged::read_into(composite / host_inbound). Unchanged behaviour, stillplan_windows(disk_store.rs:672).DeviceInbound/DeviceActiveWindow/DeviceSegmentRef= GPU restores viaStaged::fetch(disk_store.rs:1117-1159, 2387-2433), which use the newplan_aligned_windows(:700) and shared structures.
- New shared-state machinery in
Staged:shared_segments: HashMap<SharedSegmentId, SharedSegment>,shared_windows: HashMap<SharedWindowId, SharedWindow>,next_shared_segment,next_shared_window(struct at :1161-1177).Owner::Inbound(JobId,usize)becameOwner::HostInbound(JobId,usize)+Owner::SharedSegment(SharedSegmentId)(:255-262). SharedSegment(:1021-1058): one disk-thread open file per exact(path, Header)pair, with a 5-state machineUnopened/Opening/Opened/Closing/Closed,disk_outstanding,next_disk_window,pending_page_reads: HashMap<u32,SharedWindowId>,pending_row_reads: VecDeque(becausedisk::Job::ReadRowcarries no window id, FIFO),open_error,users: HashSet<JobId>.acquire_shared_segment(:1362) attaches a new fetch to the lowest-id reusable segment for the same (path, header).SharedWindow(:1070-1100): one staged staging window (SlabPool buffers) per (path, expected Header, first, count, row), withphase: Reading/Read/Failed,disk_referenced,upload_referenced,followers: Vec<WindowFollower{record, plan_index}>,read_bytescredited per follower.plan_aligned_windows(:700-744): splits each fetch segment on absoluteWINDOW_PAGES(64-page) file boundaries instead of packing from the restore's own first uncached page, so branches with different GPU-resident prefix lengths produce identical suffix windows. Row is only placed on the chunk that ends the segment (row: row && chunk_end == end).pump_device_inbound(:1811-2266) is a new 5-pass (1, 2, 3, 4, 5a-5e) scheduler replacing the old per-record pump: reap uploads/detach; attach followers to in-flight windows within theWINDOWS_IN_FLIGHT(=2) credit; sweep unreferenced windows; start new windows (opening the shared file lazily, allocating staging slots, submitting ReadPages/ReadRow); submit per-follower GPU uploads from the shared staged buffers; detach/sweep; close segments that no longer need reads; complete fetches (last user of a shared segment waits for it to settle, i.e. Close reply, before emittingFetched).build_pending_demand(:1647) +pick_next_pending_plan(:1684): per-pump index of pending window demand across all healthy fetches (keyed by path, first, count, row -> Vec<(Header,count)>), so an arriving fetch prefers windows that siblings also need.debug_assertonly in dev.- Failure isolation:
fail_window(:1475) fails only attached followers;fail_segment_users(:1449) fails all users of a shared segment on shared Open failure, tagging witherror.with_record_read()(:1494-1520). Private child/upload errors are recorded per-record and only thatFetchedgets Err. Staged::in_flight()now returns(outbound, host_inbound + device_inbound);Staged::closeabandonedcount includes both maps (:2485-2489).- Test-support-only counters added:
disk_opens,disk_window_reads,coalesced_windowsinResources(:189-200) and accessorsStaged::disk_opens(),disk_window_reads(),coalesced_windows()behind#[cfg(any(test, feature = "test-support"))](:1213-1235), asserted by the new tests. These are the only public API additions; no re-exports or on-disk format change. - New tests (module
testsat :3897):aligned_windows_align_to_window_boundaries_for_device_coalescing(:8192),concurrent_burst_coalesces_shared_ancestor_opens_and_window_reads(:8252),staggered_arrival_attaches_out_of_order_to_in_flight_windows(:8345),different_skip_pages_coalesce_aligned_windows_to_exact_gpu_pages(:8468),private_failure_isolation_preserves_sibling_sharing_ancestor(:8580),shared_ancestor_failure_propagates_to_all_followers_without_leaks(:8692),staged_close_drains_active_coalesced_fetches_cleanly(:8789). Helperswrite_shared_ancestor_tree(:8136),poll_all_fetches(:8172). 7 coalescing tests, matching the description. plan_windowsdoc comment narrowed to "caller-owned host reads" (:677-679); the module doc (:14-25) gained the sharing paragraph.
#3 [high] Claims and evidence: #496's benchmarks, test suites, and what it does not cover
From PR #496 description (unverified against reviewers, no reviews yet):
- Benchmark: single-pass
flare runon NVIDIA GB10 (SM121),--prefix-cache-memory 0 --prefix-cache-disk /tmp/selene-disk, main425ab2d4vs this change; 8 concurrent /v1/chat/completions after restart with one ~61K warm shared prefix + 8 branches. - Physical NVMe read: 27B TP1 18,026.4 -> 4,285.8 MB (-76.2%, 4.21x); +25 ms stagger 18,093.5 -> 4,562.6 MB (-74.8%); Flash-Next TP1 7,943.7 -> 1,981.1 MB (-75.1%); Flash-Next TP1 stagger -71.7%; Flash-Next 2-host RoCE TP2 -75.2% / -71.0%; DeepSeek TP4 1,877.5 -> 1,875.2 MB (1.00x, described as reads finishing (~15 ms/rank at 47.1K) faster than tokenization so no overlap).
- Burst median TTFT: 27B simultaneous 8,483.8 -> 7,112.4 ms (-16.2%); 27B stagger -20.3%; Flash-Next TP1 3,333.5 -> 3,337.1 (no change); Flash-Next TP1 stagger -2.5%; Flash-Next TP2 -4.5% / -6.9%; DeepSeek TP4 +1.1% slower (2,456.9 -> 2,483.6).
- Author's own caveat: "measured before the linear demand-index and close-count edits covered by the unit tests below"; single-pass runs not repeated after the demand-index edit or rebase.
- Tests:
cargo test --locked --release --manifest-path selene/Cargo.toml --features test-support= 474 passed on x86_64 Linux (O_DIRECT + io_uring) atc0c4f798; all 7 coalescing tests on Windows IOCP;heliosoffload 121 passed / 8 GPU ignored;flare-cli --features roce,rdma. - Not covered:
helios FLARE_RUN_CUDA_TESTS=1, discrete PCIe GPUs, Windows serving, live CompositeStore/PooledStore GPU serving, repeated post-edit benchmarks. - Live checks: 9-fact numerical retrieval at temperature 0 — DeepSeek TP4 9/9 at 23.1K and 47.1K; Qwen3.8-27B TP1 9/9 at 30.1K but 61.3K: 8/9 on main vs 7/9 on this PR (a regression on one fact vs main, disclosed); four concurrent unique-prefix decode streams 30–45 s: 0 errors, 59.4->58.2, 96.6->96.7, 109.2->122.4 vs 118.4 no-offload, 73.6->74.1 tok/s.
- The PR description mentions "Adds
test-supportcounters" — verified:Staged::disk_opens/disk_window_reads/coalesced_windows(), cfg(any(test, feature="test-support")). - Description's companion note: merge this PR first, then rebase #497 so
Staged::pump_allruns host_inbound + pump_device_inbound ahead of writes and maintenance. - Process: opened 2026-11-24 (same day as read), 0 comments, 0 reviews, no CI checks on head f9c9191, single commit f9c91915 "Coalesce shared ancestor reads across concurrent Selene disk fetches" (2026-11-23), +2808/−914 over 2 files. Marked ready for review (state open, ready for review per orientation), no labels, no milestone.
#4 [high] Related work: stacked with #497, same-file overlap with #477/#486
- #497 (open, same author, opened same day 2026-11-24): "Reduce disk offload restore latency and integrated-memory intake overhead" — selene-spark-pipeline branch, +1163/−67 across 16 files including selene/src/disk_store.rs (+151/−10) and docs/prefix-cache-offload.md. Explicitly stacked with #496: each PR's description names the other as companion; #496 must merge first, then #497 rebases so
Staged::pump_allruns inbound queues ahead of writes/maintenance. Both base onmain425ab2d4and share the same benchmark baseline run. Overlap: both touchStaged::pump_all(in #496 it was rewritten tooutbound -> host_inbound -> pump_device_inbound; #497 wants inbound-first ordering) and both touch docs/prefix-cache-offload.md (section 2.4 area). #497 also changes disk-only intake sizing tointake_slots(layout, 1)=2*row_slots + 2*WINDOW_PAGES— i.e. staging for only two windows regardless of concurrency; #496's burst test deliberately sizes its pool the same way (crate::offload::intake_slots(&layout, 1)at disk_store.rs:8271) to show six concurrent restores share the two ancestor windows, so the two changes are complementary in intent. - #477 (open, draft, yatesdr) and #486 (open) both rewrite record files / add codecs at rest: they touch selene/src/disk_store.rs but in Store/DiskStore paths (recovery, packed windows). #477 changes
selene/src/disk.rs(record file header/checksum read) anddisk_store.rsrecovery (:1525-1541 per the autobot review on #477); no overlap with the inbound transport, but a textual conflict in the same file is likely if both land. #477 also carries an autobot "Changes Requested" review. - Historical work this builds on: #141 (host-tier eviction), #142 (hash records once, direct-I/O row reads, prompt window credits — introduced
WINDOW_CREDITS), #168 (store only what a request may resume), #413/#415/#429 (Selene pool puts, rows by role, link under any ancestor), #455 (single-process prefix checkpoints for the pool), #416 (refresh host prefix-cache recency,425ab2d4— the benchmark baseline), #92 (Selene pool across instances), #80 (move host tiers into the CUDA-free selene crate). All merged, all yatesdr. None of them coalesced concurrent disk reads; the per-restore private read path being replaced dates from #142/#168. - No issue, PR, or doc in the local copy asks for coalescing concurrent disk restores. Searches for "coalesce", "shared ancestor coalesce window", "disk restore concurrent branches duplicate reads", "prefix cache disk restore latency" returned #496, #497, #477, #486, #455, #168, #92, #429, #80 and #439 — nothing that predates #496 and requests this. The motivation appears to be the author's own benchmark observation.
- #439 (open issue, default labels area:caching/area:selene/bug): prefix-index
expiredsweep stops early — unrelated code path (index eviction), only adjacent thematically.
#6 [high] Amendment 2026-11-24 run 236: new sibling PRs and what they change about #496's merge order
Event since the 2026-11-24 run-235 report: no new comments and no new commits on #496 (pr_comments = "No comments"; single commit f9c91915 still the head; files still docs/prefix-cache-offload.md +5/−1 and selene/src/disk_store.rs +2803/−913). The change is that the surrounding PR set moved. New items:
NEW SIBLING PRs, none of which touch #496's files (so no new same-file competitor):
- #498 (FujitsuPolycom, draft, opened 2026-11-24 20:09, head 08f5c8a, +259/−16, 1 file heliopause/src/export/capture.rs): "Flush PCIe D2H tails before completion in Heliopause export downloader". Adds
Downloader::fence+flush_d2h_tail(same-stream HtoD read of ≤64 trailing bytes) before sync/event on all four D2H paths. Claims 63/400,000 corruptions without fence vs 0/400,000 with it, 51.1 vs 51.6 GB/s. Limitations: lib +--ignoredCUDA tests not yet run at 08f5c8a; noNVreg_EnablePCIERelaxedOrderingMode=0control; unrelated to the disk restore path. - #499 (FujitsuPolycom, draft, opened 20:10, head 2dab6ba, +1546/−191, 18 files ignition/helios/docs):
--row-shard-prefillplanning,RebuildManifest.row_shard_prefill = 28, PreparedReduceScatter/GatherShards and auxiliary-stream overlap wrappers in ignition/components/collectives.py. Touches docs/TODO.txt and docs/cli-design.md — not docs/prefix-cache-offload.md, not selene/. - #500 (voipmonitor, opened 20:22, head 974db22, +193/−209): ERNIE 5.5 XML tool/think parsers +
flare::pcie_all_reduce_addend_dep. Unrelated to #496. => Net effect on #496's review: same author now has four open PRs in flight (#496, #497, #498, #499), two of them drafts started ~2h after #496. Context for review load, not a correctness issue for #496.
CONCRETE AMENDMENT to the merge-order claim in the previous report (verified by reading pr/497 and pr/477, pr/486, pr/492):
- #497 does NOT contain #496's refactor. At pr/497, selene/src/disk_store.rs still has
fn pump_inbound(:1673),fn pump_all(:1691) and the textDestination::HostPacked(:1112); searching pr/497's disk_store.rs forSharedSegment|plan_aligned_windows|DeviceInboundreturns nothing. So the two PRs are independent edits of the same region, not stacked commits. - Therefore the "merge #496 first, then rebase #497" instruction costs more than a text conflict: #497 carries
staged_pump_all_prioritizes_inbound_ahead_of_outbound_and_maintenance(pr/497 disk_store.rs:6978, callsstaged.pump_all()at :7061/:7072/:7081) which asserts the pre-#496 singlepump_allorder. After rebasing onto #496 it must be rewritten against the newoutbound -> host_inbound -> pump_device_inboundsplit, i.e. it has to assert host_inbound and device_inbound both run ahead of writes/maintenance. Worth naming as a review item on #496: the inbound-first ordering #497 wants is now two queues in #496, so #496's own pump order is the thing that has to be right. - #477 and #486 still have the old
InboundRecordat selene/src/disk_store.rs:710 and #492 hasInboundRecordat :975 withDestination::HostPacked(:893, :1112, :1206) plusread_into_packed/write_packed. #496 deletedDestinationentirely and rewrote every inbound path, so any of the three compression PRs that merges after #496 must re-target v4 packed restores ontoDeviceInbound/SharedWindow— the packed path has no shared-window equivalent in #496 (noHostPacked, nocompleted_packedin pr/496). That is the concrete conflict risk to state; my earlier note only said "textual conflict in the same file is likely".
AUTOBOT REVIEWS now on the neighbourhood (for consistency of the process picture): #477 has a Changes Requested review (2026-11-24 17:53) with three blockers (containers stop building because selene/native/ is not shipped, multi-host ranks cannot start with compression on because the single-use decoder is bound twice, recovery deletes intact raw records); #486 and #492 were halted by Auto-Review as "low value or does not align with the project charter". #496 still has no review, no CI checks and no labels, so it remains the only Selene disk PR with no automated assessment at all.
#7 [high] Research summary
Amendments only (PR #496 itself is unchanged: still head f9c9191, single commit, no comments, no reviews, no CI).
-
What the new event actually is: nothing moved on #496; the neighbourhood did. Three new PRs opened on 2026-11-24 evening (#498 Heliopause PCIe D2H tail fence, #499 row-shard prefill planning + collectives, #500 ERNIE 5.5 parsers). #498 and #499 are both FujitsuPolycom drafts opened ~2h after #496, and neither touches selene/ or docs/prefix-cache-offload.md, so no new same-file competitor and no new charter evidence for #496 — but it is now one of four open PRs from the same author, two of them drafts.
-
Correction to my earlier merge-order claim, verified by reading the heads: #497 does NOT contain #496's refactor. At pr/497, selene/src/disk_store.rs still has
fn pump_inbound(:1673),fn pump_all(:1691) andDestination::HostPacked; a search forSharedSegment|plan_aligned_windows|DeviceInboundreturns nothing. So they are independent edits of the same region, not stacked commits, and "merge #496 first, then rebase #497" costs more than a text conflict: #497's teststaged_pump_all_prioritizes_inbound_ahead_of_outbound_and_maintenance(pr/497 disk_store.rs:6978, pump_all at :7061/:7072/:7081) asserts the old single-queue order and must be rewritten against #496'soutbound -> host_inbound -> pump_device_inboundsplit. This makes #496's own pump ordering a review item, not just #497's. -
Sharper conflict statement with the compression PRs. #477/#486 keep the old
InboundRecord(disk_store.rs:710) and #492 hasInboundRecord(:975) withDestination::HostPacked(:893, :1112, :1206) plusread_into_packed/write_packed. #496 deletesDestinationand every inbound path, and has no packed-host or shared-window equivalent (no HostPacked, no completed_packed at pr/496). So whichever of the three compression PRs lands after #496 must re-target v4 packed restores onto DeviceInbound/SharedWindow — a semantic port, not a textual conflict. -
Process picture: #477 now has an autobot Changes Requested review (2026-11-24 17:53) with three blockers; #486 and #492 were halted by Auto-Review as low value / off-charter. #496 remains the only Selene disk PR with no automated review, no labels and no CI checks at head.
Everything above is saved in scratchpad entry #6; the earlier report's findings (change description, benchmarks, disclosed 7/9-vs-8/9 at 61.3K, test counts, related work) stand unamended.
#8 [high] Amendments to issue in the final report (2026-11-24, run 236)
The next report must be presented as amendments only (the operator asked: "Output only the amendments, do not re-iterate your entire previous report"). Use these four items verbatim in substance; they replace nothing in entry #5, which stands unamended.
-
What the new event actually is: nothing moved on #496 itself (still head f9c9191, single commit f9c91915, 0 comments, 0 reviews, no CI checks, 2 files / +2808−914). The neighbourhood moved. Three PRs opened on 2026-11-24 evening: #498 "Flush PCIe D2H tails before completion in Heliopause export downloader" (FujitsuPolycom, draft, 20:09, +259/−16, heliopause/src/export/capture.rs only), #499 "recipe-declared row-sharded prefill planning and PCIe DMA / RoCE row-shard collectives" (FujitsuPolycom, draft, 20:10, +1546/−191, 18 files, docs/TODO.txt + docs/cli-design.md, no selene/), #500 ERNIE 5.5 XML tool/think parsers +
flare::pcie_all_reduce_addend_dep(voipmonitor, 20:22, +193/−209). None touches selene/ or docs/prefix-cache-offload.md, so no new same-file competitor and no new charter evidence for #496; but #496 is now one of four open PRs from FujitsuPolycom, two of them drafts started ~2h after it. -
Correction to the merge-order claim. #497 does NOT contain #496's refactor — verified at pr/497: selene/src/disk_store.rs still has
fn pump_inbound(:1673),fn pump_all(:1691) andDestination::HostPacked(:1112); a search forSharedSegment|plan_aligned_windows|DeviceInboundreturns nothing. They are independent edits of the same region, not stacked commits. So "merge #496 first, then rebase #497" costs more than a textual conflict: #497's teststaged_pump_all_prioritizes_inbound_ahead_of_outbound_and_maintenance(pr/497 disk_store.rs:6978;staged.pump_all()at :7061/:7072/:7081) asserts the old single-queue order and must be rewritten against #496'soutbound -> host_inbound -> pump_device_inboundsplit. Consequence: #496's own pump ordering is a review item in its own right, not just a rebase chore for #497 — the inbound-first ordering #497 wants is two queues after #496. -
Sharper conflict statement with the compression PRs. #477 and #486 keep the old
InboundRecord(selene/src/disk_store.rs:710); #492 hasInboundRecord(:975) plusDestination::HostPacked(:893, :1112, :1206) andread_into_packed/write_packed. #496 deletesDestinationoutright, rewrites every inbound path, and has no packed-host or shared-window equivalent (no HostPacked, no completed_packed at pr/496). Whichever compression PR lands after #496 must therefore re-target v4 packed restores onto DeviceInbound/SharedWindow — a semantic port, not a textual conflict. This supersedes the softer "a textual conflict in the same file is likely" wording in entry #4. -
Process picture around it: #477 now has an autobot Changes Requested review (2026-11-24 17:53) with three blockers (container images stop building because selene/native/ is not shipped; multi-host ranks cannot start with compression on because the single-use decoder is bound twice; recovery deletes intact raw records). #486 and #492 were halted by Auto-Review as "low value or does not align with the project charter". #496 remains the only Selene disk PR with no automated review, no labels and no CI at head — so the review gap is now conspicuous rather than merely early.
#11 [high] Amendment 2026-11-25 run 238: #496 head moved to 0c04b1e2, autobot review landed, blocker answered
Event since run 237: PR #496 moved. This is the first real movement on #496 itself.
New state (read_item 496, updated 2026-11-25 02:41):
- head 0c04b1e2 (branch selene-disk-ancestor-coalescing), was f9c91915. Rebased onto main c0c4f798 and force-pushed as one commit (same subject "Coalesce shared ancestor reads across concurrent Selene disk fetches").
- Files: now 3, +3358/−933 — docs/prefix-cache-offload.md (+35/−2), selene/src/disk_store.rs (+3313/−931), selene/src/shard.rs (+10/−0, NEW). Previously 2 files, +2808/−914.
- 3 comments now (0 before): autobot case-file notice (20:34), autobot review (21:23, Changes Requested), author's response (02:41).
- Review verdict: recommendation Changes Requested; approach endorsed ("belongs in the repo — a measured, served-workload win with no new flags, no format change, failure isolation preserved, and the shared-window lifetime work holds up"). 1 blocker, 5 should-fix, 4 nits. This closes the previous report's "review gap is conspicuous" finding — #496 is now reviewed on the same footing as #477/#486/#492/#497.
Blocker B1 (61.3K retrieval): the 8/9-vs-7/9 disclosure is gone from the description and replaced by a 5-repeat seed-controlled parity check: one shared 60,534-token disk checkpoint, seeds 1234..1238, top_logprobs=5, main c0c4f798 vs 0c04b1e2 → identical FP32 top-5 logprobs and token IDs, per-seed retrieval scores 6/9==6/9, 8/9==8/9, 7/9==7/9, 9/9==9/9, 4/9==4/9. Mechanism claimed and independently verified by me in main: helios/src/model.rs:230-234 rejects temperature == 0 ("unsupported because greedy decoding incorrectly collapses..."), and helios/src/server/request.rs:643-666 (sampling_number) clamps request values into the declared SamplingRange; helios/src/server/config.rs:789 asserts temperature 0 → 0.5 for a 0.5..1.5 range. So the original "temperature=0" check was never greedy — it ran at the clamped positive temperature, i.e. the 8/9 vs 7/9 gap was sampling noise plus differing prompt nonces, not a coalescing bug. Also added unit test misaligned_follower_attaching_to_shared_partial_tail_and_row_matches_private_restore (selene/src/disk_store.rs:8909-9105) which is exactly the site the review named: leader skip_pages=0 vs follower skip_pages=13, partial <64-page ancestor tail + partial leaf chunk with row=true, compared byte-for-byte against a private single-restore baseline store; asserts disk_opens()==3 (parent reopened for B's unaligned head), coalesced_windows()==2.
Residual on B1: the review asked to "report variance and the differing fact"; the response reports per-seed variance and re-explains the mismatch as nonces+sampling but never names which fact differed; the parity result is 1 model / 1 checkpoint / 1 prompt / TP1 / 5 seeds, i.e. a per-seed match, not a statistical claim.
#12 [high] Amendment run 238: how 0c04b1e2 answers the autobot should-fix items (and what it only half-fixes)
Verified at head 0c04b1e2 (selene/src/disk_store.rs line numbers at head):
Met:
- S4:
plan_aligned_windowsis gone; singlefn plan_windows(segments, align_to_window: bool)with doc comment (:679-727), device fetch usestrue,read_intousesfalse(:1349).WindowKey/SegmentKey/HeaderIdentity(Arc<Header>)+window_index: HashMap<WindowKey, SharedWindowId>(:1052-1060, :1229) andbuild_pending_demand -> HashMap<WindowKey, usize>(:1758+). Autobot's five hand-written key sites collapsed to one type. - S5:
has_window_credit(:1683) andattach_pending(:1711) extracted; Pass 2 / Pass 4 both call them (:1917-1930, :1946-1957). - S2 rustdoc: module doc rewritten (:14-27) — no longer says "Nothing here waits"/"at most WINDOWS_IN_FLIGHT windows of one record", now describes per-fetch credits, out-of-order plans, shared handle + aligned windows, and the close-before-Fetched invariant.
free_slotshas its own doc andallocate's rustdoc is back onallocate(:236-243). - S2 docs: docs/prefix-cache-offload.md §2.4 now carries the real signatures (
write_from(id, header, temporary, path, pages, row, sums)/read_into(id, path, expected, first_page, pages, row)— both match code at :1308/:1334), WINDOW_PAGES file-boundary alignment, immutable+pinned+close-before-Fetched, the two limits, failure-isolation scope and physical-rate/logical-bytes (docs:337-366); plus a duplicate 5-line restatement in §4 (docs:1528-1532). - S3: benchmark table re-measured at head vs main
c0c4f798; 27B rows are means over 2 interleaved repeats; the "existing users pay per-pump demand indexing" claim is now stated as an expected bound with thedevice_inbound.len() <= 1fast path; the 2-host RoCE and DeepSeek TP4 rows were dropped and moved to "Not covered". - Nits partly:
PlanStatereplaced bystarted: Vec<bool>; counters gated#[cfg(any(test, feature = "test-support"))](:200-208, :1283-1295); duplicatepath/expectedremoved fromSharedWindow/DeviceSegmentRef;settled()remains strict and now also requires shared_segments/shared_windows/window_index empty (:6350-6360).
Only half-met / still open:
- Close accounting (autobot nit):
fn close(:2503-2545) still formats "{abandoned} disk transport jobs did not complete" butabandoned = store_jobs.max(internal)where internal = max(owners.len, maintenance.len, shared_segments.len, shared_windows.len). Mixing heterogeneous things under one max means the number can be too high or too low and cannot be used to diagnose; the misleading message survives unchanged. GatedCopier::wrapstill returns a positional 4-tuple (type GatedCopierParts = (SharedCopier, Arc<Mutex<bool>>, Arc<Mutex<VecDeque<Reply>>>, Arc<Mutex<Option<JobId>>>)) — nit not taken.- Docs readability got worse, not better: §2.4 now holds one ~30-line paragraph mixing mechanism, invariants, scheduling policy, failure isolation and metering (docs:337-366), and §4 repeats the bytes_in/inbound_rate sentence. The review asked for these facts to be documented; it did not ask for a single unbroken block.
- Naming-axis point of the module doc/§2.4 ("host_inbound" vs "device_inbound" vs "caller-owned"/"GPU") persists.
#13 [high] Amendment run 238: neighbourhood moved — #498/#499 merged, #504 is a new same-file competitor carrying the packed path
Corrections to the run-237 related-work picture:
-
#498 and #499 are no longer open — they merged.
search_itemswith state=merged returns "#498 pull request (merged) Flush PCIe D2H tails before completion in Heliopause export downloader" and "#499 pull request (merged) feat(ignition): add recipe-declared row-sharded prefill planning and PCIe DMA / RoCE row-shard collectives", both by FujitsuPolycom.search_history mainconfirms the merge commits040f39ff(#498) andd0adb958(#499) are in main, and main's tip is now84ac035c("Remove --collective-tuning..." Luke Alonso). So the run-237 statement "#496 is now one of four open PRs from the same author" is out of date: #496 and #497 are the author's only open Selene items, and #496's rebase basec0c4f798is already behind main again (three main-side commits since: 040f39ff, d3aa/3aa74200 #491, 6426cfc0, 84ac035c — none in selene/ or docs/prefix-cache-offload.md, so still no semantic conflict, only a stale base and a stale benchmark reference). -
NEW same-file competitor: #504 "selene, helios, ignition, heliopause: add pure-CUDA GPU and CPU lossless KV compression" (yatesdr, COLLABORATOR, draft, opened 2026-11-25 00:00, head a187bca, +20004/−706, 146 files).
items_touching selene/src/disk_store.rsanditems_touching docs/prefix-cache-offload.mdboth list it. This overturns the run-237 finding "no new same-file competitor". At pr/504selene/src/disk_store.rsstill has the pre-#496 shape:enum Destination(:881) withDestination::HostPacked(:1112, :1206),struct InboundRecord(:975),fn pump_inbound(:1673),fn pump_all(:1691),pub fn read_into_packed(:1502),pub fn read_into(:1551) — and NOSharedSegment/DeviceInbound/WindowKey. It also grewHeader.packed: Option<Arc<packed::Layout>>(selene/src/shared/record.rs:126) and includespackedinHeader'sPartialEq(:145). That last point is a concrete, new #496-specific defect risk: #496'sHeaderIdentity::hash(selene/src/disk_store.rs:1014-1049) destructuresHeaderfield-by-field and hashes exactly the fieldsHeader::eqcompares as of main today. Once any compression PR lands,Headergainspacked,eqcompares it, and #496's hand-writtenHashsilently omits it — two headers differing only inpackedcollide into oneSegmentKey, i.e. a packed and a raw record of the same path/chain could be treated as the same shared segment. #496 also has noread_into_packed/HostPackedequivalent, so #504's packed disk restores have nowhere to live onDeviceInbound/SharedWindow. This is the sharpened version of the run-236/#496 finding 3 claim, now with a named PR and a named failure mode. #504 itself got an autobot Changes Requested review (2026-11-25 03:28) with 3 blockers, 5+ should-fix and 10 nits, including "stop pruning readable records" and a wrong GKV1 protocol spec — i.e. it is nowhere near merge, but it is the largest open consumer of the code #496 rewrites. -
#497 also moved and is now reviewed: force-pushed to
cd5a366b(+1400/−119), autobot Changes Requested (2026-11-24 21:36), author response at 02:41. Two points that change what the next report should say about merge order:- #497's
pump_allis no longer a plain reorder: it keeps maintenance first but bounded —MAINTENANCE_DEFER_LIMIT = 8(:66),maintenance_deferredfield (:1019), andpump_all(:1212-1243) submits maintenance only when the counter reaches the limit, then inbound (sortedJobIds), then outbound, then drains maintenance while queue space remains, resetting the counter whenever it submitted. So the reconciliation with #496'spump_all(selene/src/disk_store.rs:2291-2312 at #496 head: maintenance unbounded → outbound → host_inbound → device_inbound) is a three-way merge of policy, not just moving two calls ahead. - #497 still has the un-unified planner:
fn plan_windows(segments: impl IntoIterator<Item = (u32, usize, bool)>)+WindowPlanat pr/497:671, called at :1101/:1369/:5178/:5201/:5204/:5207/:5208. After #496'splan_windows(segments, align_to_window), every one of those 7 call sites needs the new argument — so the "whichever merges second reconciles pump_all" sentence in both descriptions understates the rebase: it is pump policy plus the planner signature plusstaged_pump_all_prioritizes_inbound_ahead_of_outbound_and_maintenance(pr/497:7003, still written against the single-queue shape).
- #497's
#14 [high] FINAL amendment text for run 238 report (output = amendments only)
Report must be amendments only (operator instruction). Carry these, superseding the corresponding run-237 findings (#10) and run-236 (#8).
A1. #496 itself moved for the first time. head f9c91915 → 0c04b1e2 (rebased onto main c0c4f798, force-pushed, same commit subject "Coalesce shared ancestor reads across concurrent Selene disk fetches"). Files 2 → 3, +2808/−914 → +3358/−933: docs/prefix-cache-offload.md (+35/−2), selene/src/disk_store.rs (+3313/−931), and NEW selene/src/shard.rs (+10/−0). Comments 0 → 3. The "0 comments / 0 reviews / no CI / review gap conspicuous" findings (#10 finding 5, #8 item 4) are RETIRED: #496 now has an autobot review (2026-11-24 21:23, Changes Requested) that explicitly endorses the approach ("belongs in the repo — a measured, served-workload win with no new flags, no format change, failure isolation preserved, and the shared-window lifetime work holds up"), plus an author response (2026-11-25 02:41). Review structure: 1 blocker, 5 should-fix, 4 nits.
A2. The blocker (61.3K retrieval) is answered, and the answer holds up. The disclosed 8/9-vs-7/9 dip is gone from the description, replaced by a seed-controlled parity run: one shared 60,534-token disk checkpoint, seeds 1234–1238, top_logprobs=5, main (c0c4f798) vs 0c04b1e2 → identical FP32 top-5 logprobs and token IDs, per-seed scores 6/9, 8/9, 7/9, 9/9, 4/9 matching on both builds. Premise independently verified by me: helios/src/model.rs:230-234 rejects temperature == 0 ("unsupported because greedy decoding incorrectly collapses...") and helios/src/server/request.rs:643-666 (sampling_number) clamps into the declared SamplingRange (helios/src/server/config.rs:789 asserts 0 → 0.5 for a 0.5..1.5 range). So the original "temperature=0" check was never greedy — the old gap was sampling noise plus differing per-build prompt nonces, not a coalescing bug. The review's named suspect site got a dedicated unit test: misaligned_follower_attaching_to_shared_partial_tail_and_row_matches_private_restore (selene/src/disk_store.rs:8909-9105) — leader skip_pages=0 vs follower skip_pages=13, partial <64-page ancestor tail plus partial leaf chunk with row=true, byte-compared against a private single-restore baseline store; asserts disk_opens()==3 (parent reopened for the follower's unaligned head) and coalesced_windows()==2. Residual: parity is 1 model / 1 checkpoint / 1 prompt / TP1 / 5 seeds, and the "differing fact" the review asked to name is never named.
A3. Should-fix items: 4 of 5 met at head, 2 items only half-met. Met: plan_aligned_windows folded back into one plan_windows(segments, align_to_window) (:679-727, device fetch true at :1349 region / read_into false at :1349); WindowKey/SegmentKey/HeaderIdentity(Arc<Header>) + O(1) window_index: HashMap<WindowKey, SharedWindowId> (:1001-1060, :1229) and HashMap<WindowKey, usize> demand counts; has_window_credit (:1683) and attach_pending (:1711) extracted, Pass 2/Pass 4 both call them; module doc rewritten (:14-27 — no longer "at most WINDOWS_IN_FLIGHT windows" / "Nothing here waits") and Resources::allocate's rustdoc restored above allocate with a separate doc line on free_slots (:236-243); plan_aligned_windows/PlanState/allow(dead_code) are gone from the file. Docs §2.4 now carries the real signatures (matching code at :1308 write_from / :1334 read_into), WINDOW_PAGES file-boundary alignment, immutable+pinned+close-before-Fetched, both coalescing limits, failure-isolation scope and physical-rate/logical-bytes (docs:337-366), repeated again at docs:1528-1532 (§4). Benchmarks re-measured at head, 27B rows means over 2 interleaved repeats, and the single-restore cost restated as an expected bound naming build_pending_demand's device_inbound.len() <= 1 fast path.
Half-met: (i) Staged::close still reports "{abandoned} disk transport jobs did not complete" where abandoned = store_jobs.max(internal) and internal = max(owners.len, maintenance.len, shared_segments.len, shared_windows.len) (selene/src/disk_store.rs:2513-2544) — message unchanged, and a max over heterogeneous quantities cannot be used to diagnose; (ii) the §2.4 rewrite is one ~30-line unbroken paragraph plus a §4 duplicate, so completeness improved while readability regressed. Nits not taken: GatedCopier::wrap still returns a positional 4-tuple (type GatedCopierParts = (SharedCopier, Arc<Mutex<bool>>, Arc<Mutex<VecDeque<Reply>>>, Arc<Mutex<Option<JobId>>>)).
A4. New same-file competitor, and a concrete hazard it exposes. items_touching selene/src/disk_store.rs now lists #504 "selene, helios, ignition, heliopause: add pure-CUDA GPU and CPU lossless KV compression" (yatesdr, COLLABORATOR, draft, opened 2026-11-25 00:00, head a187bca, +20004/−706, 146 files) — retracting #10's "no new same-file competitor". At pr/504 selene/src/disk_store.rs still has the pre-#496 shape: Destination::HostPacked (:1112, :1206), InboundRecord (:975), pump_inbound (:1673), pump_all (:1691), read_into_packed (:1502) — and no SharedSegment/DeviceInbound/WindowKey. Worse than a textual conflict: #504 adds Header.packed: Option<Arc<packed::Layout>> (selene/src/shared/record.rs:126) and compares it in Header::eq (:145), while #496's hand-written HeaderIdentity::hash (selene/src/disk_store.rs:1014-1049) destructures Header field-by-field and hashes exactly the fields eq compares today. After any compression PR lands, Hash silently omits packed, so two headers differing only in packed collide into one SegmentKey/WindowKey — a packed and a raw record could share one staging segment. And #496 has no packed-host equivalent, so #504's packed disk restores have nowhere to live on DeviceInbound/SharedWindow. (#504 is far from merge: autobot Changes Requested 2026-11-25 03:28, 3 blockers including "stop pruning readable records".)
A5. Merge order with #497 is a policy three-way merge, not a call move. #497 was force-pushed to cd5a366b (+1400/−119) and now keeps maintenance first but bounded: MAINTENANCE_DEFER_LIMIT = 8 (pr/497:66), maintenance_deferred (:1019), pump_all (:1212-1243) = deferred maintenance → sorted inbound → outbound → drain maintenance while queue space remains. #496's pump_all (selene/src/disk_store.rs:2291-2312) = unbounded maintenance → outbound → host_inbound → device_inbound. So "whichever merges second reconciles pump_all" (both descriptions) is understated three ways: the bounded-deferral policy must be reconciled; staged_pump_all_prioritizes_inbound_ahead_of_outbound_and_maintenance (pr/497:7003) still asserts the single-queue shape; and #497's un-unified plan_windows(segments) (pr/497:671) has 7 call sites (:1101, :1369, :5178, :5201, :5204, :5207, :5208) that all need #496's new align_to_window argument. Also #496's rebase base c0c4f798 is stale again: main is at 84ac035c, with 040f39ff (#498), 3aa74200 (#491), 6426cfc0 and 84ac035c since — none touching selene/ or docs/prefix-cache-offload.md, so no semantic conflict, but the base and the benchmark's "main" reference are both behind.
A6. Neighbourhood correction. #498 and #499 are MERGED (search_items merged; merge commits 040f39ff and d0adb958 in search_history main), so #496 and #497 are now the author's only open Selene PRs — retracting #10's "one of four open PRs from the same author, two of them drafts". #500 (voipmonitor) remains open and unrelated (ERNIE XML/think parsers + flare::pcie_all_reduce_addend_dep). No charter evidence has appeared for #496 in any of these. Against the charter: "bring real evidence … benchmarks showing an actual speedup over main on a served workload (#210)" is now satisfied better than before (head-commit, repeated, served-workload TTFT), and the sign-off-requiring non-goals (broad production coverage, rack-scale/disaggregation) are not engaged. #496 remains the only one of the five Selene disk PRs whose autobot verdict starts from "the approach belongs in the repo".
Benchmark numbers to quote (from the refreshed description; I verified internal consistency only): 27B TP1 60.5K simultaneous 18,177.5 → 4,306.7 MB (4.22x), TTFT 7,974.6 → 5,662.8 ms (−29.0%); +25 ms stagger 18,194.2 → 4,843.6 MB (3.76x), 6,883.6 → 5,951.9 ms (−13.5%); Flash-Next TP1 61.0K simultaneous 7,944.9 → 1,981.1 MB (3.99x), 3,327.5 → 3,225.0 ms (−3.1%); stagger 7,958.0 → 2,251.5 MB (3.52x), 3,137.7 → 3,049.9 ms (−2.8%). Rank-0 physical inbound rate 6.07 GB/s single vs 7.71 GB/s 8-way simultaneous, 6.02 GB/s 8-way staggered (27B); bytes_in logical, 8x single. Tests at head: 476 Linux selene, 13 Windows IOCP, 21 single-GPU SM121 helios offload::, test_core_boundary.py. Still not covered: multi-host RoCE serving, 2-GPU split_pools, discrete PCIe GPUs, Windows serving, live CompositeStore/PooledStore GPU serving.
Coverage this run (every orientation lead followed): PR description (changed), comments/reviews (3, changed), commits (new head), files (3, changed), same-file competitors (#504 new; #497/#477/#486/#492 still open), history (main tip 84ac035c; #498/#499 merged), charter (re-read, no new non-goal engaged), and the run-236 #498 lead followed to completion — now merged into main and still not touching the Selene restore path, so still not relevant to #496.
Also worth one line: selene/src/shard.rs became a changed file this run (+10/−0, three hunks). I checked all three: Kind::of gets an unreachable! arm for InboundWindowSample (:476-478) and absorb_local re-queues those events instead of forwarding (:722-725), so rank 0 keeps its rate samples and peers drop them (:1148-1150 in Peer::forward). Consistent with the description; no defect found in the new file. Note the unreachable! guard depends on absorb_local/Peer::forward filtering first — any future caller of Kind::of on a raw TransportEvent stream would panic rather than mishandle a sample.
#16 [high] Amendment 2026-11-25 run 363: second autobot review on unchanged head 0c04b1e2 — no blocker, five new should-fix
NEW EVENT (the only one): a second flare-autobot review comment, 2026-11-25 05:23 UTC, on PR #496 at the SAME head 0c04b1e2. No new commits (read_item 496: head 0c04b1e2, +3358 -933, 3 files, updated 2026-11-25 05:23). Also a repeat "case file opened" comment at 2026-11-25 04:33 with a NEW intake-report URL (a894fb21-…, vs 542f7809-… in the run-238 review round).
Review round 2 verdict:
- Recommendation still "Changes Requested", but now explicitly "### Blockers: None." — the round-1 blocker (settle the 61.3K retrieval result) is formally closed by the bot. My run-238 report said the blocker was answered by the author; this confirms the reviewer accepted it.
- Five should-fix items, parallel to round 1's five, but four are DIFFERENT items. Round 1's S1 (inbound_rate on logical bytes), S3 (benchmark predates head), S4 (one planner/one WindowKey) and S5a (attach-loop de-dup) are all accepted as resolved; S5b (design sign-off) is the only survivor, now promoted to its own item.
- "Nits: 5 nits" (not itemised in the comment). Round 1 had 4. The full body with citations is behind https://autobot.eidonix.com/p/843ebe6d-3a89-4d79-9452-a6dcefc6f591.html (not fetched; findings below are verified from source at head).
- Reviewer explicitly states: "No toolchain, GPU or test run was available to this review: every finding is established from source at head
0c04b1e2."
So the shape of the PR changed from "one blocker + tidying" to "no blocker + five should-fix". That is an improvement in merge readiness, and it means my previous report's "the review's one blocker" framing is now superseded: there is no open blocker at all on #496.
#17 [high] Verified: new S1 (InboundWindowSample on the completion enum) is real AND the S1 fix created a progress-counter asymmetry
Round-2 should-fix #1 ("Take the rate sample off the cross-rank completion enum") — VERIFIED at head 0c04b1e2, all citations exact:
selene/src/disk_store.rs:83— enum doc: "/// Completion the transport reports to the disk store."selene/src/disk_store.rs:97-101—InboundWindowSample { bytes: u64, elapsed: Duration }, noJobId. Every other variant (Stored,StoreInvalidated,Fetched,Truncated,Unlinked, :86-109) carriesid: super::JobId.selene/src/shard.rs:476-478—Kind::ofmustunreachable!("window rate samples stay local to rank zero")for it.- Two hand-written guards uphold that
unreachable!:selene/src/shard.rs:722-725(absorb_localpushes the event onward andcontinues) andselene/src/shard.rs:1148-1150(forwardskips it). Both are load-bearing: remove either andKind::ofpanics. selene/src/composite.rs:1374-1386—CompositeStore::polldoesself.stats.progress += 1;for EVERY event fromdisk.poll_transportBEFORE the match, so anInboundWindowSamplebumpsprogress.selene/src/composite.rs:1418-1428—let progress = self.stats().progress; ... if !self.disk.preserve_committed && (self.maintenance_progress != progress || retry) { ... self.spill_parked(self.memory.reserve(2 * self.memory.pool().intake_slots())); self.disk.maintain(); }. So each physical staging window read re-runsspill_parked+disk.maintain().
ASYMMETRY THE REVIEW DOES NOT NAME (mine, verified): DiskStore::apply (selene/src/disk_store.rs:3630-3636) special-cases the sample and RETURNS EARLY before self.stats.progress += 1:
pub fn apply(&mut self, event: TransportEvent, events: &mut Vec<StoreEvent>) {
if let TransportEvent::InboundWindowSample { bytes, elapsed } = event {
self.inbound_rate.observe(bytes, elapsed);
return;
}
self.stats.progress += 1;
So the disk store's own accounting deliberately treats a window sample as NOT progress, while the composite path it is forwarded to counts it as progress. The S1 metering fix (added in 0c04b1e2 to satisfy round-1 review) inserted a non-completion into a completion channel, and the two consumers now disagree about what progress means. progress is documented as "Completion and capacity-release events, including host pins and shared disk budget" (selene/src/store.rs:201-202) — a bandwidth sample is neither.
Also: StoreStats.inbound_rate is not refreshed by the early return on the disk path, but CompositeStore::streamed_event only copies inbound_rate across when after.fetched > before.fetched (selene/src/composite.rs:324-326) — and streamed_event is reached for the sample only through the other => arm at :1384. So the composite's inbound_rate still does get updated (via disk.apply mutating the disk's own rate, read in stats() at :1435), which is fine — the defect is confined to progress/maintenance frequency.
Severity: real but non-blocking; it is a per-window amplification of maintenance work during exactly the concurrent-restore burst this PR optimises for, i.e. it taxes the PR's own headline scenario. No test covers poll-frequency under coalescing.
#18 [high] Verified: HeaderIdentity::hash drift risk is real and structural — the .. exists because Header.version is private
Round-2 should-fix #2 ("Move HeaderIdentity's hand-written Hash next to the equality it tracks") — VERIFIED at head 0c04b1e2:
selene/src/disk_store.rs:1001-1002— doc: "Reference-counted record header wrapper implementing [Hash] over every semantic field that participates in [Header]'s [PartialEq] contract."selene/src/disk_store.rs:1006-1010—PartialEqisArc::ptr_eq(&self.0, &other.0) || *self.0 == *other.0, i.e. it DELEGATES toHeader's canonicalPartialEq.selene/src/disk_store.rs:1014-1050—impl std::hash::Hashdestructureslet Header { identity, fingerprint, flags, key, parent, bucket, page_tokens, tail_pages, ranks, page_segment, row_segment, row_checksum, created, .. } = &*self.0;— 13 named fields plus a rest pattern at :1030. The review's "14 fields" counts the rest arm; 13 are actually hashed.ranksis hashed structurally byplanes/row_bytes(:1040-1044), plusranks.len()at :1040.selene/src/shared/record.rs:136-152—Header'sPartialEqis exhaustive, field by field: identity, fingerprint, flags, key, parent, bucket, page_tokens, tail_pages, ranks, page_segment, row_segment, row_checksum, created. 13 fields.versionis deliberately excluded (doc at :118 "not semantic identity").- LIVE DIVERGENCE RIGHT NOW:
selene/src/shared/record.rs:119isversion: u32— a PRIVATE field. The rest pattern..at disk_store.rs:1030 is therefore not optional hygiene: it is what lets this compile today, becausedisk_store.rsis a different module and cannot name a private field. So the hash is structurally unable to trackHeaderexhaustively; the..exists precisely to paper over the privacy boundary. - NO TEST guards the hash/eq contract:
grep 'Hash for HeaderIdentity|hash_consist|hash.*eq'over selene/src/disk_store.rs returns only the impl at :1014. There is noa == b ⇒ hash(a) == hash(b)test. Confirmed. - Consequence if a field is added to
Header'sPartialEqbut not to the hash: two headers that are NOT equal hash identically, so they collide inwindow_index: HashMap<WindowKey, SharedWindowId>(selene/src/disk_store.rs:1229) and inSegmentKey/WindowKey(:1052-1060). Two semantically different records would coalesce onto one shared window and one restore would upload the wrong bytes. Silent — no test failure. - Best fix, which the review gestures at but states more weakly: hash only
PrefixKey(Header.key). Under the index's own contract a record file is identified by its key, sokeyalone is coherent, andHeader'sPartialEqneed not be mirrored at all. DerivingHashonHeaderis NOT possible as-is:versionis private-but-included? (no — excluded from eq) andHash/Eqmust agree, so a derive would hashversionand breakEqagreement. Hence "giveHeaderaHashimpl" means a hand-written one in shared/record.rs, which reintroduces the same drift one module over — the review's own two options are not equally good.
#21 [high] Verified: design sign-off item is the only survivor of both review rounds; AGENTS.md:204-206 says routine approval is not the decision
Round-2 should-fix #5 ("Get the design decision recorded") — this is the SURVIVOR from round 1 (round-1 SF5b: "get recorded maintainer sign-off for putting a second inbound lifecycle inside Staged rather than in the disk thread that already owns the handle"). VERIFIED:
- The author added the rationale to the PR description's Why (read_item 496): "Coalescing belongs in
Stagedrather thanDiskThreadbecauseDiskThreadsees only file offsets and raw host addresses and finishes once direct I/O andxxh3complete, whereas shared staging slots must stay pinned inSlabPooluntil every attached follower's asynchronousCopierGPU upload completes." → That is a technical justification, and it is sound, but it is the AUTHOR explaining, not a MAINTAINER recording a decision. AGENTS.md:201-207is the governing rule and it is explicit: "An explicit maintainer request covering the work is sufficient authorization for changes within these constraints and their necessary supporting steps. A feature request, passing tests, or a performance gain does not waive an architectural invariant. Resolve conflicts through an explicit maintainer decision on the design before implementing a change to that invariant; a commit acknowledgment or routine PR approval is not that decision." → "a routine PR approval is not that decision" is decisive: merging #496 does NOT retroactively supply the sign-off.AGENTS.md:204-206is exactly the line the bot cites.- Why this is architectural and not style:
Stagedgains a second inbound lifecycle (host_inbound+device_inboundqueues,shared_segments,shared_windows,window_index) parallel to the oneDiskThreadalready owns; ownership of file handles is now split across two layers, and the invariant "a shared segment's file stays open until the last attached restore's GPU upload completes" (:346-350) is a cross-layer lifetime contract. That is the kind of invariant AGENTS.md:204 says needs a decision on record. - Severity: process, not code. No code change. Ascertainable in one maintainer sentence ("coalescing in Staged is the intended layer"), which is why it is should-fix rather than a blocker. But it is the single item that has now survived two full review rounds, so it is the most likely thing to block a merge if a maintainer applies AGENTS.md:209-212 ("recommend rejection ... Do not rescue it").
- Related, unstated: the same AGENTS.md rule is why #497 got "Ready To Merge" — #497 changes no architectural invariant.
#22 [high] Neighbourhood run 363: #504 MERGED with Header.packed in PartialEq (live hash-collision), #477/#486/#492 closed, #497 now Ready To Merge
NEIGHBOURHOOD MOVED SINCE RUN 238 — this is now the most material change around #496, bigger than the review itself.
-
#504 is MERGED (2026-11-25 18:22, head d1b90d7, +20519 -785, 152 files, by yatesdr). It is no longer a "draft competitor" — it is main. My run-238 note #13 described it as an open draft; that is now wrong.
- #504 reshapes exactly the structures #496 rewrites:
selene/src/disk_store.rsgainsSource::HostPacked(:273),Destination::HostPacked(:949-961),read_into_packed(:1576),InboundRecord::new(vec![segment], Destination::HostPacked, vec![plan])(:1613),plan_windows(segments) -> Vec<WindowPlan>(:1001) — the single-arg signature. Header.packed: Option<Arc<packed::Layout>>is a NEW field (selene/src/shared/record.rs:127on #504) and it is INCLUDED inHeader'sPartialEq(:146, the first compared field).Header.versionstays private and excluded.- Therefore the round-2 review's hash concern is not hypothetical — it is already true on main. #496's
HeaderIdentity::hash(disk_store.rs:1014-1050) destructures a fixed 13-field list with.., so it hashes neitherpackednor anything added later. After a rebase, two records that differ ONLY inpackedare!=underHeader::eqbut hash identically, so they land in the sameWindowKey/SegmentKeybucket and, if they also agree on path+first+count+row, coalesce onto one shared window — one restore uploads another record's bytes.HeaderIdentityexists ONLY in #496 (grep on main and on d1b90d7 returns nothing), so this defect arrives with #496 and cannot be caught by any test currently on main. - Corollary: any rebase of #496 onto post-#504 main is a semantic conflict in
Destination/Source/InboundRecord, not just a textual one. #496 splits the inbound path by destination; #504 adds a third destination. The rebase must decide whetherHostPackedparticipates in window coalescing (it is a contiguous packed payload — coalescing windows across it is probably wrong) — that decision is unstated by #496.
- #504 reshapes exactly the structures #496 rewrites:
-
#477, #486, #492 are CLOSED (not merged). Run 238's report listed them as open competitors "carrying the packed path". They no longer threaten #496 on their own; #504 superseded them. My run-238 amendments over-weighted them.
-
#497 is unchanged since run 238 — still open, still head cd5a366b, still +1400/-119, and its round-2 review at 2026-11-25 05:54 is now "Recommendation: Ready To Merge" with "No blockers" and only 3 should-fix (evidence hygiene + plumbing). Its
pump_all(selene/src/disk_store.rs:1212-1217 at pr/497) addsMAINTENANCE_DEFER_LIMIT = 8(:66) andmaintenance_deferred. Crucially, #497's tree has NOMAINTENANCE_DEFER_LIMIT, noDestination, noInboundRecord— grep at pr/497 forDestination|read_into_packed|InboundRecordreturns nothing, andplan_windowsthere is single-arg. So #497 is a genuinely independent branch and the two are still mergeable in either order, as both descriptions claim. -
Already merged and relevant as background: #498 (
d0adb958/040f39ff) and #499 (d0adb958) are in main per search_history; #415, #429, #413, #337, #343, #355, #336, #142, #168 all merged earlier.items_touching selene/src/disk_store.rscurrent list: #497 open, #496 open, #504 merged, then a tail of merged history. So after #504 merged, #496 and #497 are the only open PRs on this file.
#23 [high] #496 now needs a real rebase: plan_windows arity, Destination/Source HostPacked 3rd variant, and the §2.4 paragraph #504 also rewrote
CONFIRMED REBASE SURFACE between #496 (head 0c04b1e2) and post-#504 main (d1b90d7):
plan_windows: #496 headfn plan_windows(segments: impl IntoIterator<Item = (u32, usize, bool)>, align_to_window: bool)(selene/src/disk_store.rs:682-685, doc at :679-681). Post-#504 it isfn plan_windows(segments: impl IntoIterator<Item = (u32, usize, bool)>)(one arg, d1b90d7:1001). Same function, different arity → direct textual conflict, and #504 added apages == 0early-continue branch (:672-676) that #496's version expresses inside theif pages == 0 { ... } else { ... }windows computation. Both must be merged by hand.Destination: #496 leavesDestination::{Device, Host}implicitly (itsDestinationis not present at head — the split is viahost_inbound/device_inbound+HostInbound/DeviceInboundstructs at :749 and :1168). #504 addsDestination::HostPackedas a third variant consumed at:1180,:1185,:1274,:1613. #496 must decide whereHostPackedlives in its two-queue split — there is no obvious home, becauseHostPackedis caller-owned (host) but its payload is a packed v4 envelope, so attaching it tohost_inboundkeeps the oldHostInboundshape; attaching it todevice_inboundwould make it window-coalescable, which is probably wrong for a contiguous packed payload.Source: #496 head hasSource::{Device{pages,slot,detect}, Host{pages,row,sums}}(:274-287); #504 addsSource::HostPacked{units,spans,row}(d1b90d7:273, used at :508, :610, :699-706, :861 unreachable, :1715). Same three-way split problem on the outbound side.InboundRecord: #504 still constructsInboundRecord::new(vec![segment], Destination::HostPacked, vec![plan])— thevec![segment]single-element shape #496 collapses. So #504 re-introduces exactly the structure #496 removes.- Docs: #504 moved §2.4 to :414-419 (offset +81 lines) and re-states
write_from(key, metadata, buffers)/read_into(key, buffers)at :418 (:337 on main). #496 rewrites the same paragraph at :337-366 with real signatures. So the two edits touch the same paragraph, and whichever lands second must re-apply the signature fix — the doc sentence is now stale on main, in the paragraph #496 is trying to correct. - VERDICT: #496 cannot be described as "3 files, no format change, merges cleanly" any more. As of 2026-11-25 18:22 it needs a real rebase onto post-#504 main and at least one unstated design decision (
HostPackedplacement w.r.t. coalescing). The PR description's "No core re-export or format change is required" is still true of #496 itself but its merge base has moved under it.
#24 [high] Coverage run 363: all angles re-checked, 3 judged not relevant, 2 tool limitations worked around
COVERAGE this run (every angle re-checked):
- PR head/state: confirmed unchanged at 0c04b1e2, +3358 -933, 3 files, no new commits (read_item 496). No new author response after 02:41; the only new events are two bot comments (04:33 case-file/intake, 05:23 review).
- Review round 2: read in full from pr_comments. Verified all five should-fix items against source at head — entries 17 (S1), 18 (S2), 19 (S3), 20 (S4), 21 (S5). All five are accurate; none is spurious.
- Round-1 items re-checked for regression: S1 inbound_rate — still physical via the window sample (:1617-1620, :3630-3636), follow-up defect found (progress asymmetry, entry 17). S2 docs/rustdoc — §2.4 rewritten (:333-366) and module doc now correct (disk_store.rs:7-27, "at most [
WINDOW_PAGES] pages" :16, "Submissions never block" :23);free_slotsdoc restored (:236-239) andallocatedoc back onallocate(:241-243). S3 benchmarks — table now cites c0c4f798→0c04b1e2 and single-restore cost labelled an expected bound. S4 WindowKey/plan_windows —window_index: HashMap<WindowKey, SharedWindowId>(:1229) present, plan_windows unified (:682). S5a attach dedup — present. Regression: none. - Round-1 nit on
Staged::close— STILL NOT FIXED, unchanged.selene/src/disk_store.rs:2513-2528:store_jobs = outbound.len() + host_inbound.len() + device_inbound.len() + maintenance_jobs, theninternal = owners.len().max(maintenance.len()).max(shared_segments.len()).max(shared_windows.len()), thenabandoned = store_jobs.max(internal), reported at :2540-2545 as "{abandoned} disk transport jobs did not complete within {:?}". Two defects survive: (a)shared_segments/shared_windowsare refcounted window/slot bookkeeping, not "jobs", so a leaked window is reported as leaked jobs; (b).max()of two heterogeneous counts UNDER-reports — if 3 store jobs and 5 leaked structures remain, the message says 5 jobs, and if 5 jobs and 3 structures remain it says 5; the true total is unknowable from the message. The author's claim "Includedowners,shared_segments, andshared_windowsinStaged::close'sabandonedcount" is true but only adds the.max()arguments; it does not fix the semantics. Round-2 review demoted this to a nit (it is not in the 5 should-fix), so it will likely ride in. - Hash/eq test coverage: none exists (entry 18). Confirmed by grep.
pump_allordering: unchanged,maintenance.front()is drained FIRST and unbounded (disk_store.rs:2291-2300) before outbound/host_inbound/device_inbound. Round-2 review does not raise it. My run-238 finding stands: #496 ships no inbound-before-maintenance ordering; the description's ordering sentence describes post-rebase #497 (MAINTENANCE_DEFER_LIMIT, pr/497:66,:1212-1217). #497 is still the PR that owns that fix and is now Ready To Merge.- Benchmarks / evidence: unchanged from run 238 (no new commits). The 4.22x/3.76x 27B rows, 3.99x/3.52x Flash-Next rows, and TTFT −29.0%/−13.5%/−3.1%/−2.8% are as previously reported; "Not covered" list unchanged (multi-host RoCE, 2-GPU split_pools, discrete PCIe, Windows serving, live CompositeStore/PooledStore GPU serving).
- Neighbourhood: fully re-enumerated (entry 22, entry 24). #504 merged is the material change; #477/#486/#492 closed; #497 Ready To Merge.
- Judged NOT relevant this run: (a) #498/#499 — merged before this window and touching offload/collective paths, not disk_store coalescing; (b) the case-file/intake-report bot comments at 04:33 — infra noise, no content about the code, and I did not fetch the external URLs; (c) the closed #477/#486/#492 diffs — superseded by #504, no longer arriving independently; (d) AGENTS.md line 204-206 "not opened" in the bot's own text — I DID open it (AGENTS.md:195-215) and it is the decisive citation, so the bot's "(not opened)" note is wrong and should not be repeated.
- Attempted and failed:
read_file selene/src/store/composite.rs(composite lives atselene/src/composite.rs, notselene/src/store/);read_filewith refc0c4f798(tool requires a full 40-digit sha), worked around viapr/496andpr/497. Searches onmainfor #504 markers return nothing because the local main snapshot predates the 18:22 merge; #504 content read from its head sha d1b90d7 instead.
#25 [high] FINAL amendment text run 363 (output = amendments only): A1-A8
FINAL AMENDMENT TEXT (output = amendments only, do not re-iterate the run-362 report).
A1. The review's blocker is gone; the PR is now "no blocker, five should-fix". A second flare-autobot review landed 2026-11-25 05:23 UTC on the same head 0c04b1e2 (no new commits, still +3358/−933, 3 files). It supersedes the 21:23 review I reported. Recommendation is still Changes Requested, but Blockers: None — the 61.3K retrieval blocker is formally closed, confirming the author's 02:41 answer was accepted. All five should-fix items are new, and I verified each against source: (1) InboundWindowSample polluting the completion enum, (2) HeaderIdentity's hand-written hash, (3) record_slots restated by hand, (4) the §2.4 paragraph plus the duplicated metrics contract, (5) design sign-off. All five are accurate; none is spurious. Five nits, not itemised by the bot.
A2. Only one earlier should-fix survives, and it is the process item. Round 1's five are resolved at head with no regression. The single repeat is "Get the design decision recorded" — the author's Why paragraph is a correct technical argument but is the author justifying, not a maintainer recording a decision, and AGENTS.md:201-207 is explicit that "a commit acknowledgment or routine PR approval is not that decision". So merging #496 cannot retroactively supply the sign-off. This is now the item most likely to hold the PR.
A3. The hash concern is not hypothetical: #504 merged and it is already true on main. #504 merged 2026-11-25 18:22 (head d1b90d7, +20519/−785) and adds Header.packed: Option<Arc<packed::Layout>>, which is included in Header's PartialEq (selene/src/shared/record.rs:127, :146). #496's HeaderIdentity::hash (selene/src/disk_store.rs:1014-1050) destructures a fixed field list with a .. rest arm, so it hashes neither packed nor anything added later. After a rebase, two records differing only in packed compare unequal yet hash identically, collide into one WindowKey/SegmentKey, and one restore uploads another record's bytes — silently, since no test guards hash/eq agreement (I checked: none exists). HeaderIdentity exists only in #496, so this arrives with this PR and cannot be caught by today's main. Two corrections to the review's own advice: it says "14 fields" but 13 are hashed (the 14th is the rest arm), and its option "give Header a Hash impl" is not a clean derive — version is private and excluded from PartialEq, so a derive would hash it and break the eq/hash agreement it is meant to protect. Hashing only PrefixKey is the sound choice, and that is also why the .. is structural rather than untidy: Header.version is private to another module, so disk_store.rs cannot name every field.
A4. New finding the review does not name — the rate-sample fix made two consumers disagree about progress. DiskStore::apply (selene/src/disk_store.rs:3630-3636) special-cases the window sample and returns before self.stats.progress += 1, so the disk store treats a bandwidth sample as not-progress. But CompositeStore::poll (selene/src/composite.rs:1374-1386) increments self.stats.progress for every transport event ahead of its match, so the composite counts the same sample as progress — and :1418-1428 re-runs spill_parked(...) plus disk.maintain() whenever progress moves. Net effect: one full maintenance pass per physical staging window during exactly the concurrent-restore burst this PR exists to speed up, plus StoreStats.progress inflated by a quantity that selene/src/store.rs:201-202 defines as "Completion and capacity-release events". This is a consequence of the fix the author added for round 1, not of the original design, and no test covers poll frequency under coalescing.
A5. Neighbourhood, rewritten. #504 is merged, so it is main rather than a competitor; the closed #477, #486 and #492 are superseded by it and should be dropped from the related-items list. #497 is unchanged at cd5a366b and its own 05:54 review is now Ready To Merge / no blockers, and it still has no Destination, no InboundRecord and a single-argument plan_windows — so the two-doors-open claim in both descriptions still holds. #496 and #497 remain the only open PRs touching selene/src/disk_store.rs.
A6. #496 can no longer be called a clean 3-file merge — post-#504 it needs a real rebase plus one unstated decision. Three concrete collisions, verified: (i) plan_windows is two-argument at #496's head (selene/src/disk_store.rs:682-685) and one-argument on post-#504 main, and #504 also restructured its pages == 0 branch; (ii) #504 adds a third Destination::HostPacked and Source::HostPacked, while #496's whole restructuring is a two-way host_inbound/device_inbound split — the rebase must decide whether a contiguous packed payload participates in window coalescing, and #496 says nothing about it; (iii) #504 moved and edited the same §2.4 paragraph #496 rewrites, and it re-states the stale write_from(key, metadata, buffers) / read_into(key, buffers) signatures there, so the paragraph #496 is fixing is now wrong on main in a second way.
A7. Unchanged from my last report, and still worth carrying. pump_all (selene/src/disk_store.rs:2291-2312) still drains maintenance.front() first and unbounded, so #496 ships no inbound-before-maintenance ordering — that is #497's MAINTENANCE_DEFER_LIMIT, not this PR's. And Staged::close still reports abandoned = store_jobs.max(internal) into "{abandoned} disk transport jobs did not complete" (:2513-2545); including shared_segments/shared_windows satisfied the reviewer's wording but a .max() of two heterogeneous counts cannot total them, and a leaked window is still reported as leaked jobs. Round 2 demoted this to a nit, so it will probably ride in.
A8. Coverage and one correction to the bot's own text. Every angle was re-checked: head/state, all five should-fix items, all five round-1 items for regression, the nits, pump_all, the hash/eq test gap, benchmarks, and the neighbourhood. Judged not relevant: #498/#499 (merged earlier, collective/offload paths, not disk-store coalescing), the 04:33 case-file and intake-report comments (infrastructure notices carrying no claim about the code; I did not fetch the external URLs), and the closed compression PRs (#504 supersedes them). One correction: the review cites "AGENTS.md:204-206 (not opened)" — I did open it, and AGENTS.md:201-207 is the decisive text for A2 ("a commit acknowledgment or routine PR approval is not that decision"), so the "(not opened)" caveat should not be carried forward. Equally, the review states it had no toolchain, GPU or test run; that limits it to source reading, which matches everything I verified above — the five items are all source-visible, and none of them rests on a runtime measurement.
#26 [high] Research summary
Amendments only (head unchanged at 0c04b1e2; no new commits). Full text in scratchpad entry #25.
A1. The blocker is gone; it is now "no blocker, five should-fix". A second autobot review landed 2026-11-25 05:23 on the same head 0c04b1e2. It supersedes the 21:23 review I reported: recommendation still Changes Requested but Blockers: None, formally closing the 61.3K retrieval blocker and confirming the author's 02:41 answer was accepted. All five should-fix items are new, and I verified each against source — all accurate, none spurious: InboundWindowSample in the completion enum; HeaderIdentity's hand-written hash; record_slots restated by hand; the §2.4 paragraph plus duplicated metrics contract; design sign-off. Five nits, not itemised.
A2. One earlier should-fix survives — the process item. Round 1's five are resolved with no regression. The repeat is "get the design decision recorded": the author's Why is a correct technical argument but is the author justifying, and AGENTS.md:201-207 says "a commit acknowledgment or routine PR approval is not that decision" — so merging cannot retroactively supply sign-off. This is now the likeliest hold.
A3. The hash concern is already true on main: #504 merged 18:22 (head d1b90d7) and adds Header.packed, included in Header's PartialEq (shared/record.rs:127,146). #496's HeaderIdentity::hash (disk_store.rs:1014-1050) destructures a fixed field list with a .. rest arm, so after a rebase two records differing only in packed compare unequal yet hash identically, collide into one WindowKey, and one restore uploads another record's bytes — silently; no test guards hash/eq agreement. Two corrections to the review: it says "14 fields" but 13 are hashed, and its "give Header a Hash impl" is not a clean derive — version is private and excluded from PartialEq, so a derive would hash it and break the very agreement it protects. Hashing only PrefixKey is sound, and the .. is structural, not untidy: version is private to another module.
A4. New, not named by the review — the rate-sample fix split progress between two consumers. DiskStore::apply (:3630-3636) returns before progress += 1, so the disk store treats a bandwidth sample as not-progress; CompositeStore::poll (composite.rs:1374-1386) increments progress for every event ahead of its match, and :1418-1428 re-runs spill_parked + disk.maintain() whenever progress moves. Net: one maintenance pass per physical staging window during exactly the burst this PR optimises, plus progress inflated by a quantity store.rs:201-202 defines as completion/capacity events.
A5. Neighbourhood, rewritten. #504 is merged, not a competitor; #477/#486/#492 are closed and superseded — drop them from related items. #497 is unchanged at cd5a366b with its own review now Ready To Merge / no blockers, and it still has no Destination, no InboundRecord and a single-arg plan_windows, so the either-order claim still holds.
A6. #496 is no longer a clean 3-file merge. Three verified collisions: plan_windows is two-arg at #496's head (:682-685) vs one-arg post-#504; #504 adds a third Destination::HostPacked/Source::HostPacked against #496's two-way split, and the rebase must decide whether a contiguous packed payload participates in coalescing — unstated by #496; and #504 edited the same §2.4 paragraph #496 rewrites, re-stating the stale signatures there.
A7. Unchanged and still worth carrying. pump_all (:2291-2312) still drains maintenance first and unbounded — that ordering is #497's, not this PR's — and Staged::close still reports abandoned = store_jobs.max(internal) as "disk transport jobs"; a .max() of heterogeneous counts cannot total them and a leaked window is still reported as a leaked job. Round 2 demoted this to a nit.
A8. Coverage and one correction. All angles re-checked. Not relevant: #498/#499 (merged, collective paths), the 04:33 case-file/intake comments (infrastructure notices carrying no claim about the code; external URLs not fetched), and the closed compression PRs. Correction: the review cites "AGENTS.md:204-206 (not opened)" — I opened it, and AGENTS.md:201-207 is decisive for A2, so that caveat should not be carried forward. The review's own no-toolchain limitation is not material: all five items are source-visible and none rests on a measurement.
#27 [high] Strike-list: statements in the run-362 report (entry #15) now superseded vs still standing
The run-362 report is entry #15. This note lists exactly which of its statements the amendments (entry #25) supersede, so the writer can strike them rather than leave contradictions.
STRIKE / SUPERSEDE:
- "an autobot review (2026-11-24 21:23, Changes Requested) plus an author response" — there are now TWO reviews. The second (2026-11-25 05:23) is the live one: same head
0c04b1e2, Changes Requested but Blockers: None, five new should-fix items. The 21:23 review is history that the author answered at 02:41. - "its one blocker was that the description's own 61.3K retrieval check showed 8/9 vs 7/9" and the whole blocker narrative — closed by the reviewer, not merely answered by the author. Do not present an open blocker.
- "Four of five should-fix items are met at head" — the reviewer's round-2 framing is that all round-1 items are resolved; the survivor is the process item only (now promoted to its own bullet).
- Related items block:
#504 (open, draft)is now #504 (merged 2026-11-25 18:22, head d1b90d7, +20519/−785).#477,#486,#492are closed, superseded by #504.#497is still open atcd5a366bbut its own 05:54 review is Ready To Merge / no blockers. The line "#498/#499 merged, so this and #497 are the author's only open Selene PRs" remains correct. - "the 'differing fact' the review asked to be named never is" — soften/withdraw. The description now does name it ("cross-seed score variation reflects positive-temperature sampling, as helios clamps request temperature into the core's positive sampling range and Flare does not support greedy temperature = 0"), and the reviewer accepted it by closing the blocker.
- "#496 ships no inbound-before-maintenance ordering" — still TRUE and still worth keeping (A7), but keep it attached to #497 as the owning PR rather than as a defect of #496.
- "a clean 3-file change" as an implicit framing — supersede: post-#504 it needs a real rebase plus one unstated design decision (A6, entry #23).
CONFIRM (unchanged, do not let the writer think they moved):
- §2.4 is still one ~330-word bullet (
docs/prefix-cache-offload.md:333-366) and thebytes_in/inbound_ratecontract is still stated twice (:362-366and:1528-1531). Staged::closestill reportsabandoned = store_jobs.max(internal)as "{abandoned} disk transport jobs did not complete" (selene/src/disk_store.rs:2513-2545); run-238's "still mixing heterogeneous counters" verdict stands, and round 2 demoted it to a nit.- Benchmarks, test counts, the "Not covered" list and the parity evidence are unchanged (no new commits since run 362).
HeaderIdentitydestructures 13 named fields +..at:1030— the review's "14" counts the rest arm.- The metrics/severity character of #496 is unchanged: no format change, no new flags, failure isolation preserved.
#2 [medium] Change: docs/prefix-cache-offload.md section 2.4 edit
docs/prefix-cache-offload.md, +5/−1, at the paragraph describing Staged in section 2.4 (the Disk transport). Added text: "Concurrent fetch jobs reading the same record file share one open file handle and coalesce aligned 64-page windows while staged so one disk read fans out to each attached fetch's GPU upload before its staging slots are released; caller-owned read_into reads run independently." Previous sentence about read_into moving records between files and caller-owned registered slots kept. This matches the description's claim that section 2.4 is updated. No other doc touched (AGENTS.md, design-review docs untouched).
#9 [medium] Coverage this run: every angle re-checked, no other changes found
Angles re-checked for the amendment pass (all confirm the run-235 findings rather than changing them):
- PR body / description: unchanged (read_item 496, updated 2026-11-24 18:13, same benchmark table, same 7/9-vs-8/9 61.3K disclosure, same "measured before the linear demand-index and close-count edits" caveat).
- Comments and reviews:
pr_comments= "No comments"; no inline reviews. - Commits:
search_historyat pr/496 still shows only f9c91915 on top of main; main has since gained c0c4f798 ("Remove redundant RegistryDwords EnableResizableBar check in flare doctor", unrelated file flare-cli/src/doctor.rs) — the only main-side commit after #496's base 425ab2d4 that is not already in the reported history, and it does not touch selene/ or the doc. - Files:
pr_files= docs/prefix-cache-offload.md (+5/−1) and selene/src/disk_store.rs (+2803/−913), unchanged; docs diff still the section-2.4 paragraph only. - Same-file competitors:
items_touching selene/src/disk_store.rsanddocs/prefix-cache-offload.md— #497, #477, #486, #492 still the only open ones; #498/#499/#500 do not appear. - New same-day items scanned: #494 and #495 (scheduler fixes, autobot reviews), #491 (collectives), #498, #499, #500 — none touches Selene disk restore.
- Lead judged not relevant: #498's PCIe D2H tail-fence bug is real corruption in Heliopause export under Relaxed Ordering, but it is the export downloader path, not the Selene staged restore path, and #496 does not change D2H copy semantics; noted so the report can say the lead was followed and dismissed.
- Also not relevant: #492's own text was previously read as a same-file conflict; it is, but only via the packed-host restore path described in entry #6 item 3. Nothing in the charter, the doc, or the tests changed for #496, so the run-235 body (change description, benchmark claims, uncovered areas, related work) needs no rewrite — only the additions in entry #6.
#19 [medium] Verified: record_slots restatement in pick_next_pending_plan — correct today, one-line fix, drift would stall or under-admit restores
Round-2 should-fix #3 ("Call Layout::record_slots instead of restating it") — VERIFIED, and it is genuinely a one-line fix:
selene/src/disk_store.rs:1767-1777(pick_next_pending_planadmission guard):
let layout_row_slots = self.resources.pool.as_ref()
.map(|_| lock(&self.resources.transfers).layout().row_slots())?;
...
let needed = plan.count + if plan.row { layout_row_slots } else { 0 };
if needed > free { continue; }
i.e. it restates pages + usize::from(row) * row_slots() by hand.
selene/src/geometry.rs:180-182—pub fn record_slots(&self, pages: usize, row: bool) -> usize { pages + usize::from(row) * self.row_slots() }. Algebraically identical.selene/src/disk_store.rs:243-246— the allocator it is predicting already calls it:fn allocate(&mut self, pages: usize, row: bool) { let needed = lock(&self.transfers).layout().record_slots(pages, row); ... }.- Consequence of drift:
pick_next_pending_plancould admit a window the allocator then refuses (or vice versa), so a restore stalls waiting for slots that were never going to fit, or under-admits windows and loses parallelism. Today the two agree; nothing enforces that they keep agreeing. - Note the guard also relocks
transfersper plan-iteration candidate (once outside the loop at :1767-1771, so actually hoisted already) — the review's "hoisted besidefree" (:1766) is accurate:freeislet free = self.resources.free_slots();. - Severity: low-impact maintainability; correct today. Agree it should ride along before merge since it is one line.
#20 [medium] Verified: §2.4 is still one ~330-word bullet and the bytes_in/inbound_rate contract is still stated twice (:362-366 and :1528-1531)
Round-2 should-fix #4 ("Split the §2.4 bullet and stop stating the metrics contract twice") — VERIFIED, and my run-238 report already flagged the paragraph shape; this confirms it survived unchanged:
docs/prefix-cache-offload.md:333-366is ONE Markdown bullet carrying the whole §2.4Stageddescription: signatures (:337-339), shared-handle/window coalescing (:340-345), slot pinning (:343-345),read_intoindependence (:345-346), the immutable+pinned invariant (:346-350), demand-preference scheduling (:350-354), the two coalescing limits (:354-358), failure-isolation scope (:358-362), AND the metrics contract (:362-366). The review says "one ~250-word paragraph carrying ~12 behaviours"; :336-366 is ~30 rendered lines and ~330 words. My run-238 note said "one ~30-line unbroken paragraph plus a duplicate in §4" — consistent, and the duplication is still there.- The metrics statement appears TWICE at head:
docs/prefix-cache-offload.md:362-366(in §2.4): "StoreStats.bytes_incounts logical checkpoint bytes restored to GPU destinations across completed fetches, whereasDiskStoreupdatesStoreStats.inbound_ratefrom physical staging-window disk reads once per window so coalesced followers do not inflate admission bandwidth estimates."docs/prefix-cache-offload.md:1528-1531(in §4): "OnDiskStore,StoreStats.bytes_incounts logical checkpoint bytes restored to GPU destinations across completed fetches, whileStoreStats.inbound_ratemeasures physical staging-window disk reads so coalesced follower restores do not overstate device read bandwidth." Same fact, two wordings, ~1,200 lines apart. §4 is the metrics section per the doc's own structure, so §2.4's copy should go and the §4 wording should absorb "once per physical window".
- The review's verdict is right and I confirm it: this is presentation, not correctness. But note the §2.4 paragraph is the ONLY place the two coalescing limits and the failure-isolation scope are stated (I verified there is no second copy), so a split must not drop them — the limits sentence is :354-358 and failure scope is :358-362.
- Also still true from run 238: the §2.4 bullet sits inside a list item whose siblings (the
MemoryStorebullet at :325-326, theCompositeStorebullets at :344-365) are 1-3 lines each, so the shape is inconsistent with its own neighbourhood regardless of absolute length.