Contracts, Charter & Verification Gates Audit — PR #713 (4efd9fd, 11 files, +779/−48)
Verdict
No contract or verification gate blockers. All four hard gates pass. I found no signed-format/wire/captured-graph change, no vendored-file fork, no unmerged-external dependency, no applicable mandatory formal/GPU gate that was skipped, and no reported failing test or failing CI check. Three non-blocking observations are recorded at the end (evidence gap on the claimed benefit, undocumented user-visible precedence rule, unverifiable design sign-off identity) — none of them is a repository-governance gate violation.
Gate 1 — Signed core-format / wire / captured-graph / public contract boundaries: PASS
- No new proto, core-format, wire kind, or captured-graph operation. The PR adds no Protobuf field/enum, no graph kind, no op contract, no prepared-metadata field. The changed files are
flare-cli/src/{config,core_cache,distribution,main}.rs,flare-cli/src/orbit/{agent,controller}.rs, andhelios/src/{lib.rs,core/cache.rs,runtime_core/{driver,memory,mod}}.rs.CUDA_ERROR_OUT_OF_MEMORY = 2(helios/src/runtime_core/driver.rs:94–95(not opened)) is a mirror of an existing CUDA driver status code, not a new wire or graph identifier; it is consumed only by comparison against the driver's returned status (helios/src/runtime_core/mod.rs:382,memory.rs:130). Thereforedocs/design-review.mdprinciple 1's "introducing a captured-graph operation family requires prior explicit approval from Luke Alonso" is not triggered, and no owner approval is owed. - Peer-distribution wire protocol is unchanged.
flare-cli/src/distribution.rs:38still readsconst VERSION: u32 = 4;andMAX_FRAME/TIMEOUT/IO_TIMEOUTat:39–41are untouched.serve_sourcestill answers the same request with the samecache::range_bytescount frame and the same payload bytes (distribution.rs:1201–1216); the only change is how the bytes are read from disk (copy_source_ranges→copy_ranges_direct,:1319–1336). Byte-for-byte parity withcache::RangeReaderis asserted against the buffered reader atdistribution.rs:1845–1850and:1928–1942. No wire contract change, so no cross-version compatibility question arises. - No contradiction of the normative scheduling/core-format documents. Nothing under
docs/scheduling-theory.md(not opened),docs/scheduling-runtime-design.md, ordocs/core-format-design.mddescribes the distribution read path or the kernel page cache — I searched all three forO_DIRECT,page cache,MemAvailable,readahead,reserveand found no governing statement. - The one normative memory statement is consistent, not contradicted.
docs/runtime-core-design.md:783–786states that on integrated GPUs the budget "is LinuxMemAvailable, capped by CUDA's device total … reclaimable page cache contributes to available memory". This PR deliberately does not change that budget:shared_availablestill delegates straight toflare_selene::offload::available_memory(helios/src/runtime_core/memory.rs:30–33), unmodified. The new code only describes the state (appendsMemFree / MemAvailable / Cachedto thePlan cachesummary atmemory.rs:1256–1268, and toCudaError.descriptionon context-creation OOM atmod.rs:375–388). Normative doc and implementation remain aligned, so no normative-doc update is owed by Gate 1. (That the documented model is empirically wrong on GB10 is a correctness-lens matter, outside this audit.) - The
[memory] reserveinheritance does not contradict any signed contract — it discharges a doc/implementation mismatch that the docs already state as normative.docs/cli-design.md:1484("Serving memory budget | Runtime--memory-limit, then configured[memory] reserve, then the core reserve"),docs/cli-design.md:759and:895already specify this ordering, anddocs/orbit.md:182states "flare orbit runtakes the serving flags offlare run".flare-cli/src/config.rs:152–161now makes that true fororbit run, matching theCommand::Runbranch at:76–80. This is a shipped default becoming documented behaviour, not an undocumented default contradicting a normative doc. docs/orbit.md:467("The planner does not set--memory-limit; groups on disjoint GPUs retain their own serving memory settings") also survives: the planner is untouched, and the new merge rule preserves a saved group's limit —merge_serving_optionsatflare-cli/src/orbit/controller.rs:1972–1997skips a config-inherited--memory-limit(both--memory-limit Xand--memory-limit=Xforms) wheneverhas_memory_limit(saved)is true, gated onmemory_limit_from_config(controller.rs:169,:695; set atflare-cli/src/main.rs:538–540fromvalue_source("memory_limit") != CommandLine). Explicit CLI still wins. This is the exact analogue of the already-documentedtransfer_streamsrule atdocs/orbit.md:632–634.
Gate 2 — Vendored upstream dependencies & cross-PR conflicts: PASS
- No vendored upstream file is modified or forked. The changed-file list contains no
helios/native/file (noroce_proxy.c(not opened)), no third-party tree, and no patch file. The only "native" looking work is Rust. - No new or unpinned external dependency.
helios/src/lib.rs:38–41re-exportsFileReadAt, allocate_aligned, direct_reopen, free_aligned, release_page_cache, release_page_cache_rangefromflare_eos, which is an in-workspace crate that already contains all of them onmain:eos/src/lib.rs:48(not opened) (allocate_aligned),eos/src/unix.rs:61(not opened) (direct_reopen),:68(release_page_cache),:74(release_page_cache_range). These were introduced by merged #667. The PR adds noCargo.toml(not opened) change (not in the file list), so no dependency, version, or commit pin is added. - No dependence on an unmerged external recipe or PR. All three sub-changes are self-contained Rust in this repository; nothing references an unmerged upstream patch, branch, or recipe revision, and no placeholder/
git-path dependency appears. - No conflict with newer
mainwork in these files (11 files untouched onmainsince branch pointcc0a49d, per the Discovery Dossier). The pollutedpr_diff(merged #690/#702/#707 content) is a stale-merge-base artifact; I audited the 11 files at the PR head, not the diff.
Gate 3 — Mandatory verification evidence (design-review Layer 3): PASS
TLA+ / Kani / mutation gates — not triggered. docs/design-review.md:209–228 mandates python3 verification/helios-lifecycle/check.py (not opened) only for changes to "admission, fences, generations, cancellation, speculation accounting, cache compaction, snapshot aliases, response buffering or ownership, offload aggregation, readiness, or rank coordination", and Kani only for completion-vector validation, prepared completion contracts, state-view extent arithmetic, or sequential validators. Checking each touched site against that list:
helios/src/runtime_core/mod.rs:375–388wrapscheck_ctxforcuDevicePrimaryCtxRetain/cuCtxCreate_v2— it only rewritesCudaError.descriptiontext; the status value, error variant (ExecutionError::Driver(CudaError { code: 2, .. }), asserted atmemory.rs:2367–2371), and control flow are identical (driver.checkresult is mapped, never swallowed). No readiness, fence, generation, cancellation, or rank-coordination transition changes.helios/src/runtime_core/memory.rs:1256–1268appends to thePlan cacheprogress summary; the phase name (helios/src/startup.rs:74(not opened)) and the sizing computation are untouched.helios/src/lib.rs:38–41is a re-export list — no behavior.helios/src/core/cache.rs:4398, 4441, 4511, 4772, 4774are in the payload store (write_stream,verify_file,hash_file,copy_file), not the prefix-checkpoint cache. The cache-ownership modelCacheOwnership.tlacoversPrefixCheckpointCache, which lives in a different file,helios/src/cache.rs:208(not opened) — not among the 11 changed files. So the "cache compaction"/"snapshot aliases" trigger is not met either.- No scheduler, admission, dispatch, or
helios/src/execution/{threaded,parallel,roce}*file is touched, so the cross-rank barrier test requirement (Layer 1) and the mandatory multi-GPU collective requirement are not engaged.
Layer 1 CPU checks — reported for every affected crate, at --release --locked. flare-cli (251 passed) and helios --features runtime-core,server (1948 passed) are exactly the two crates the PR changes, run with cargo test --locked --release as Layer 1 requires; flare (255 passed) was run too, and clippy --all-targets plus rustfmt --edition 2024 --check are reported. No Python file is touched, so no pytest suite is owed. These are self-reported, but they are not contradicted by anything in the description or the Discovery Dossier, which explicitly confirms "Everything the description claims is present in the tree; I found no claimed change that is missing."
No failing test and no failing CI check on 4efd9fd. The description reports 0 failed in all three crates; the Dossier states there are no CI checks at all on the head commit and no comments, reviews, or labels. Since nothing reports a failure or an explicit refusal to run tests on this non-trivial change, and my tooling cannot observe GitHub Actions check runs, I do not raise a CI finding — per the calibration rule against unobservable-CI false positives. I note only that the reported counts are unverified by any repository artifact.
Performance-benchmark gate — trigger not met. docs/design-review.md principle 12 / charter #210 require a main-vs-branch served-workload A/B when a speedup is claimed. This PR claims no speedup and publishes no performance number: it explicitly states the trade-off ("O_DIRECT peer serving drops kernel readahead in exchange for avoiding page-cache accumulation") and discloses "live GB10 impact remains unmeasured" and that GB10 CU_DEVICE_ATTRIBUTE_INTEGRATED / context-creation CUDA_ERROR_OUT_OF_MEMORY behaviour is "unconfirmed". Disclosure of unrun hardware checks is precisely what principle 12 asks for, and the non-substitution rule at docs/design-review.md:247–251 ("Disclosure does not excuse skipping runnable CPU checks") is satisfied because all runnable CPU layers were run. See observation (1) for the residual risk this leaves.
Gate 4 — Material scope / claim contradictions: PASS
- No fabricated artifact. There is no reference to a benchmark, TLA+ run, GPU run, or test file that is absent from the diff. Every described mechanism is present at the cited lines:
copy_ranges_direct(distribution.rs:1268–1317) withDIRECT_BLOCK 4096/DIRECT_CHUNK 4 MiB(:1221–1223), unconditional post-copy range release including the error path (:1330–1332, no?on the copy result), mid-streamEINVALfallback (:1305–1311), buffered fallback with release (:1255–1265, :1335), aligned-EOF/offset trimming (:1284–1303); the four new buffered sites (core_cache.rs:450, 455, 505, 562;agent.rs:2046 (not opened), 2068;controller.rs:1465;helios/src/core/cache.rs:4398, 4441, 4511, 4772, 4774); the reserve inheritance and merge rule (config.rs:152–161;controller.rs:169, 695, 1967–1997;main.rs:538–540) with tests atcontroller.rs:3794; and the meminfo diagnostics (memory.rs:35–140, 1256–1268, 2276–2409;mod.rs:375–388;driver.rs:94–95(not opened)). The descriptionRefs #630rather thanFixes #630, which is honest about the partially-addressed ask. - Not "bundling unrelated standalone tooling." +779/−48 across 11 files is three changes for one reported defect and its operator workflow, all inside the product crates; no tooling, no generated dumps, no audit artifacts. The three parts are independently reviewable (which the value lens already recommended splitting) but they are not unrelated scope expansion under
AGENTS.md#contribution-scope-and-rejection-criteria. - The
design-review=2e5bmention is not a contradiction.docs/design-review.md:294–299places theDesign-Signed-Off-By: <reviewer identity>; design-review=<hex>trailer in the commit message, not the PR description. The description reports that.githooks/commit-msgpassed; that hook validates the trailer against the staged checklist (:335–340). The commit message itself is not readable in this copy (search_historyfails on an unreadable commit, per the Dossier), so I can neither confirm nor refute the trailer and do not raise it as a finding.
Non-blocking observations (reported, not gate violations)
- The claimed benefit is unmeasured on every affected path, and #630's primary ask is untouched (evidence risk, not a gate breach). The PR's stated purpose is to stop the KV-plan loss that #630 measured at −37.8% (13.0 GiB / 1,961,984 tokens vs 20.5 GiB / 3,153,664). #630's 2026-12-02 comment records that merged #667's release calls did not clear the ~9 GiB controller page cache by plan time, and the sizing path is unchanged (
memory.rs:30–33still returnsflare_selene::offload::available_memory), so whether the four new sites plusO_DIRECTchange the observed plan is open. The reporter offered a ~5-minute instrumented reproduction on the hardware. I record this as the single largest weakness in the evidence chain, but it is disclosed, it is hardware-only (not a skipped CPU layer), and no speedup number is claimed — so it is an evidence-quality matter for the value lens rather than a Layer-3 gate violation. - A new user-visible precedence rule ships with no documentation, and no docs file is touched (0 of 11). The rule "saved persistent-group
--memory-limitbeats a config-inherited one; an explicit CLI flag beats both" (controller.rs:1972–1997) is exactly the shape of the documentedtransfer_streamsrule atdocs/orbit.md:632–634, but nothing analogous is written for--memory-limit; the newPlan cachefields, the stderr page-cache warning (memory.rs:106–114), and thedrop_cacheshint insideCudaError.description(memory.rs:133–137) also have no documented home (docs/cli-design.md:1436–1484is the natural one). This is a documentation gap underAGENTS.mdprose rules, not a contradicted normative invariant —docs/cli-design.md:1484,:759,:895anddocs/orbit.md:182already state the default the PR now implements. docs/orbit.md:467's "groups … retain their own serving memory settings" is now true only for groups that saved--memory-limit. Groups without a saved limit and a host[memory] reserveinherit the reserve. That is the documented budget order (docs/cli-design.md:1484) and each node reads its own host configuration (docs/cli-design.md:1381), so I read this as wanted behaviour, but it is a silent KV-budget change for existing configs and should be stated indocs/orbit.mdalongside the persistent-group section (docs/orbit.md:374–402).
What I checked and did not find
No docs/core-format-design.md, docs/scheduling-theory.md (not opened), or docs/scheduling-runtime-design.md invariant is contradicted; no Protobuf/enum/wire/graph addition; no helios/native/ or vendored third-party change; no new crate dependency or unpinned external reference; no touched scheduler, admission, dispatch, execution-transport, or PrefixCheckpointCache code that would trigger verification/helios-lifecycle/check.py (not opened), Kani, or mutation testing; no reported failing test or failing CI check on 4efd9fd; no fabricated benchmark or verification artifact.