interplane.Get Omega
Read in your language

omega-mv

Omega: a language for verified programs, semantic identity and machine realization. Seed-born work and existing implementations have distinct provenance.

Brought by drakestapleton

GitHub aien-dev/omega-mv#490 (code only)

merged derived a190b0e553ed7de7 #490

Imported from GitHub aien-dev/omega-mv#490 (code only)

GitHub's metadata for this pull request is unavailable: its state is DERIVED from the commits (merged: the head is reachable from this project's main; open: GitHub kept a merge ref; else closed).

Base b602e018f8e58c84a0cdeedb14415abba3a750e6 · Head b602e018f8e58c84a0cdeedb14415abba3a750e6

- reviewed (COMMENTED) on -

Independent review: KT1 coalesced output + prefetch (head 4009ec53)

Verdict: the kernel change looks correct and the speed evidence matches its receipts. One CI blocker; several test gaps should be closed before merge.

Blockers

  1. Crumb CI fails on this PR. Both crumb and AIEN Verification report 3 of 157 crumbs stale (src, tests, .). I reproduced it locally with the tool pinned in crumb.lock: the PR head is STALE, while origin/main (b93dfa12) is OK: 157 crumbs current. Fix: run crumb compile with the pinned tool and commit the regenerated src/.crumb, tests/.crumb and ./.crumb. Also rebase: the branch is 8 commits behind main (no overlapping files).

Should-fix

  1. The simulator cannot see the slot-set race the design guards against. tests/bw_warp_sim_k.h:314 always runs warps 0..W-1 in that order within a barrier phase, so warp 0 always reads its slots before any other warp writes the next round. Mutant check: forcing a single slot set (stog = 0 at src/omega_blackwell_codegen_tern.c:382) still passes 34/34. By contrast, dropping the round barrier (:480) is caught. The two-slot design is correct on paper: writes to set S in round i+2 come after barrier i+1, and warp 0 only reaches that barrier after round i's LDS→STG. But nothing tests it. Suggest a reverse-warp-order phase (an order for warps, not only fragments) so the single-slot mutant goes red.
  2. The partial last round with more than one K iteration is not covered. Mutant check: removing the unit clamp (ueff = u at src/omega_blackwell_codegen_tern.c:400) still passes 34/34. Every coalesced sim point that has warps past U also has KSC/D == 1, so only the clamped prefetch is ever used and later iterations never load. Add a point such as { 1024, 40, 0, 4, 4, 1, 2 } (U=5, stride 8, 4 K iterations). The unclamped prefetch is caught (mutant at :338 gives a sim memory error), so the prefetch bound itself is tested.
  3. The test target is not in CI. No workflow runs test-gpu-tern, even though this PR changes the shared encoder (src/omega_blackwell_codegen.c:383) and adds the coalesced path. Its host and sim runs take seconds; please wire it into a host-suites job (the numeric2/gpuengine selectors already match src/omega_blackwell_codegen*).
  4. The clock claim's primary data is not in the evidence. evidence/.../README.md:21 (and investigation/plan.md:39) cite clockcam-1-cam.csv, which is not committed; investigation/clockcam-1.json has no clock figures. Either commit the CSV or mark the 2560 MHz figure as not receipted here.

Nits

  1. src/omega_blackwell_codegen.h:30: the comment still reads desc[URd][Ra.64]; make it [Ra.64+imm].
  2. The other simulators still ignore the LDG.E immediate now that the encoder honors it: tests/bw_warp_sim.h:150, tests/bw_warp_sim_pa.h:166, tests/bw_warp_sim_tc.h:177, tests/gpu_attention_test.c:727. Today every non-tern caller passes 0, so this is harmless, but it is a trap for the next kernel. Mirror the bw_warp_sim_k.h:156 change or refuse a nonzero imm there.
  3. src/omega_blackwell_codegen_tern.h:109: OMEGA_TERN_SHARED_MAX copies OMEGA_BW_QMD_MAX_SHARED_BYTES by value. Include omega_blackwell_qmd.h or add a _Static_assert so the two cannot drift.
  4. src/omega_blackwell_codegen_tern.c:493: the XOR toggle relies on x_bytes (a multiple of 512) and slot_bytes (at most 128) having no common bits. That holds today; a one-line comment or assert would keep it true.
  5. Coalescing needs 2RW ≤ 32 (:145), so the block layout at R=4, W=8 keeps per-row stores. That is fine, but worth one line in the README, since the speed table is row-major R=1 only.

Verification done (fresh /tmp clone, no GPU)

  • Shared-memory staging. Read the full round: lane 0 writes STS into slot set S, then BSYNC, then BAR, then warp 0's LDS → STG, then XOR. The CTA-uniform exit (:393) keeps barrier counts equal across warps. Rows ≥ 2RU are never stored. Footprint: x + 2·(8RW) ≤ 16384 is checked in coalesced_out, and the QMD rounds up to 128 within the cap. nvdisasm of k2560/R2/W8 shows 2× BAR.SYNC, a single LDS→STG in the store region, and LOP3 0x3c.
  • LDG.E immediate. The words match the sealed nvdisasm layout in docs/numeric/E1_LDST_GB10.md:24 (w1 = ureg | off24<<8, w2 0x0c1e1900). nvdisasm 13.0 of the PR kernel decodes LDG.E R33, desc[UR4][R34.64+0x40], +0x280, and so on, as intended. Byte identity: every other BW_IR_LDG_E emitter (gemm, qg, tc, dec, moe, moe2, bf16, elementwise, attention, bw_em.h, codegen.c BW_APPEND) leaves imm 0, so their words are unchanged. elementwise, attention, moe-window, fp8, decode-attn, router, bf16-gemv, fp8gemm, gpr-boundary and matmul-api host+sim gave the same results on base and head. test-gpu-attention fails the same way on both, so that failure predates this PR.
  • Prefetch. The clamp to U-1 is correct (n == 0 is refused by the API, so U ≥ 1). The x staging lanes clamp to KWC-1. k=256 (one K iteration) passes in the sim.
  • Tests. make test-gpu-tern: host 56/56, sim 34/34, mutants 1/2/3 caught. Peak 54 / declared 56 at k2560 row-major i32 is reproduced.
  • Evidence. All 20 "after" fractions in the README match receipt-cold-{1..5}.json (minus_floor_of_practical_237_2), and all 12 "before" fractions match the 18185404 receipt-main and repeat2/3 receipts. Gates 180/237.2 = 0.759 and 200/237.2 = 0.843. device.txt pins d58a46a0 with dirty=0, and the second commit only adds files under evidence/. The folder has no checksum manifest; the only hashes are binary sha256s in investigation/*.meta, which point at paths outside the repo and cannot be re-checked.
  • Thresholds and honesty. tests/gpu_tern_test.c and tools/run_gpu_tern_chip.sh are untouched by both commits, so no threshold moved and no stray diagnostic line was committed. The PR body and README state the 2560x2560 FAIL plainly, and the 150-launch gate is framed as a proposal only.
  • Trailers. Both commits carry Co-Authored-By: Claude Fable 5.1. No repo policy conflicts with that.

Reviewed by an independent Claude Opus 5.5 reviewer for the orchestrator.

Code

The head commit is on main: b602e018f8e58c84a0cdeedb14415abba3a750e6.

Provenance

This proposal is imported from GitHub; it is not signed by its author. Its import statement and source record:

github-import 1
aien-dev/omega-mv
490
b602e018f8e58c84a0cdeedb14415abba3a750e6
{"kind":"github-import","owner":"aien-dev","repo":"omega-mv","number":490,"url":"https://github.com/aien-dev/omega-mv/pull/490","export_sha256":"967c79e26a893657b5cdaa45efd442be5dbd2ecfe68e25f9a8c1b5da4d60d452","imported_utc":"2026-11-18T16:38:02Z","metadata":"unavailable","state_derived":true}

Changes

There is no diff: the head commit is already on main.