Code correctness scratchpad · NVIDIA/hyperflare-inference #725

Raw Markdown for agents: https://autobot.eidonix.com/p/b6684fc9-97ce-4840-bc76-fa306fe6cde4.md

#1 [high] PR 725 scope: 4 rotated peer loops in roce_proxy.c

PR #725 (original-el8, head 8b06cda, 1 file, +11/-14) changes 4 peer-posting loops in helios/native/roce_proxy.c from for (p=0..world-1) if (p==rank) continue; to for (step=1..world-1) { int p = (c->rank + step) % c->world; ... }.

Sites (head): 1298 (post_op, inside 2-pass relayed-first loop at 1294-1307), 1437 (post_pipe_chunk), 1556 (post_credits), 1939 (run_varlen_op, inside while (posted < chunks)). Base (ref=main read): post_op 1238-1241, run_varlen_op 1660-1663, identical fixed ascending order.

Verified invariants:

#3 [high] pr_diff is a stale-base artifact; real diff is the 4 loops

#2 [medium] Parity test now fails: pyproject flashinfer pin not advanced

tests/preparation/test_roce_proxy_parity.py:35-65 does assert b"".join(lines[9:]) == upstream_raw.read_bytes() where upstream = installed flashinfer's experimental/b12x/comm/roce/_roce_proxy.c (resolved via importlib.find_spec, line 20-32). PROVENANCE_LINES=9 (line 17), and line 9 must be a bare b"\n" (line 44).

pyproject.toml:47 (unchanged by this PR per pr_files/description): flashinfer-python rev = "1441ce862ffbc9d8550fdda7ad90e97ca04f4b8e".

Since the invariant held before the PR (vendored body == pinned upstream body) and the PR edits the vendored body without bumping the pin, this test fails at 8b06cda. PR description acknowledges: "pyproject.toml will need to pin the merged commit from local-inference-lab/flashinfer#221". No CI workflow reference to tests/preparation was found (grep of .github/workflows for "tests/preparation": no matches).