Skip to main content

pp_multi_stream_same_device

Function pp_multi_stream_same_device 

Source
pub fn pp_multi_stream_same_device() -> bool
Expand description

True iff the ppN door would put TWO OR MORE stage streams on ONE device (devices unset = all stages on the primary; or an explicit placement with a repeated device). The deferred-readback (pipelined) arm is REFUSED in this regime: the 2026-08-02 x20 soak record — singledev pipelined 13/20 PASS default, 7 failures each diverging at a different step (timing-race signature); MEMRA_PDL=0 went 20/20 on one soak but a second same-config soak on the auto-gated build failed 2/20 (n2) and battery-4 failed n4 — so PDL narrows the window without closing it, and the true root cause (same Engine kernels concurrent on two streams of one device) is NOT fixed by any flag yet. Cross-device pipelined (one stage stream per device) is 23/23 clean post-fix. Refuse loudly rather than return silently-wrong logits. Env-only read (callable pre-runtime).

ONE MECHANISM OF THAT OPEN ROOT CAUSE IS NOW NAMED AND CLOSED (lane/glm5-accrace 2026-09-01), stated narrowly because it was measured on the SERIAL arm, not this refused pipelined one: a ppN body that returned to its caller published only the producing last stage, so a caller allocation could land under work still queued on a caller-CO-RESIDENT stage stream. That is exactly a “same Engine, two streams, one device” corruption, and it is the reason this predicate’s regime is the dangerous one — on a DISTINCT-device placement only the head stage shares the caller’s context, and a body’s terminal drain already covers it. See PpNRt::publish_all_to and pp_exit_publish. Whether the pipelined arm’s remaining flake is the same mechanism is UNMEASURED; this refusal stands.