Pre-test report — PR #589 (merged): CUDA 12 batched copies, Linux ARM64 release portability, Selene unified-memory budgeting
Recommendation: REFER TO TESTING — but only a minimal, gated slice. Do not test the PR's headline claim (the CUDA 12 cuMemcpyAsync fallback): it is unreachable on both available hosts. Two substantive defects must be fixed first; one cheap CPU-only check is worth more than any GPU job here.
Head aed8039, already merged to main (ba3afb13, 2026-11-28, same day, zero human review, while sibling PRs #497/#323 carried review rounds). I read all 21 changed files at head rather than relying on the six summaries, and corrected three points where they are wrong or overstated.
1. What the change actually is
Four independent outcomes in one 21-file, +994/−133 PR:
- CUDA <13 copy fallback (
helios/src/cuda.rs:824-833): whencuMemcpyBatchAsync_v2is absent,Stream::copy_batchnow loopscuMemcpyAsyncper entry instead ofcuMemcpyDtoDAsync_v2, which rejects pinned host pointers. - Lazy
libibverbs.so.1(helios/native/roce_proxy_dlopen.c, new 236 lines;helios/build.rs:67-77linksdl+pthreadinstead ofibverbs) plus a rewritten.github/workflows/release.yml(not opened) that builds insideubuntu:22.04and asserts nolibibverbs.soDT_NEEDEDand noGLIBC_> 2.35. - Selene/helios host budgeting: scaled reserve (
host_service_headroom_bytes: 64 MiB ≤16 GiB, elsemin(2 GiB, total/32)), a pre-planned budget threadedallocate_caches→prepare_offload→prepare_with_inputs_budget, and aHOST_NUMA→SlabPool::sized+cuMemHostRegister_v2fallback. eos/src/unix.rs::map_hostdropsMAP_POPULATE, advisesMADV_HUGEPAGEfirst, prefaults viaMADV_POPULATE_WRITE.
Charter fit: outcome 3 repairs support already on main (helios/src/core/naming.rs:15 (not opened),54-57 lists ga10b; ignition/planning.py:38 (not opened) advertises SM87), so the "charter Non-Goals / needs maintainer sign-off" charge in the Architecture and Value reviews is unfounded — I checked. The genuine scope problem is the four-in-one bundling: a regression in one cannot be bisected from the others.
2. Substantive problems — fix before spending hardware time
S1. CUDA_ERROR_INVALID_VALUE is classified as "platform unsupported" — helios/src/cuda.rs:535-537
matches!(status, 1 | 801) is applied at four sites inside try_map_device_host_parts: :579 (cuDeviceGetAttribute), :587 (cuMemGetAllocationGranularity), :642 (cuMemCreate), :658 (cuMemSetAccess). Each returns Ok(None), which silently swaps the split HOST_NUMA pool for a registered anonymous mapping with different properties. Status 1 is the generic "invalid argument" code, so a real bug in the mapping path degrades into a different allocation strategy instead of failing. The doc at :539-547 ("real failures … return Err") is only true for non-1/801 — the PR description's "real errors such as OOM propagate unchanged" overstates it.
Partial defence I verified: ATTRIBUTE_HOST_NUMA_ID = 134 (cuda.rs:150) is CUDA 12.2+, so an older driver legitimately returns INVALID_VALUE for an unknown attribute — status 1 is defensible at the two probe sites, and not at cuMemCreate/cuMemSetAccess. Minimal fix: restrict those two to 801, keep {1, 801} for the probes with the driver-version reason written down. Note cuMemAddressReserve (:609-611) still hard-errors, so a non-HOST_NUMA platform can also Err depending on which call reports first.
S2. integrated_offload_host_budget duplicates limited_budget and already diverges — helios/src/runtime_core/memory.rs:192-221 vs :267-298
The new function restates the explicit---memory-limit arms of the existing limited_budget in the same module, but for a Bytes/Fraction cap smaller than loaded + future it saturates to 0 (:216) where limited_budget raises "memory limit is {cap} bytes, but loaded model resources require {required}" (:294-296). That is an operator-reachable silent under-sizing of the prefix-cache host pool, and it is exactly the class of double-accounting bug this PR set out to remove. Related, same function: integrated_state (:646-683) recomputes the per-rank loop at :877-909 and the copies already disagree (min total at :657-661 vs observations[index].total at :887; max observed drop at :674-680 vs initial[index] at :904). Collapsing to limited_budget(memory, loaded, options.memory_limit, 0, true, future) removes ~93 lines including the test that currently pins the copy.
S3. The dlopen symbol table is unverified and could be fatal for all multi-host RoCE — helios/native/roce_proxy_dlopen.c:84-100
FLARE_LOAD_IBV (:72-82) hard-fails — dlclose, flare_ibv_ready stays 0 — on any one of 17 misses, and RoceTransport::open (helios/src/execution/roce.rs:192-195) turns that into "RoCE transport setup failed: …". Line :89 requires the plain name ibv_query_port @IBVERBS_1.1; in modern rdma-core ibv_query_port/ibv_reg_mr are static inline in verbs.h (not opened) with the real exports being the ___-prefixed compat forms — the shim's own field type (struct _compat_ibv_port_attr*, :27-28) and its verbs_get_ctx_op/compat reimplementation (:146-154) show the author expected the legacy symbol, but nothing in the tree proves the name resolves. If it does not, multi-host RoCE is completely dead on every host while single-host serving looks fine, and no CI step opens a transport (release.yml:110-121 runs only --version and --help).
This is settled for free: objdump -T libibverbs.so.1 | grep -E 'ibv_query_port|ibv_reg_mr' inside ubuntu:22.04 and ubuntu:24.04. This single CPU-only command is the highest-value check in the whole PR and must run before any RoCE test.
Correction to the review consensus: all six summaries call the new RoCE test vacuous. It is not. helios/src/execution/roce.rs:511-523 asserts inside if status != 0, and the three failure texts differ: a dlopen failure prints "cannot load libibverbs.so.1 (…); install libibverbs1 …" (contains both tokens → passes, correctly), but a missing symbol prints "libibverbs.so.1 is missing required symbol X" — which contains libibverbs.so.1 and not libibverbs1, so the assertion fails. It is weak (silent on success) but it is a real guard for S3, and it runs free.
Defer (documentation/staleness — do not gate, do not test): copy_batch's contract still says "every address is a device address" while the new fallback (:824-827) accepts raw cuMemHostAlloc(flags=0) pointers that the real caller (helios/src/execution/transport.rs:1087 (not opened)) passes; helios/src/frontend/mod.rs:1400-1402 still states 2 GiB + total/20 (the only place the constraint is written down); THIRD_PARTY_NOTICES.md:76-78 still says aarch64 builds link libibverbs in a file shipped in the archive; docs/release.md:30-31 (not opened) asserts JetPack 6 qualification on amd64-only evidence with no docs/TODO.txt entry (I searched — zero matches for JetPack/Orin/GA10B/aarch64/libibverbs); docs/prefix-cache-offload.md:1483-1485 says roce+rdma both link libibverbs (only rdma does now). Dead code worth deleting: cuda.rs:667-676 map_device_host_parts (reachable only via a trait default that CudaRegistrar overrides), helios/src/offload/mod.rs:72 (not opened) prepare (no caller at all), slab.rs:261-270 sized_by_rank (test-only), offload.rs:858-886 host_pool_budget_with_reserve (flag always true in production).
3. Expected value of a hardware test — low for three of four claims
I checked each new path's precondition against the available hardware:
| Changed behaviour | Precondition | cn5 (4× RTX PRO 6000 Blackwell, sm_120, amd64) | cn7 (GB10, sm_121, arm64) |
|---|---|---|---|
CUDA 12 cuMemcpyAsync fallback |
driver lacks cuMemcpyBatchAsync_v2, i.e. CUDA 12.x |
n/a — Blackwell needs r580/CUDA 13 | n/a — GB10 needs CUDA 13 |
| Lazy libibverbs arm64 archive | no libibverbs1; stock JetPack 6 (glibc 2.35) |
wrong arch | has RDMA libs; Ubuntu 24.04-class |
HOST_NUMA → registered fallback |
driver without HOST_NUMA VMM |
reachable | not reachable (GB10 supports it) |
| Integrated-GPU prefix-cache budgeting | CU_DEVICE_ATTRIBUTE_INTEGRATED |
no (discrete) | yes |
eos map_host THP ordering |
any Linux ≥5.14 | yes | yes |
| Multi-host RoCE data path | ≥2 RDMA-linked hosts | no HCA stated | no HCA stated |
Three consequences:
- The headline fix cannot be exercised.
memcpy_batchisOptionpurely from symbol lookup (cuda.rs:282-285); there is no env var or feature flag to force the fallback (I grepped — onlyFLARE_OFFLOAD_TEST_DIRexists). Every cn5/cn7 run takes the unchangedcuMemcpyBatchAsync_v2path. A GPU test would validate nothing about outcome 1. I considered and explicitly reject downgrading cn5 to a CUDA 12.8 driver (sm_120 is supported from 12.8) to reach the branch — disproportionate on shared hardware, and the only regression risk it would expose is already covered by the new unit tests. - The RoCE/arm64 claim is not a GPU question at all. Its glibc ceiling is a property of the build container, provable with
readelf; the symbol-table risk (S3) is provable withobjdump. cn7 is not a stock JetPack 6 host, so it cannot prove the thing the PR claims. - One behaviour genuinely needs hardware: integrated-GPU budgeting on cn7, where
CU_DEVICE_ATTRIBUTE_INTEGRATEDis set and the reserve/budget path runs end to end against a real unified-memoryMemAvailable. This is the part with the largest blast radius and the least test coverage (every new budget test uses a mock registrar and synthetic snapshots).
No throughput A/B is warranted. Nothing in the PR changes a hot path: the fallback keeps the same sequential per-entry loop, and the budget change alters sizing at startup, not speed. Any throughput delta would be a second-order effect of intake capacity, not of this code — and a cross-version A/B on main would be confounded because the change is already merged.
4. Proposed test plan (minimal, staged; abandon on first failure)
Stage 0 — free, CPU only, no hardware booking. Must pass before Stage 1.
objdump -T libibverbs.so.1 | grep -E 'ibv_query_port|ibv_reg_mr'inubuntu:22.04andubuntu:24.04(settles S3).cargo test --release --manifest-path helios/Cargo.toml --features runtime-core,server,roce execution::roce::testson the new shim (now a meaningful check per §2).cargo test --release --manifest-path eos/Cargo.toml(not opened) — the/proc/self/smapsVmFlags: hgassertion.- Re-run the two
selenebudget tests and theHOST_NUMA-fallback/OOM test as a fast sanity gate. If step 1 shows no plainibv_query_port/ibv_reg_mrexport, stop: multi-host RoCE is broken, the PR needs a code change, and nothing below is worth running.
Stage 1 — cn7 (GB10, arm64), one job, ≤60 min. The only GPU-testable claim.
5. Build flare-cli --features roce natively on arm64; confirm it launches (flare --version, flare run --help) with libibverbs1 not installed. This is the one claim no other host can settle, and arm64 native build is the PR's own listed-unrun check.
6. Serve one short model on GB10 (e.g. nvidia/Qwen3.8-27B-NVFP4) with --prefix-cache-memory on, and record the startup Plan cache line: confirm the host budget is non-degenerate and no "host budget cannot hold a full pool capture" failure appears. Then one repeat with an explicit small --memory-limit to exercise the explicit-limit arm of integrated_offload_host_budget — this is the arm S2 says diverges, so capture whether it errors or silently under-sizes.
7. One pool-only capture start (--prefix-cache-memory 0 + --prefix-cache-pool) to confirm capture startup no longer fails post-KV-alloc.
8. Send two or three requests, confirm the prefix cache stores and restores across a restart (this transitively exercises the changed eos::map_host on every pinned mapping, and handshake HOST_NUMA split-pool registration on a healthy driver).
Note: the ≤16 GiB arm of host_service_headroom_bytes is unreachable at 60 GiB RAM — do not try to force it; it is unit-tested.
Stage 2 — cn5, one job, ≤30 min, regression only.
9. Generic single-host serving on 2 of the 4 GPUs at TP2 with --prefix-cache-memory on, which drives the split HOST_NUMA mapping across multiple contexts (slab.rs:191-252), then one restart-and-restore. Purpose is only to prove the untouched cuMemcpyBatchAsync_v2 batch path and the mapping path still work; it validates no new behaviour.
Explicitly do not test: the CUDA 12 fallback (unreachable — see §3); JetPack 6 / GA10B / Windows WDDM (no such hardware); multi-host RoCE data path (no HCAs stated, and Stage 0 may already condemn it); the ≤16 GiB headroom arm; any throughput A/B.
5. Shelf life and caveats
- This PR is already merged, so a test cannot gate it; it can only find a follow-up. Treat the output as regression evidence on
main. - Results may be invalidated quickly: open #323 rewrites
budget()/host_pool_budget()and the system-headroom formula again, and open #497 deletesselene::offload::prepareand removes the veryOption<u64>budget seam #589 re-adds. Keep any test at the behaviour level (§4 steps 6–8) rather than the implementation level, so it stays meaningful across either landing. - Do not test S1 or S2 as-is. Both are defects, not features; testing them on healthy hardware would confirm only that the happy path works and would burn time on code that needs to change. Fix them first.
- No prompt-injection or instruction-like content was found in the PR body, diff, or docs; the security screen's all-clear is consistent with my reading of the diff and the new C file (compile-time literal library name, no
system/exec/fork/getenv).
Bottom line: the PR is worth a small amount of hardware time — one cn7 job for the integrated-GPU budgeting path and the native arm64 launch, plus one cn5 regression job — but its advertised headline (CUDA 12 batched copies) is untestable here and its most dangerous defect (S3, the dlopen symbol table) is diagnosable for free on a CPU. Spend the first ten minutes on Stage 0; book hardware only if it is clean, and fix S1 and S2 before anything is re-tested.