Skip to content

docs+manifest(rocm): close Still Open landed bullets + add compiled status for executing ops - #119

Merged
gstoner merged 3 commits into
mainfrom
rocm/audit-compiled-status
Jun 25, 2026
Merged

gstoner merged 3 commits into
mainfrom
rocm/audit-compiled-status

Conversation

@gstoner

@gstoner gstoner commented Jun 25, 2026

Copy link
Copy Markdown
Owner

Recovery + the "close the Still Open list" task in one. This is commit
0f95a707, which was pushed to #118 but orphaned#118 merged at the prior
tip (f204ff7f, the op-name dispatch, which IS on main), and this audit-hygiene
commit didn't land (third time a fast background merge captured an earlier tip).
Re-landed cleanly on current main. It also is the "close these landed bullets"
work that was requested.

What

1. ROCM_AUDIT ## Still Open## Landed. That section had become a
changelog — 6 of 7 bullets describe landed, executing, execute-compare-tested,
runtime.launch()-reachable kernels (matmul, flash_attn fwd+bwd, GQA/MQA,
fused epilogue, sliding-window, logit-softcap, linear_attn incl.
lightning/retention). Renamed to ## Landed — compiler-generated execution on gfx1151; added a fresh ## Still Open with only the genuinely-open work
(remaining artifact_only op surface, CDNA hardware-gated, parked KV-tile
pipelining).

2. New compiled manifest status — a rung below hardware_verified:
executes via runtime.launch() as a compiler-generated hsaco + execute-compare
fixture, but no shipped C-ABI runtime_symbol.
Promotes 7 rocm rows
(gqa/mqa/mha/sliding-window → flash_attn kernel; linear_attn/lightning →
linear-attn kernel; fused_epilogue → matmul kernel), each tied to its
*_compiled.py test. rocm_target_map: artifact_only 30→23, +7 compiled,
2 hardware_verified
. No inflation (Decision #25) — compiled
hardware_verified (no C symbol), explicit in the validator + legend.

Verification

Do NOT prune this branch until git grep _COMPILED_STATUS origin/main
confirms the merge landed the content.
This commit has now been orphaned
three times by fast background merges capturing an earlier tip.

🤖 Generated with Claude Code

…nded + new `compiled` status for executing ops

Two reconciliations so the audit reflects ROCm execution reality.

(1) ROCM_AUDIT.md — the `## Still Open` section had become a changelog: 6 of its
7 bullets described landed, executing, execute-compare-tested, runtime.launch()-
reachable kernels. Renamed that heading to `## Landed — compiler-generated
execution on gfx1151` and added a fresh `## Still Open` with only the genuinely-
open work: the remaining artifact_only op surface (norms/activations/positional/
matmul-chains/exotic-attention), CDNA (hardware-gated), and the parked KV-tile
pipelining rung.

(2) backend_manifest — new `compiled` status (a rung below `hardware_verified`):
"executes on hardware via runtime.launch() as a compiler-generated hsaco, with a
checked-in execute_compare_fixture, but NO shipped C-ABI runtime_symbol." This is
the honest status for the ROCm compiled-lane family that previously sat at
`artifact_only` despite executing. The validator requires the fixture (not a
symbol). Promotes 7 rocm rows: gqa_attention / mqa_attention /
multi_head_attention / attn_sliding_window (flash_attn kernel), linear_attn /
lightning_attention (linear-attn kernel), fused_epilogue (matmul kernel) —
each pointed at its *_compiled.py execute-compare test. gpu_target_map renders
+ counts + legends the new rung; the stale "every row is artifact_only/planned"
intro is corrected (NVIDIA sm_120 + ROCm now carry execution rungs).

rocm_target_map: artifact_only 30→23, +7 compiled, 2 hardware_verified.
56 manifest/fixture tests pass; mypy + drift clean.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@gstoner gstoner changed the title docs+manifest(rocm): close the 'Still Open' landed bullets + status for executing ops docs+manifest(rocm): close Still Open landed bullets + add compiled status for executing ops Jun 25, 2026

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: c009e89611

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +859 to +865
"gqa_attention": {
"dtypes": ("fp16", "bf16"),
"notes": "GQA/MQA via the flash_attn WMMA kernel (gqa directive attr; "
"fwd+bwd, grouped K/V; runtime detects from operand shapes). "
"Executes on gfx1151 via runtime.launch() (rocm_flash_attn_"
"compiled); no shipped C-ABI symbol.",
},

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Don’t mark aliases compiled before launch accepts them

For these ROCm flash-attn-family rows, the checked-in runtime path still only accepts tessera.flash_attn (runtime._execute_rocm_compiled_flash_attn, lines 1909-1913), and the GQA/sliding-window fixtures also stamp that op name rather than tessera.gqa_attention, tessera.mqa_attention, etc.; rocm_compiled similarly only accepts matmul/gemm for the fused epilogue. Any caller/audit consumer that tries to launch the manifest op names now marked compiled is rejected before GPU execution, so the target map overstates per-op runtime.launch() support unless the executors are taught those op names or these rows stay artifact-only.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Aliases now actually launch (not just marked compiled) — you were right that the executors rejected the alias op names; rather than revert those rows to artifact_only, I taught the executors the op names (consistent with how lightning/retention were handled in this same PR stack):

counts[r.status] = counts.get(r.status, 0) + 1
for status in ("fused", "compileable", "executable", "artifact_only",
"reference", "planned"):
for status in ("hardware_verified", "compiled", "fused", "compileable",

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Sync the status vocabulary drift gate

Adding compiled to the GPU map means all_rocm_rows('rocm') now yields that status, but the shared-vocabulary drift gate in tests/unit/test_gpu_target_maps.py still allowlists only through hardware_verified; running PYTHONPATH=python pytest -q tests/unit/test_gpu_target_maps.py::test_apple_and_gpu_dashboards_share_status_vocabulary fails with GPU dashboard uses unknown status(es): {'compiled'}. Please update the downstream status consumers/allowlist along with this renderer change so CI stays green.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Status-vocabulary drift gate — added compiled to the shared allowlist in test_gpu_target_maps.py::test_apple_and_gpu_dashboards_share_status_vocabulary (the rung below hardware_verified: runtime.launch() hsaco + numerical fixture, no shipped C symbol). CI stays green.

…ch executors the `compiled` op names

Two review points on the `compiled` promotion:

(1) Drift gate. Adding `compiled` to the GPU target map made
test_gpu_target_maps.py::test_apple_and_gpu_dashboards_share_status_vocabulary
fail ("GPU dashboard uses unknown status(es): {'compiled'}"). Added `compiled`
to the shared-vocabulary allowlist (the rung just below hardware_verified:
runtime.launch() hsaco + numerical fixture, no shipped C symbol).

(2) Don't mark aliases `compiled` before launch accepts them. The flash-attn
executor only accepted tessera.flash_attn and the gemm executor only
matmul/gemm, so the op names newly marked `compiled` (gqa/mqa/mha/sliding-window,
fused_epilogue) would have been rejected before GPU execution — the target map
would overstate runtime.launch() support. Taught the executors those op names
(matching how lightning/retention were handled):
  * _execute_rocm_compiled_flash_attn accepts tessera.{flash_attn,
    multi_head_attention,gqa_attention,mqa_attention,attn_sliding_window};
    GQA/MQA come from operand shapes, window/softcap from kwargs.
    attn_sliding_window additionally REQUIRES a positive `window` (the op name
    implies one) — else a named error.
  * rocm_compiled (gemm) accepts tessera.fused_epilogue (= matmul + the fused
    bias/activation epilogue, same kernel).

Tests: GPU-free op-name acceptance for each alias (a downstream validation
fires, proving the op-name gate is passed, not the "handles exactly one"
rejection) + unknown-op rejection + attn_sliding_window-requires-window + a GPU
oracle launch of the multi_head_attention op name on gfx1151. So every op name
marked `compiled` genuinely launches via runtime.launch().

mypy + ruff + drift + manifest/fixture tests all clean.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@gstoner

gstoner commented Jun 25, 2026

Copy link
Copy Markdown
Owner Author

Both review points addressed in e60702a5:

1. Status-vocabulary drift gate — added compiled to the shared allowlist in test_gpu_target_maps.py::test_apple_and_gpu_dashboards_share_status_vocabulary (the rung below hardware_verified: runtime.launch() hsaco + numerical fixture, no shipped C symbol). CI stays green.

2. Aliases now actually launch (not just marked compiled) — you were right that the executors rejected the alias op names; rather than revert those rows to artifact_only, I taught the executors the op names (consistent with how lightning/retention were handled in this same PR stack):

  • _execute_rocm_compiled_flash_attn accepts tessera.{flash_attn, multi_head_attention, gqa_attention, mqa_attention, attn_sliding_window} — GQA/MQA from operand shapes, window/softcap from kwargs. attn_sliding_window requires a positive window (named error otherwise).
  • rocm_compiled (gemm) accepts tessera.fused_epilogue (= matmul + the fused bias/activation epilogue, same kernel).

Tests added: GPU-free op-name acceptance for each alias (asserts a downstream validation fires, proving the op-name gate is passed — not the "handles exactly one" rejection), unknown-op rejection, attn_sliding_window-requires-window, and a GPU oracle launch of the multi_head_attention op name on gfx1151. So every op name marked compiled genuinely launches via runtime.launch() — the target map no longer overstates.

mypy + ruff + drift + 49 manifest/fixture tests clean.

…_attention `compiled` promotion

CI fail: test_rocm_attention_family_uses_16x16x16 asserted
manifest_for("multi_head_attention")["rocm"].mfma_shape == (16,16,16,1), but
promoting multi_head_attention to `compiled` (WMMA, no MFMA shape — it IS the
flash_attn kernel) made that None.

The test's premise (MHA on the artifact MFMA path) is outdated. Repointed the
MFMA-shape assertion at a still-artifact_only attention op
(deepseek_sparse_attention, which keeps the 16x16x16 CDNA MFMA score-tile), and
added assertions that multi_head_attention is now `compiled` / wmma / no MFMA
shape — documenting the move off the artifact path. No hardcoded artifact_only
counts elsewhere; 166 manifest/coverage/conformance + 179 rocm execution tests
pass.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@gstoner

gstoner commented Jun 25, 2026

Copy link
Copy Markdown
Owner Author

CI fix pushed (40c92189). The failing test_rocm_attention_family_uses_16x16x16 had an outdated premise: it asserted multi_head_attention carries the artifact-path MFMA 16×16×16 shape — but promoting it to compiled (WMMA; it is the flash_attn kernel) correctly drops the MFMA shape.

Fix: repointed the MFMA-shape assertion at a still-artifact_only attention op (deepseek_sparse_attention, which keeps the CDNA MFMA 16×16×16 score-tile), and added assertions that multi_head_attention is now compiled / wmma / no MFMA shape — documenting the move off the artifact path.

Checked there are no hardcoded artifact_only counts elsewhere; 166 manifest/coverage/conformance + 179 rocm execution tests pass locally, mypy + ruff + drift clean.

@gstoner
gstoner merged commit b5d3781 into main Jun 25, 2026
17 checks passed
@gstoner
gstoner deleted the rocm/audit-compiled-status branch June 26, 2026 13:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant