#1 [high] Research summary
Case file: PR #699 — "Avoid double-counting preallocated /dev/shm selene-manager regions against Linux MemAvailable"
Open, "ready for review", opened 2026-12-02 (same day it was last updated), base main, head 135633f, 5 files, +175/−12, no labels, no reviews, no comments, and no CI checks on the head commit (orientation packet). Author ebfio, association FIRST_TIME_CONTRIBUTOR (0 merged PRs; 2 open: #698, #682). I could not run repository history (search_history fails: git: error: Could not read c513e46a…), so commit-level provenance below is inferred from merged-PR file overlap, not from commits.
Key findings (what the description does not say)
- Public API break with no
#[non_exhaustive].PlannedRegionandRegisteredRegionare exported (selene/src/pool/mod.rs:60) andbacked_bytes: u64is a required field in both (startup.rs:29–32, 42–45). Any out-of-tree constructor of these structs stops compiling.registered_region()also gained a parameter (conn.rs:706–717), but that ispub(crate). The description mentions the field addition but not that it is a source-breaking change to a published-crate type. - The budget side effect on integrated GPUs is not stated.
Budget::chargesapportionshost.div_ceil(integrated)to every integrated device (selene/src/pool/budget.rs:30–42). Zeroing host bytes for backed tmpfs also removesarena+stagingfrom that per-GPU charge — and on a unified-memory host the tmpfs pages are still the same physical RAM the GPU KV cache competes for. That is a behavioural change beyond "0 additional host charge", and the failing-config host in the report (494.5 GiB unified memory) is exactly that case. - The root cause is only half-fixed at the layer the description names.
host_pool_budget/host_pool_budget_with_reserve(selene/src/offload.rs:923–985), which reads/proc/meminfoMemAvailableand subtractsfutureplus the reserve, is untouched by this diff. The change instead special-cases tmpfs shares inside the pool budget. (Stated as fact about the diff, not a verdict.) backed_shm_bytesis never executed by any test, self-admitted in the body ("they do not directly execute thestatfshelper or a fresh manager attachment reproduction"). The two new tests fabricatePlannedRegionvalues directly (selene/src/pool/budget/tests.rs:92–186). No test coversregister_memory's decision to passarena_backed/staging_backedinto the plan (conn.rs:774–792) orbuilder.rs'sregistration_costsmapping.- No in-tree caller of the changed path found.
PoolBuilderappears only inselene/src/pool/builder.rs:61,82and its re-exportselene/src/pool/mod.rs:43;offload::Startup::start_pool(selene/src/offload.rs:994) has no call site anywhere in the tree, andheliosonly re-exportsPoolOptions(helios/src/offload/mod.rs:28) and usesStartup::attach/reset/binding(helios/src/runtime_core/model.rs:26,1002,1048,1089,1117). So the approval path this PR changes has no in-repo integration test or reproduction harness — which is consistent with the "no fresh manager attachment reproduction" caveat. (SearchedPoolBuilder,start_pool,registration_costs,approve:repo-wide.) - Description vs. code nuance on the reserve. The body calls the reserve "2 GiB + 5% MemTotal"; the code is
host_service_headroom_bytes(total) + total/20where the service headroom ismin(2 GiB, total/32)and collapses to 64 MiB on ≤16 GiB hosts (selene/src/offload.rs:901–919). Immaterial to the bug, but the description simplifies it. - Two open-PR leads I could not resolve in the time available: the orientation packet matches #674 (open) on the identifiers
shared_backed,staging_backed,saturating_mul— the same names this PR introduces inregister_memory(conn.rs:774–780) — and #646 (merged) onstaging_backed; #477 (closed) matchesbacked_bytesandbuilder.rs. #674 in particular may be concurrent work on the same accounting and should be checked for overlap before merge.
The change
Plain terms: when a selene-manager pool's arena/staging files live on tmpfs and have been fallocated, the pages are already physically committed and already missing from MemAvailable; charging their full size again against the pool budget rejects valid configs. The PR measures how much of each shared file is already backed and charges only the remainder.
Budget::costschanged fromimpl Iterator<Item = u64>toIterator<Item = (u64, u64)>, computingadditional_host = bytes.saturating_sub(backed_bytes.min(bytes))for host while leaving the device termbytes.div_ceil(512)per region untouched, and keeps both overflow checks (selene/src/pool/budget.rs:15–28).approvemaps(region.bytes, region.backed_bytes)(budget.rs:44–48), so thehost = Err(...)propagation and per-GPUGPU {rank}error are unchanged (budget.rs:49–70).backed_shm_bytes(path, declared_bytes)(conn.rs:678–699): Linux-only;CString+libc::statfs, requiresf_type == TMPFS_MAGIC, thenmetadata(path).blocks()*512clamped todeclared_bytes; returns 0 on any failure. Non-Linux stub returns 0 (conn.rs:701–704) — so Windows/macOS builds keep the old behaviour, relevant because the project builds selene on Windows too (#171, merged).register_memorycomputes both backed values up front fromshared.arena_path/staging_path(conn.rs:774–779), uses them in thePlannedRegionplan (conn.rs:780–793), passes0for remote anonymousdata-staging(conn.rs:794–800), and reuses them forRegisteredRegion(conn.rs:852–864).PreparedPool::registration_costsmaps(bytes, backed_bytes)(builder.rs:239–245), which feedssummary()and thechargescomputation at builder.rs:188–193.- New tests:
preallocated_shm_skips_host_double_count_but_keeps_device_charge(tests.rs:92–142) asserts host = 0, device =(arena+staging)/512, that 25 GiB of host budget now approves a 40 GiB pool, that a GPU shortfall still fails withGPU 0, and thathost: Errstill fails;partially_backed_shm_charges_only_unbacked_remainder(tests.rs:144–186) asserts host = 6 MiB from a 16/4/2 MiB plan, thebacked > bytesclamp, and the off-by-one rejection. Existing tests gainedbacked_bytes: 0(tests.rs:9–18, 59–61). - Size/scope: purely selene budget arithmetic plus one
statfshelper; no proto, CLI, config, or docs change;selene-manageritself is untouched even though the diagnosis is about itsfallocate(the body attributes it toselene-manager/src/local.rs; my search of that file forfallocate|set_len|ftruncatereturned nothing, so that attribution is claimed, not verified).
The why
Reported failure on a 494.5 GiB unified-memory host (230.2 GiB weights, 128 GiB local prefix cache, 32 G arena + 8 G staging) quoted verbatim from the body: needs 42949672960 host bytes and 83886080 device bytes per GPU; host budget has 27910736778 bytes left. That string is exactly the approve error (selene/src/pool/budget.rs:55) wrapped by register_memory (selene/src/pool/conn.rs:809–811), so the report is internally consistent with the code; the 26.0 GiB remainder matches 494.5 − 230.2 − 128 − ~40 − reserve(~26.7). No issue number, discussion thread, or prior report is referenced anywhere in the PR or in search_items (the only match for pool-budget/shm terms in the last 30 days is #699 itself). So: wanted by the author, no recorded demand from others.
Related work
All pool internals come from yatesdr (from related_items on #699): #92 (merged) introduced the pool manager and sharing — 5 files in common, i.e. every file this PR touches; #365 (merged) "Require pool attachment at startup and register pool memory off the I/O thread" — 3 files in common (builder/conn/startup), and the direct ancestor of the Approve/PlannedRegion/register_memory machinery this PR extends; #611 (merged) hardening of conn.rs; #609 (merged) shared-region lifetimes in conn.rs; #376 (merged) pid-zero peers in conn.rs; #142 (merged) conn.rs; #455 (merged) builder.rs; #171 (merged) selene build on Linux and Windows — the reason the non-Linux backed_shm_bytes stub matters. Compression series #504/#492/#486/#477/#436 all touch builder.rs/conn.rs (not opened) but not budget accounting. #477 (closed) is also a name-match on backed_bytes; #475 (open) matches declared_bytes, the parameter name invented here. Nothing I found is superseded or undone by this PR; whether #674 (open) overlaps is unresolved (see Key findings 7).
Recent activity
The packet's history query failed (git: error: Could not read c513e46a…), and "no commits in these areas in the last 180 days" is reported for selene/src with the same git error, so I cannot state who last touched these files or when. What is solid: no commits on the default branch since this PR branched (cc0a49d) touch its changed files, so the PR is currently non-conflicting; the maturity of the surrounding code (many merged pool PRs by yatesdr) means this is a late, narrow correction to a mature subsystem, not a greenfield change.
People
Author ebfio: first-time contributor, no merged PRs, two same-day open PRs (#698 cuModuleLoadData deadlock, #682 logind RemoveIPC docs), both in the same operational/startup memory area — so this PR is part of a self-consistent series by someone running large unified-memory hosts (Hades aarch64, kernel 6.17.0-1029-nvidia-64k). The de facto owner of every file here is yatesdr (#92, #365, #609, #611), who has not engaged. No reviewers, no reactions, no comments: zero community interest so far.
Community
pr_comments returns "No comments" — no review, no inline comments, no reactions. Interest to date: author only.
Project fit
Charter goal (line 24): "Store prefix-cache checkpoints in host memory and share them across Flare instances via Selene" — directly on a stated goal, in the layer the charter assigns to Selene. Charter review standards ask for four description parts (why/changes/result/evidence): all four present. Charter "Bring real evidence" and "Bug fixes need to address the root cause": the description supplies a mechanism-level root cause (fallocate on tmpfs ⇒ st_blocks*512 == size charged to Shmem) and a unit-test result, but no reproduction against a live manager and no before/after measurement of MemAvailable/Shmem, and the description explicitly disclaims exercising statfs or a manager attachment. Documentation that describes this budget (docs/model-preparation.md:490 (not opened), docs/runtime-core-design.md:768 (not opened), docs/cli-design.md:891 (not opened) — all describe the integrated/available-memory budget as MemAvailable-derived) is not updated, so the documented semantics and the new tmpfs exemption are not reconciled in-tree.
Claims and evidence
| Claim | Evidence |
|---|---|
tmpfs fallocate charges Shmem and deducts from MemAvailable immediately |
Stated as verified against live /proc/meminfo in the description; the PR contains no log, script or datum. Kernel behaviour is consistent with tmpfs semantics, but nothing in the repo backs it. |
| The pool's 40 GiB is charged twice | Supported by the error string, which matches budget.rs:55; the two-stage charging it describes is visible in code (offload.rs:923–985 for MemAvailable-minus-future, then approve at budget.rs:44–72). |
| Device registration metadata still charged in full | Verified in code: bytes.div_ceil(512) unchanged (budget.rs:24), covered by the new test's (arena+staging)/512 assertion. |
| Off-by-one/partial-backed and clamp behaviour | Verified by reading tests.rs:144–186; backed_bytes.min(bytes) clamps at budget.rs:19. |
statfs helper correct and conservative |
Code reading only: CString::new failure, non-zero statfs, non-TMPFS_MAGIC, and metadata() failure all yield 0 (conn.rs:686–698). No test, no execution. |
cargo test -p flare-selene pool::budget → 4 passed, 0 failed, 551 filtered out |
Author-reported from Hades aarch64; no CI check exists on the head commit to corroborate, and the run covers only the budget module. |
| The error in the report came from a manager-attached instance | No artifact; plausible from the message shape, unverified. |
Reach
Affects operators of local selene-manager pools on Linux (the configs this PR unblocks), any host where /dev/shm is not tmpfs or is partially backed (unchanged, conservative), Windows/macOS selene builds (no behaviour change, stub at conn.rs:701–704), and any external consumer constructing PlannedRegion/RegisteredRegion (compile break). No CLI flag, default, config key, proto, or wire field changes; no new dependency (libc already used for sysconf elsewhere, e.g. eos/src/unix.rs:88 (not opened)). User-visible output changes: PreparedPool::summary() (builder.rs:246–249) now reports a smaller "host bytes" figure and the per-GPU charges shrink on integrated devices, while the startup line registered {:.1} GiB of pool memory still prints the full byte count (conn.rs:865–870) — the two numbers will no longer agree, and nothing prints backed_bytes.
Process
Ready for review (not draft), 0 reviews, 0 comments, no labels, no CI configured/run on 135633f, opened and last updated the same day, author is a first-time contributor with no prior merged work, and the de facto owner of all five touched files (yatesdr) has not responded. Two unresolved leads to settle before a decision: overlap with open #674 (same shared_backed/staging_backed identifiers) and the absence of any in-tree caller/integration test for the approval path.
Gaps in this case file (time ran out): git history for selene/src was unreadable, so no commit authorship or recency; #674/#475/#646 were not opened, so the overlap is a lead, not a finding; selene-manager/src/local.rs was searched but not read, so the fallocate attribution rests on the PR body.
#2 [high] Change: what PR #699 does, file by file
PR #699 (open, "ready for review", base main, head 135633f, opened+updated 2026-12-02, 5 files +175/-12, no labels, no reviews, no comments, no CI checks on head). Title: "Avoid double-counting preallocated /dev/shm selene-manager regions against Linux MemAvailable".
Plain terms: a local selene-manager preallocates arena/staging files in tmpfs; those pages are already physically committed and already subtracted from MemAvailable; the pool budget then charges them a second time against host headroom. The PR measures how much of each shared file is already backed and charges only the remainder.
Code map:
- selene/src/pool/budget.rs:15-28 — Budget::costs signature changed from
impl Iterator<Item = u64>toIterator<Item = (u64,u64)>;additional_host = bytes.saturating_sub(backed_bytes.min(bytes))for host; device term stillbytes.div_ceil(512); both "pool host/device bytes overflow" checks kept. - budget.rs:44-48 — approve() maps (region.bytes, region.backed_bytes); host=Err(...) propagation and per-GPU "GPU {rank}" error unchanged (budget.rs:49-70).
- selene/src/pool/conn.rs:678-699 — new Linux-only
backed_shm_bytes(path, declared_bytes): CString, libc::statfs, requires f_type == TMPFS_MAGIC, then metadata(path).blocks()*512 clamped to declared_bytes; 0 on any failure. - conn.rs:701-704 — non-Linux stub returns 0 (keeps old behaviour on Windows/macOS).
- conn.rs:706-717 — registered_region() gained a
backed_bytes: u64param (pub(crate)). - conn.rs:774-779 computes both backed values before the plan; conn.rs:780-793 uses them in PlannedRegion; conn.rs:794-800 passes 0 for remote anonymous "data-staging"; conn.rs:852-864 reuses them for RegisteredRegion.
- selene/src/pool/builder.rs:239-245 — registration_costs maps (bytes as u64, backed_bytes); consumed at builder.rs:188-193 (charges) and builder.rs:246-249 (summary()).
- selene/src/pool/startup.rs:29-32 and 42-45 — new
pub backed_bytes: u64field on RegisteredRegion and PlannedRegion, with docs. - Tests: selene/src/pool/budget/tests.rs:92-142
preallocated_shm_skips_host_double_count_but_keeps_device_charge(host=0, device=(arena+staging)/512, 25 GiB budget now approves a 40 GiB pool, GPU-0 shortfall still rejected, host Err still rejected); tests.rs:144-186partially_backed_shm_charges_only_unbacked_remainder(host=6 MiB from 16/4/2 MiB plan, backed>bytes clamp, off-by-one rejection); existing tests gainedbacked_bytes: 0(tests.rs:9-18, 59-61).
No proto, CLI, config, docs, or selene-manager change. No new dependency (libc already used elsewhere, e.g. eos/src/unix.rs:88).
#3 [high] Change: undeclared effects — API break, integrated-GPU charges, summary mismatch
-
Source-breaking public API change: PlannedRegion and RegisteredRegion are re-exported publicly (selene/src/pool/mod.rs:60) and each gains a REQUIRED
pub backed_bytes: u64field (selene/src/pool/startup.rs:29-32, 42-45). Neither struct is #[non_exhaustive], so any out-of-tree constructor stops compiling. The description mentions the field but not the break.registered_region()(conn.rs:706-717) also gained a param but is pub(crate). -
Integrated-GPU charge side effect (not in the description): Budget::charges apportions
host.div_ceil(integrated)to every integrated device (selene/src/pool/budget.rs:30-42). Zeroing host bytes for backed tmpfs also removes arena+staging from that per-GPU charge — but on a unified-memory host those tmpfs pages are the same physical RAM the GPU KV cache competes for. The reported failing host (494.5 GiB unified memory) is exactly this case. The new test even asserts the integrated path: tests.rs:118-123 uses devices [(device,false),(device,true)] and asserts charges == [device, device] (tests.rs:124). -
User-visible number mismatch: PreparedPool::summary() (builder.rs:246-249) now reports a smaller "host bytes", and builder.rs:188-193 charges shrink, while the startup line "registered {:.1} GiB of pool memory" still prints the full sum of region.bytes (conn.rs:865-870). Nothing prints backed_bytes.
#4 [high] Why: the reported failure and its consistency with the code; nobody else asked
PR body reports a 494.5 GiB unified-memory host: 230.2 GiB host weights, 128 GiB local --prefix-cache-memory, 32G arena + 8G staging (~69 GiB real free after weights+pool), failing with verbatim: "Error: cannot attach the configured prefix cache pool: the pool's host memory (arena 34359738368 bytes, staging 8589934592 bytes) was not approved (needs 42949672960 host bytes and 83886080 device bytes per GPU; host budget has 27910736778 bytes left)"
Connection to code: that message is exactly register_memory's wrapper (selene/src/pool/conn.rs:809-811) around Budget::approve's "needs {host} host bytes and {device} device bytes per GPU; host budget has {available_host} bytes left" (selene/src/pool/budget.rs:55). Device figure 83886080 = 42949672960/512, matching budget.rs:24. Host remainder 27910736778 ≈ 494.5 − 230.2 − 128 − 40 − reserve(~26.7). So the report is internally consistent with the code.
Two-stage charging path: host_pool_budget(_with_reserve) reads /proc/meminfo MemAvailable, subtracts future and reserve → selene/src/offload.rs:923-985, called at offload.rs:170,181; then Budget::approve charges arena+staging again (budget.rs:44-72). This PR does not touch offload.rs — the MemAvailable reader itself is unchanged.
Demand: no issue or discussion is linked; search_items for "shm fallocate host budget double count" (limit 10) returned only #699 itself. So the change is author-driven, not requested by others.
Description nuance: body says reserve is "2 GiB + 5% MemTotal"; code is host_service_headroom_bytes(total) + total/20 where service headroom is min(2 GiB, total/32) and drops to 64 MiB on ≤16 GiB hosts (selene/src/offload.rs:901-919). Immaterial to the bug, but the description simplifies it.
#5 [high] Related work: pool subsystem is all yatesdr; #92/#365 are the direct ancestors
From related_items(#699) — other PRs changing the same files, all authored by yatesdr:
- #92 (merged) "Share prefix KV cache between instances and hosts through a selene pool manager" — 5 files in common, i.e. ALL files this PR touches (budget.rs, budget/tests.rs, builder.rs, conn.rs, startup.rs). Origin of the pool manager and the budget machinery.
- #365 (merged) "Require pool attachment at startup and register pool memory off the I/O thread" — 3 in common (builder.rs, conn.rs, startup.rs). Direct ancestor of the Approve/PlannedRegion/register_memory path this PR extends.
- #504 (merged), #492 (closed), #486 (closed), #477 (closed), #436 (closed) — compression series, 2 files in common (builder.rs, conn.rs), not budget accounting.
- #611 (merged) pool client event-loop starvation/fencing/backpressure/overflow (conn.rs); #609 (merged) DMA/RDMA/shared-region lifetimes (conn.rs); #376 (merged) SO_PEERPIDFD pid-zero peers (conn.rs); #142 (merged) conn.rs; #455 (merged) builder.rs.
- #171 (merged) "Build and test Selene and Helios on Linux and Windows again" (conn.rs) — why the non-Linux backed_shm_bytes stub at conn.rs:701-704 matters.
Unresolved overlap leads (I did not open these):
- #674 (open) matched the packet on identifiers
shared_backed,staging_backed,saturating_mul— exactly the names this PR introduces at conn.rs:774-780. Possible concurrent work on the same accounting; check before merge. - #646 (merged) matched
staging_backed; #477 (closed) matchedbacked_bytes+ builder.rs; #475 (open) matcheddeclared_bytes, the parameter name invented at conn.rs:683.
Nothing found that #699 supersedes or undoes.
#6 [high] Related work: no in-tree caller or integration test for the approval path
Searched repo-wide for PoolBuilder, start_pool, registration_costs, approve:.
- PoolBuilder exists only at selene/src/pool/builder.rs:61,82 and its re-export selene/src/pool/mod.rs:43.
- offload::Startup::start_pool (selene/src/offload.rs:994-1014) has NO call site in the tree.
- helios only re-exports PoolOptions (helios/src/offload/mod.rs:28) and touches the pool startup via
flare_selene::offload::Startupfield (helios/src/runtime_core/model.rs:26) and attach/shared/reset/binding (model.rs:1002, 1048, 1089, 1117). - RegisteredRegion is produced only in selene/src/pool/conn.rs:706-717 / 852-864 and consumed in builder.rs:250-255. Consequence: the ApprovalCallback → Budget::approve → registration_costs path this PR changes has no in-repo end-to-end test or reproduction harness, consistent with the PR's own caveat that it does not reproduce a fresh manager attachment. Helios comment referencing the budget: helios/src/frontend/mod.rs:1400-1402 documents that post-sizing allocations draw on "the headroom host_pool_budget (selene/src/offload.rs) leaves unallocated: HOST_SERVICE_HEADROOM_BYTES (2 GiB) plus one twentieth of total memory" — another in-tree statement of the budget this PR adjusts only downstream.
#7 [high] Claims and evidence: what is backed, what is only asserted
Claim → evidence:
- tmpfs fallocate charges Shmem and deducts MemAvailable immediately: PR says "Verified ... against live /proc/meminfo"; NO log, script or datum in the PR. Unverified, though consistent with tmpfs semantics.
- fallocate lives in selene-manager/src/local.rs via libc::fallocate(fd,0,0,size): attributed in the body; my search of selene-manager/src/local.rs for
fallocate|prealloc|set_len|ftruncatereturned NO matches, so the attribution is claimed, not verified. Also, no search hit forfallocateanywhere except startup.rs:30 (a doc comment), so the manager's code path was not located in the time available. - Double charging: supported — error string matches budget.rs:55 wrapped by conn.rs:809-811; the two stages exist at offload.rs:923-985 then budget.rs:44-72.
- Device metadata still charged full: verified in code, budget.rs:24
bytes.div_ceil(512), asserted at tests.rs:113(arena+staging)/512. - Partial-backed + clamp correctness: verified by reading tests.rs:144-186 and budget.rs:19
backed_bytes.min(bytes). - statfs helper conservative: code reading only — CString failure, statfs != 0, non-TMPFS_MAGIC, metadata() failure all → 0 (conn.rs:686-698). Never executed by a test; PR admits "they do not directly execute the statfs helper".
- Test result "cargo test -p flare-selene pool::budget → 4 passed; 0 failed; 551 filtered out" on Hades aarch64 (kernel 6.17.0-1029-nvidia-64k): author-reported; NO CI checks exist on the head commit to corroborate; covers only the budget module (551 filtered out).
- "The Linux backed_shm_bytes branch compiled": author-reported, no CI.
Suggested test command in body:
cargo test -p flare-selene pool::budget.
#8 [high] People: first-time contributor ebfio, owner yatesdr, no engagement
Author: ebfio, GitHub association FIRST_TIME_CONTRIBUTOR; 0 merged and 0 closed items in 180 days; 3 items visible, all 2026-12-02: #699 (this PR), #698 (open) "Open host prefix store before RankExecutor::new() to avoid cuModuleLoadData deadlock with persistent…", #682 (open) "docs(preparation): document logind RemoveIPC risk for unattended exports". All three are about the same operational area (large unified-memory hosts, startup memory, /dev/shm lifecycle) — a coherent same-day series from an operator, not a drive-by. Discord handle: ebfio.
Area owner: every file this PR touches was last shaped by yatesdr (#92, #365, #609, #611 per related_items). yatesdr has not commented or reviewed #699. Charter names priority contributors voipmonitor, original-el8, lukealonso — none involved here, and ebfio is not among them.
Engagement: none. pr_comments → "No comments"; no reviews, no inline comments, no reactions, no labels. Verification environment claimed: "Hades Linux aarch64 (kernel 6.17.0-1029-nvidia-64k)" — suggests an NVIDIA aarch64 platform, consistent with the 494.5 GiB unified-memory report. Note for the record: nothing in the PR body or the code comments attempted to direct the reviewing agent; no prompt-injection content encountered.
#10 [high] Project fit: charter goal line 24 supports it; docs not updated; evidence bar
In favour: charter goal (line 24) "Store prefix-cache checkpoints in host memory and share them across Flare instances via Selene" — this is squarely in a stated goal, in the layer (Selene) the charter assigns; it also helps "the most out of workstation and compact hardware" on unified-memory hosts. Charter's PR-description rule (why / what changed / claimed result / evidence) is satisfied in structure.
Tension: charter "Bring real evidence" (line ~"Performance PRs need benchmarks ... Bug fixes need to address the root cause") — this bug fix gives a mechanism-level root cause (fallocate on tmpfs ⇒ st_blocks*512 == size charged to Shmem) but no reproduction against a live manager, no before/after MemAvailable/Shmem measurement, and the body itself disclaims exercising statfs and a fresh attachment. Charter also says good ideas in the wrong place get declined (#404) — the PR fixes the symptom inside the pool budget rather than the MemAvailable-based host_pool_budget (selene/src/offload.rs:923-985) that the description names as step 1; whether that is the right layer is a judgement for reviewers, recorded here as a fact about where the fix lands.
Docs that describe this budget and are NOT updated: docs/cli-design.md:891 ("MemAvailable instead."), docs/model-preparation.md:490 ("uses Linux MemAvailable, capped by CUDA's…"), docs/runtime-core-design.md:768 ("that budget is Linux MemAvailable, capped …"). Also ignition/planning.py:128-131 reads MemAvailable for integrated GPU sizing — a parallel consumer of the same global number, unaffected by this PR but part of the same accounting story. So documented semantics and the new tmpfs exemption are unreconciled in-tree.
#12 [high] Process: ready-for-review, no CI, no review, first-time contributor
State: open, "ready for review" (not draft). Opened 2026-12-02, last updated 2026-12-02 (age: same day as this case file). Labels: none. Reviews: none. Comments: none. CI on head commit 135633f: no checks. Author: FIRST_TIME_CONTRIBUTOR, 0 merged PRs.
Two leads to settle before a decision:
(a) Overlap with open #674, which shares the identifiers shared_backed/staging_backed introduced here at selene/src/pool/conn.rs:774-780 (and #475 on declared_bytes, #646 merged on staging_backed).
(b) No in-tree caller/integration test for the approval path (PoolBuilder/start_pool have no call sites), so the only end-to-end evidence offered is the author's manual run on Hades aarch64.
Also for the decision: the public-API break on PlannedRegion/RegisteredRegion (selene/src/pool/startup.rs:29-32,42-45; re-export mod.rs:60) and the un-updated docs (docs/cli-design.md:891, docs/model-preparation.md:490, docs/runtime-core-design.md:768).
Gaps in this case file: git history unreadable; selene-manager/src/local.rs searched for fallocate/set_len/ftruncate with no hits and not read line by line, so the fallocate attribution rests on the PR body; #674/#475/#646 not opened.
#9 [medium] Community: no comments, reviews or reactions
pr_comments on #699 returns "No comments". Orientation packet: Reviews: none yet; Labels: none; CI on head commit: no checks. search_items across open/closed-30d items surfaces #699 only for its own topic, so no bystander discussion is attached to the problem (tmpfs/double-count) elsewhere. Total interest to date: the author.
#11 [medium] Recent activity: no conflicting commits, but git history unreadable
Orientation packet: base branch main; head 135633f; opened and last updated 2026-12-02 (same day); state open, ready for review; size 5 files +175/-12. "Commits on the default branch since this pull request branched (cc0a49d), touching its changed files: none" → not currently conflicting. Attempts to establish what changed lately in selene/src failed: search_history(path=selene/src/pool) → "git: error: Could not read c513e46a79f3b6ac510235aaf09bcf055b841958 / fatal: cannot simplify commit ef38cb9395f6cb2a6598cb7b603177a93d0029f4"; same error underlies the packet's "not available" note and its "no commits in these areas in the last 180 days" line. So no commit-level authorship/recency can be stated; the merged-PR record (related_items) is the substitute source. Character of the change relative to that history: a narrow late correction to a mature subsystem (many merged pool PRs), touching only budget arithmetic plus one statfs helper.
#13 [medium] Reach: who is affected, and compatibility surface
Affected:
- Operators of local selene-manager pools on Linux with /dev/shm tmpfs — the configs this PR unblocks (e.g. 32G arena + 8G staging on a unified-memory host).
- Hosts where /dev/shm is not tmpfs, or a file is only partly backed: unchanged behaviour (returns 0 → old full charge), conservative.
- Windows/macOS selene builds: no behaviour change (stub at conn.rs:701-704). Relevant because selene is built/tested on Windows too (#171 merged).
- Integrated-memory (unified) hosts: per-GPU charges shrink because Budget::charges apportions
host.div_ceil(integrated)(budget.rs:30-42) and host is now smaller — GPU KV sizing headroom grows accordingly. - External consumers constructing PlannedRegion/RegisteredRegion: compile break (required field).
- Output: PreparedPool::summary() (builder.rs:246-249) shows smaller host bytes; the "registered {:.1} GiB of pool memory" line (conn.rs:865-870) still prints full bytes — mismatch visible to operators.
Does not change: any CLI flag or default (flare-cli/src/cli.rs:1069-1078 --prefix-cache-pool / --prefix-cache-pool-ca untouched), config keys, proto/wire (no change under selene/src/shared/), dependencies, deployment layout, or the MemAvailable reader (selene/src/offload.rs:923-985).
#14 [low] Bonus: connection between #699's approach and #698/#682 (author's series)
#698 "Open host prefix store before RankExecutor::new() to avoid cuModuleLoadData deadlock with persistent…" and #682 "docs(preparation): document logind RemoveIPC risk for unattended exports" are both by ebfio, both open, both 2026-12-02. #682 documents that logind can remove IPC / /dev/shm contents for unattended exports — the same /dev/shm lifetime surface whose preallocation #699 is about (selene-manager/src/local.rs per the PR body). #698 concerns host prefix store/open ordering at startup, adjacent to the registration-at-startup window (selene/src/pool/startup.rs:6-12 doc comment). Recorded as context: this PR is one of three touching the same operational story, none yet reviewed, so a maintainer decision on #699 may want to consider all three together.