Skip to content

[ASM] [HIP] [CI] [MLA] [Bugfix] Fix and optimize the gfx942 MLA decode/prefill kernels - #6277

Merged
zufayu merged 22 commits into
ROCm:mainfrom
jonahbernard:mla-gfx942-fixes
Dec 3, 2026
Merged

zufayu merged 22 commits into
ROCm:mainfrom
jonahbernard:mla-gfx942-fixes

Conversation

@jonahbernard

@jonahbernard jonahbernard commented Oct 8, 2026 •

Copy link
Copy Markdown
Contributor

Replace 20 (out of 26) gfx942 MLA kernels with fixed and optimized builds and add one new kernel (32 heads, qlen 1).

Motivation

The main motivation for this PR is a 4 GiB addressing bug in the gfx942 ASM MLA kernels. They compute the KV byte offset in 32 bits, so when a KV row is more than 4 GiB past the start of the KV tensor (about 3.7 M token slots for bf16 KV, 7.5 M for fp8), the offset wraps. The kernel then silently reads another token's KV and the output is wrong. In SGLang this shows up with unified KV memory, where all layers share one tensor. It also happens with per-layer KV buffers once a layer's pool is larger than 4 GiB and the cache fills past that point. This PR fixes it in 20 of the 26 gfx942 ASM MLA kernels by loading KV through 64-bit global addresses.

Related issues and PRs:

#5826
#6223
#5893
#5765

This PR overlaps with #6223 on 3 kernels. I recommend merging #6223 and then this PR second. Both PRs fix the 4 GB bug, but this PR speeds up the kernels and fixes some other bugs as well:

Kernel Bug / shape Result and speedup (% faster)
#4 mla_a16w16_qh16_m16x4_n16x1_coex0_mask1_ps: bf16, 16 heads, persistent
Bugs fixed 4 GiB KV offset page_id × row_stride computed in 32 bits; pools > 4 GiB read other tokens' KV. Now 64-bit global addresses
Empty work item A work item with no KV jumps to the end of the program, so the workgroup's later work items are never computed
32-bit overflow Output offset wraps from output row 2^18, partial offset from partial row 2^17; kv_start ≥ 2^30
Missing wait 4th prologue KV tile used before its load completed (stale KV under memory pressure)
MFMA hazard Softmax reads MFMA results before the required wait states (nondeterministic results)
Speedup 16 × 1024, q1 +18%
64 × 4096, q1 +20%
128 × 16384, q1 +18%
512 × 4096, q1 +19%
1 × 32768, q1 +27%
16 × 4096, q4 0%
128 × 16384, q4 +8%
16 × 1M, q1 (cold) +23%
#22 mla_dec_stage1_bf16_a16w16_subQ128_mqa128: bf16 decode, 128 rows
Bugs fixed 4 GiB KV offset computed in 32 bits; pools > 4 GiB read other tokens' KV. Now 64-bit global addresses
Missing wait 2 load results used before their wait
MFMA hazard Softmax reads MFMA results before the required wait states (nondeterministic results)
Speedup 16 × 1024 0%
256 × 256 +1%
1 × 65536 +16%
16 × 16384 +8%
64 × 65536 +14%
128 × 16384 +10%
512 × 4096 +5%
1 × 32768 +25%
#23 mla_dec_stage1_bf16_a16w16_subQ16_mqa16: bf16 decode, 16 rows
Bugs fixed 4 GiB KV offset computed in 32 bits, and the page id built with v_mul_u32_u24 (24 bits, wraps even earlier). Now 64-bit global addresses
32-bit overflow Split-data offset at batch × S ≥ 2^17; kv_indptr ≥ 2^30
Speedup 1 × 1024, q1 +6%
16 × 1024, q1 +4%
1 × 65536, q1 +3%
64 × 4096, q1 +1%
128 × 16384, q1 0%
256 × 256, q1 +1%
1 × 32768, q1 +4%
1 × 1M, q1 (cold) +4%

Technical Details

I fixed the 4 GB addressing bug each of these 20 kernels, fix other bugs discovered in each of them while working on the 4 GB fix, and optimized them when optimizations were discovered while fixing the 4 GB bug.

New kernel MLA_A16W16_1TG_4W_32mx1_16nx1_Coex0_Msk1_QH16_Q1 (bf16, 32 heads, qlen 1). The fix for the existing 32mx1 kernel makes it handle 2 causal query tokens per workgroup, which is needed for correct qlen ≥ 2 (spec-decode verify). Plain decode (qlen 1) doesn't need that path, so it gets its own kernel without the multi-token causal handling. That kernel takes 0.79–0.85× the old time. It has the same grid and kernel arguments as the 32mx1 kernel. The new mla_asm.csv row is qSeqLen = 1, and asm_mla.cu now passes qSeqLen = 1 when max_seqlen_q == 1. Every other qlen still goes to the fixed 32mx1 kernel.

Bugs fixed in each original kernel:

Kernel Type Bug fixed
#1 MLA_A16W16_1TG_4W_32mx1_16nx1_Coex0_Msk1_QH16 (+ new _Q1): bf16, 32 heads
Correctness Not causal at qlen ≥ 2, and half the query tokens were never written (the kernel did 1 token per workgroup, but aiter launches ceil(qlen/2) workgroups). Error vs reference: 0.32 at qlen 2, 1.68 at qlen 4. gsm8k, Kimi NGRAM 4: 0.178 → 0.892
Fault S == 1: writes through the split pointer, which is null in that mode → GPU fault
Missing wait Waves 2/3 read Q before it was loaded; the 4th prologue KV tile was used before its load completed
4 GiB 4 GiB KV wrap
32-bit overflow kv_indptr ≥ 2^30; LSE base carry; split buffer num_records wraps at S = 32768
MFMA hazard MFMA → VALU hazard in the softmax
NaN Masked-row NaN for a fully masked split
#2 MLA_A16W16_1TG_4W_64mx1_16nx1_Coex0_Msk1_QH16: bf16, 64 heads
Correctness Not causal (built with the mask off). Error vs reference: 0.038 at qlen 2, 0.055 at qlen 4. gsm8k, DeepSeek-V2.5 NGRAM 4: 0.727 → 0.930
Fault S == 1 null split pointer: faults at qlen 3/4, hangs at qlen 2. aiter picks S = 1 for batch 286–304 and 112 other batch sizes
MFMA hazard 8 MFMA → VALU hazards; heads 32–63 changed from run to run
4 GiB 4 GiB KV wrap
32-bit overflow kv_indptr ≥ 2^30; num_records; split-data offset at S ≥ 32768; LSE base carry
Missing wait One KV load used before its vmcnt wait
NaN Masked-row NaN
#3 mla_a16w16_qh16_m16x4_n16x1_coex0_mask1: bf16, 16 heads
4 GiB 4 GiB KV wrap
32-bit overflow kv_indptr ≥ 2^30; LSE base carry
Missing wait 4th prologue KV tile used before its load completed
MFMA hazard MFMA → VALU hazard in the softmax
NaN Masked-row NaN for a fully masked split
#4 mla_a16w16_qh16_m16x4_n16x1_coex0_mask1_ps: bf16, 16 heads, persistent
Empty work item Empty work item ends the workgroup; its later work items are never computed
4 GiB 4 GiB KV wrap
32-bit overflow Output offset wraps from output row 2^18, partial offset from partial row 2^17; kv_start ≥ 2^30
Missing wait 4th prologue KV tile used before its load completed
MFMA hazard MFMA → VALU hazard in the softmax
#5 mla_a16w16_qh16_m32x4_n16x1_coex0_mask1: bf16, 16 heads, qlen ≥ 5
Unwritten split qlen ≥ 9 with S > 1 leaves some splits unwritten; the reduce merges stale memory. The S = 1, zero-tile path also used an uninitialized register
4 GiB 4 GiB KV wrap
32-bit overflow num_records wraps from row 233,017
Missing wait 4th prologue KV tile used before its load completed
MFMA hazard MFMA → VALU hazard in the softmax
NaN Masked-row NaN
#26 mla_pfl_bf16_a16w16_causal_subQ16_mqa16: bf16 causal prefill, 16 rows
(same as #5) Same code as #5, so the same fixes
#7 mla_a16w8_qh16_m16x4_n16x1_coex0_mask1_ps: bf16 Q, fp8 KV, persistent
4 GiB 4 GiB KV wrap (first wrong row: 7,456,540)
Missing wait fp8 descale loads used before their wait; 24 V-transpose LDS reads used before their lgkmcnt wait (latent on MI300X, but the ISA requires the wait)
MFMA hazard MFMA → VALU hazard in the softmax
Empty work item Empty work item ends the workgroup
32-bit overflow Output offset ≥ 2^18 rows and kv_start ≥ 2^30 (both reachable through aiter); partial offset ≥ 2^17 rows
Correctness Causal mask used an unsigned compare, which breaks rows that see no keys (reachable here only with hand-built work items)
NaN Masked-row NaN
#8 mla_a16w8_qh16_m16x4_n16x1_coex0_mask1_ps_page64_ds32: bf16 Q, fp8 KV + block scales, page 64
4 GiB 4 GiB KV wrap (from page 102,300, about 6.5 M tokens)
Missing wait 24 V-transpose LDS reads used before their lgkmcnt wait
MFMA hazard MFMA → VALU hazard in the softmax
Empty work item Empty work item ends the workgroup
32-bit overflow Output, partial and kv_start offsets
Correctness Unsigned causal compare breaks rows that see no keys; reachable through aiter for this kernel
NaN Masked-row NaN (6 sites)
#9 mla_a8w8_qh128_m32x4_n16x2_msk0_ps: fp8, 128 heads, persistent
4 GiB 4 GiB KV wrap (108 load sites)
Fault kv_end < kv_start (CUDA-graph padding) faulted: the unsigned "no KV" check saw a huge page count
Empty work item Empty work item ends the workgroup
32-bit overflow kv_indptr ≥ 2^30; output offset (rows ≥ 32768 wrote row − 32768); partial offset
Missing wait Prologue KV tile used before its load completed
MFMA hazard MFMA → VALU hazard: 4 of the 11 required wait states missing
#10 mla_a8w8_qh128_m32x4_n16x2_msk1: fp8, 128 heads, causal
Unwritten split Causally empty splits left unwritten
4 GiB 4 GiB KV wrap (108 load sites)
32-bit overflow kv_indptr ≥ 2^30
Missing wait Prologue KV tile used before its load completed
MFMA hazard MFMA → VALU hazard: 4 of the 11 required wait states missing. Stock gave different results from run to run
#11 mla_a8w8_qh16_qseqlen1_gqaratio16: fp8, 16 heads, qlen 1
LDS race Softmax P written into the LDS region of the next KV tile while other waves still read it (stock: 1778 bad words in the race test)
4 GiB 4 GiB KV wrap + 24-bit page id
32-bit overflow 32-bit base pointers
#12 mla_a8w8_qh16_qseqlen1_gqaratio16_ps: fp8, 16 heads, qlen 1, persistent
LDS race Same P / KV-tile LDS race as #11 (stock: 175 bad words)
Empty work item Empty work item ends the workgroup
4 GiB 4 GiB KV wrap + 24-bit page id
32-bit overflow 32-bit base pointers
#13 mla_a8w8_qh16_qseqlen2_gqaratio16: fp8, 16 heads, qlen 2
LDS race Same P / KV-tile LDS race as #11, plus overlapping LDS regions for the two query tokens
Unwritten split A split with no KV tile left unwritten
NaN Output was NaN when the last token was alone in its split
4 GiB 4 GiB KV wrap + 24-bit page id
32-bit overflow 32-bit base pointers
#14 mla_a8w8_qh16_qseqlen2_gqaratio16_ps: fp8, 16 heads, qlen 2, persistent
LDS race Same P / KV-tile and qlen-2 LDS races as #13
Correctness Tail mask applied after the row max, so masked padding could set the max. gsm8k, Kimi NGRAM 2 (fp8 Q via test shim): 0.694 → 0.882
Empty work item Empty work item ends the workgroup
4 GiB 4 GiB KV wrap + 24-bit page id
32-bit overflow 32-bit base pointers
#19 mla_a8w8_qh64_qseqlen4_gqaratio16: fp8, qlen 3–4
LDS race Two V-transpose / KV-tile LDS races: stock gave a different result in 56 of 150 runs
Unwritten split Empty splits left unwritten: causal error 0.173 (fixed: 0.0125, bf16 level). gsm8k, Kimi NGRAM 4 (fp8 Q via test shim): 0.485 → 0.881
Missing wait Prologue KV tile used before its load completed; one KV wait count too loose
4 GiB 4 GiB KV wrap (110 load sites)
#20 mla_a8w8_qh64_qseqlen4_gqaratio16_ps: fp8, qlen 3–4, persistent, paged
Correctness kv_scale missing from the final normalization, so outputs were scaled wrong whenever the KV scale is not 1
LDS race One barrier where three are needed
Missing wait 72 load results used before their wait, plus the prologue KV tile and the descale
MFMA hazard MFMA → VALU hazard: 8 wait states short
Empty work item Empty work item ends the workgroup
4 GiB 4 GiB KV wrap
32-bit overflow 3 base pointers
#22 mla_dec_stage1_bf16_a16w16_subQ128_mqa128: bf16 decode, 128 rows
4 GiB 4 GiB KV wrap
Missing wait 2 load results used before their wait
MFMA hazard MFMA → VALU hazard in the softmax
#23 mla_dec_stage1_bf16_a16w16_subQ16_mqa16: bf16 decode, 16 rows
4 GiB 4 GiB KV wrap + 24-bit page id
32-bit overflow Split-data offset at batch × S ≥ 2^17; kv_indptr ≥ 2^30
#24 mla_dec_stage1_bf16_a16w16_subQ16_mqa16_ps: bf16 decode, 16 rows, persistent
4 GiB 4 GiB KV wrap + 24-bit page id
32-bit overflow Output offset ≥ 2^19 rows (reachable through aiter); partial offset ≥ 2^18; Q offset from row 466,034; kv_start ≥ 2^30
#25 mla_pfl_bf16_a16w16_causal_subQ128_mqa128: bf16 causal prefill, 128 rows
4 GiB 4 GiB KV wrap
32-bit overflow num_records: Q wrapped from row 29,128 and the bf16 output from row 32,768
Missing wait 2 load results used before their wait
MFMA hazard MFMA → VALU hazard in the softmax

Test Plan

Comprehensive testing was done on MI300:

  1. Speed benchmarking
  2. Pre-existing AITER tests and new gfx942 tests (more details below)
  3. 1000s of AI-generated adversarial tests
  4. SGLang gsm8k accuracy tests (with runs that are verified to use each of the 20 kernels)

More details on the new AITER tests:

Extends op_tests/test_mla_ltx.py on gfx942 from #6223's 16 BF16 cases (16/128 heads, qlen 1) to 96 cases (about 11 s in the default CI run) that launch all 21 changed kernels: 8/32/64 heads, qlen 1–8 against a causal reference, fp8 and bf16-Q/fp8-KV, ds32 page-64 KV, and a prefill mode through mla_prefill_fwd, all placing KV rows below, across and above the 4 GiB boundary, plus a split-KV case.

Speed benchmarking:

MI300X:

Kernel Shape Speedup (% faster)
#1 MLA_A16W16_1TG_4W_32mx1_16nx1_Coex0_Msk1_QH16_Q1: bf16, 32 heads, qlen 1
16 × 1024, q1 +23%
64 × 4096, q1 +23%
128 × 16384, q1 +27%
256 × 16384, q1 +27%
512 × 4096, q1 +23%
1 × 32768, q1 +18%
#1 MLA_A16W16_1TG_4W_32mx1_16nx1_Coex0_Msk1_QH16: bf16, 32 heads, qlen ≥ 2 (now causal)
4 × 1024, q2 −6% ¹
16 × 1024, q2 −11% ¹
64 × 4096, q2 −3% ¹
128 × 16384, q2 +6%
512 × 4096, q2 +2%
1 × 32768, q2 +8%
128 × 16384, q3 +11%
16 × 4096, q4 −2% ¹
64 × 4096, q4 −3% ¹
128 × 16384, q4 +6%
#2 MLA_A16W16_1TG_4W_64mx1_16nx1_Coex0_Msk1_QH16: bf16, 64 heads
1 × 1024, q2 0%
16 × 16384, q2 +3%
64 × 4096, q2 +1%
128 × 16384, q2 +5%
256 × 16384, q2 +6%
1 × 65536, q4 +5%
128 × 16384, q4 +6%
16 × 1M, q2 +10%
#3 mla_a16w16_qh16_m16x4_n16x1_coex0_mask1: bf16, 16 heads
16 × 1024, q1 +27%
128 × 16384, q1 +41%
512 × 4096, q1 +37%
1 × 32768, q1 +28%
128 × 16384, q2 +25%
512 × 4096, q2 +23%
128 × 16384, q3 +16%
16 × 4096, q4 +4%
128 × 16384, q4 +6%
16 × 1M, q1 +41%
#4 mla_a16w16_qh16_m16x4_n16x1_coex0_mask1_ps: bf16, 16 heads, persistent
16 × 1024, q1 +18%
64 × 4096, q1 +20%
128 × 16384, q1 +18%
512 × 4096, q1 +19%
1 × 32768, q1 +27%
16 × 4096, q4 0%
128 × 16384, q4 +8%
16 × 1M, q1 +23%
#5 mla_a16w16_qh16_m32x4_n16x1_coex0_mask1: bf16, 16 heads, qlen ≥ 5
16 × 256, q5 +2%
1 × 4096, q5 +4%
16 × 16384, q5 +9%
64 × 4096, q5 +6%
128 × 16384, q5 +12%
512 × 4096, q5 +10%
1 × 32768, q5 +15%
128 × 16384, q17 +10%
1 × 1M, q5 +27%
16 × 1M, q5 +20%
#7 mla_a16w8_qh16_m16x4_n16x1_coex0_mask1_ps: bf16 Q, fp8 KV, persistent
16 × 4096, q1 +22%
64 × 4096, q1 +25%
128 × 16384, q1 +18%
1 × 32768, q1 +32%
64 × 4096, q2 +16%
128 × 16384, q2 +11%
128 × 16384, q3 +6%
16 × 4096, q4 +2%
128 × 16384, q4 +6%
1 × 32768, q4 +10%
#8 mla_a16w8_qh16_m16x4_n16x1_coex0_mask1_ps_page64_ds32: bf16 Q, fp8 KV + block scales, page 64
1 × 256, q1 +25%
64 × 4096, q1 +28%
128 × 16384, q1 +25%
512 × 4096, q1 +25%
1 × 32768, q1 +30%
1 × 4096, q4 +11%
128 × 16384, q4 +14%
16 × 1M, q1 +27%
#9 mla_a8w8_qh128_m32x4_n16x2_msk0_ps: fp8, 128 heads, persistent
1 × 64K, q1 +4%
8 × 128K, q1 +8%
16 × 32K, q1 +5%
64 × 4K, q1 +2%
128 × 1K, q1 0%
32 × 8K, q2 +3%
32 × 8K, q4 +6%
#10 mla_a8w8_qh128_m32x4_n16x2_msk1: fp8, 128 heads, causal
1 × 64K, q1 +9%
8 × 128K, q1 +14%
16 × 32K, q1 +4%
64 × 4K, q1 +1%
128 × 1K, q1 0%
32 × 8K, q2 +1%
32 × 8K, q4 +1%
16 × 1000, q2 0%
#11 mla_a8w8_qh16_qseqlen1_gqaratio16: fp8, 16 heads, qlen 1
1 × 65536 +1%
1 × 32768 +3%
4 × 16384 +2%
16 × 8192 0%
64 × 4096 +3%
128 × 16384 −1% ²
256 × 8192 −1% ²
#12 mla_a8w8_qh16_qseqlen1_gqaratio16_ps: fp8, 16 heads, qlen 1, persistent
1 × 65536 +1%
1 × 32768 +2%
4 × 16384 +3%
16 × 8192 0%
64 × 4096 0%
128 × 16384 0%
256 × 8192 0%
#13 mla_a8w8_qh16_qseqlen2_gqaratio16: fp8, 16 heads, qlen 2
1 × 4096 +2%
1 × 65536 +5%
16 × 16384 +2%
64 × 65536 0%
128 × 16384 +2%
512 × 4096 +1%
1 × 32768 +8%
16 × 1M +11%
#14 mla_a8w8_qh16_qseqlen2_gqaratio16_ps: fp8, 16 heads, qlen 2, persistent
1 × 4096 +3%
1 × 65536 +3%
16 × 16384 +1%
64 × 65536 0%
256 × 4096 0%
512 × 4096 +1%
4 × 1M +5%
16 × 1M 0%
#19 mla_a8w8_qh64_qseqlen4_gqaratio16: fp8, qlen 3–4
1 × 256, q3 0%
256 × 256, q3 0%
1 × 32K, q3 +16%
64 × 64K, q3 +9%
512 × 64K, q3 +6%
1 × 1M, q3 +12%
16 × 1M, q3 +6%
16 × 4096, q4 −1% ²
#20 mla_a8w8_qh64_qseqlen4_gqaratio16_ps: fp8, qlen 3–4, persistent, paged
64 × 4096, q4 +1%
128 × 16384, q3 +3%
512 × 1024, q3 +1%
1 × 65536, q3 0%
1 × 32768, q3 0%
4 × 16384, q4 −1% ²
1 × 32768, q4 −1% ²
#22 mla_dec_stage1_bf16_a16w16_subQ128_mqa128: bf16 decode, 128 rows
16 × 1024 0%
256 × 256 +1%
1 × 65536 +16%
16 × 16384 +8%
64 × 65536 +14%
128 × 16384 +10%
512 × 4096 +5%
1 × 32768 +25%
#23 mla_dec_stage1_bf16_a16w16_subQ16_mqa16: bf16 decode, 16 rows
1 × 1024, q1 +6%
16 × 1024, q1 +4%
1 × 65536, q1 +3%
64 × 4096, q1 +1%
128 × 16384, q1 0%
256 × 256, q1 +1%
1 × 32768, q1 +4%
1 × 1M, q1 +4%
#24 mla_dec_stage1_bf16_a16w16_subQ16_mqa16_ps: bf16 decode, 16 rows, persistent
1 × 1024, q2 +9%
16 × 256, q2 +9%
1 × 65536, q2 +3%
16 × 16384, q2 0%
64 × 4096, q2 0%
128 × 16384, q2 0%
512 × 4096, q2 0%
1 × 1M, q2 +4%
#25 mla_pfl_bf16_a16w16_causal_subQ128_mqa128: bf16 causal prefill, 128 rows
1 × 1024, 1024 (whole prompt) +18%
1 × 4096, 4096 (whole prompt) +19%
1 × 16384, 16384 (whole prompt) +23%
4 × 4096, 4096 (whole prompt) +18%
16 × 1024, 1024 (whole prompt) +6%
1 × 16384, 1024 +19%
64 × 1024, 7 +5%
1 × 1M, 64 +27%
16 × 1M, 64 +20%
#26 mla_pfl_bf16_a16w16_causal_subQ16_mqa16: bf16 causal prefill, 16 rows
1 × 1024, 1024 (whole prompt) +6%
1 × 4096, 4096 (whole prompt) +43%
1 × 16384, 16384 (whole prompt) +52%
1 × 65536, 65536 (whole prompt) +37%
4 × 4096, 512 +15%
16 × 2048, 64 +11%
64 × 1024, 7 +6%
1 × 1M, 64 +28%

¹ The original was not causal and wrote less split data per workgroup (~16 KiB of distinct data vs 128 KiB for the correct causal output). On small shapes with many splits that write dominates.
² The 64-bit KV addressing needed for KV pools over 4 GiB costs ~0.5–1.5 % on these memory-bound shapes.

MI355X:

Kernel Shape Speedup (% faster)
MLA_A16W16_1TG_4W_64mx1_16nx1_Coex0_Msk1_QH16: bf16, 64 heads, qlen ≥ 2
1 × 1024, q2 +2%
1 × 64K, q4 +6%
16 × 16384, q2 +3%
16 × 1M, q2 +11%
64 × 4096, q2 +2%
128 × 16384, q2 +8%
128 × 16384, q4 +9%
256 × 16384, q2 old kernel faults (1 KV split)
mla_a16w16_qh16_m16x4_n16x1_coex0_mask1: bf16, 16 heads, qlen 2–4
128 × 16384, q2 +16%
512 × 4096, q2 +15%
128 × 16384, q3 +15%
16 × 4096, q4 +1%
128 × 16384, q4 +9%
16 × 1M, q2 +19%
mla_a16w16_qh16_m32x4_n16x1_coex0_mask1: bf16, 16 heads, qlen ≥ 5
16 × 256, q5 +2%
1 × 4096, q5 +5%
16 × 16384, q5 +11%
64 × 4096, q5 +11%
128 × 16384, q5 +21%
512 × 4096, q5 +18%
1 × 32K, q5 +16%
128 × 16384, q17 +20%
1 × 1M, q5 +30%
16 × 1M, q5 +25%
mla_a16w8_qh16_m16x4_n16x1_coex0_mask1_ps: bf16 Q, fp8 KV, persistent
16 × 4096, q1 +20%
64 × 4096, q1 +25%
128 × 16384, q1 +26%
1 × 32K, q1 +27%
64 × 4096, q2 +18%
128 × 16384, q2 +22%
128 × 16384, q3 +13%
16 × 4096, q4 +2%
128 × 16384, q4 +12%
1 × 32K, q4 +6%
mla_a8w8_qh128_m32x4_n16x2_msk0: fp8, 128 heads, non-causal (new on gfx950)
1 × 64K, q2 +8%
8 × 128K, q2 +14%
16 × 32K, q2 +5%
64 × 4096, q2 +2%
128 × 1024, q2 +1%
32 × 8192, q2 +2%
32 × 8192, q4 +2%
mla_a8w8_qh128_m32x4_n16x2_msk1: fp8, 128 heads, causal
1 × 64K, q1 +11%
8 × 128K, q1 +15%
16 × 32K, q1 +6%
64 × 4096, q1 +3%
128 × 1024, q1 +1%
32 × 8192, q2 +3%
32 × 8192, q4 +4%
16 × 1000, q2 +1%
mla_a8w8_qh16_qseqlen2_gqaratio16: fp8, 16 heads, qlen 2
1 × 4096, q2 +4%
1 × 64K, q2 +7%
16 × 16384, q2 +1%
64 × 64K, q2 +5%
128 × 16384, q2 +3%
512 × 4096, q2 +2%
1 × 32K, q2 +6%
16 × 1M, q2 +5%
mla_a8w8_qh16_qseqlen2_gqaratio16_ps: fp8, 16 heads, qlen 2, persistent
1 × 4096, q2 +4%
1 × 64K, q2 +4%
16 × 16384, q2 +1%
64 × 64K, q2 +4%
256 × 4096, q2 +1%
512 × 4096, q2 +1%
4 × 1M, q2 +6%
16 × 1M, q2 +3%
mla_dec_stage1_bf16_a16w16_subQ128_mqa128: bf16 decode, 128 rows
16 × 1024, q1 +1%
256 × 256, q1 +1%
1 × 64K, q1 +14%
16 × 16384, q1 +6%
64 × 64K, q1 +18%
128 × 16384, q1 +16%
512 × 4096, q1 +14%
1 × 32K, q1 +10%
mla_dec_stage1_bf16_a16w16_subQ16_mqa16: bf16 decode, 16 rows
1 × 1024, q1 +9%
16 × 1024, q1 +2%
1 × 64K, q1 +2%
64 × 4096, q1 0%
128 × 16384, q1 0%
256 × 256, q1 0%
1 × 32K, q1 +1%
1 × 1M, q1 +4%
mla_pfl_bf16_a16w16_causal_subQ128_mqa128: bf16 causal prefill, 128 rows
1 × 1024, 1024 (whole prompt) +18%
1 × 4096, 4096 (whole prompt) +19%
1 × 16384, 16384 (whole prompt) +25%
4 × 4096, 4096 (whole prompt) +15%
16 × 1024, 1024 (whole prompt) +6%
1 × 16384, 1024 +22%
64 × 1024, 7 +7%
1 × 1M, 64 +30%
16 × 1M, 64 +27%
mla_pfl_bf16_a16w16_causal_subQ16_mqa16: bf16 causal prefill, 16 rows
1 × 1024, 1024 (whole prompt) +8%
1 × 4096, 4096 (whole prompt) +53%
1 × 16384, 16384 (whole prompt) +41%
1 × 64K, 65536 (whole prompt) +34%
4 × 4096, 512 +17%
16 × 2048, 64 +11%
64 × 1024, 7 +7%
1 × 1M, 64 +32%

AITER test results:

1. 4 GiB regression test: op_tests/test_mla_ltx.py (extended)

MI300X:

Preset Mode: kernel Cases Old New
qh16_bf16_q1 nps: #23, ps: #4 8 8 pass (fixed by #6223) 8 pass
qh128_bf16_q1 nps: #22, ps: #4 (folded) 8 8 pass (fixed by #6223) 8 pass
qh16_bf16_q4 nps: #3 4 1 pass, 3 fail 4 pass
qh16_bf16_q8 nps: #5, prefill: #26 8 2 pass, 6 fail 8 pass
qh128_bf16_q8 prefill: #25 4 1 pass, 3 fail 4 pass
qh32_bf16_q1 nps: #1q1 (old: #1) 4 GPU fault 4 pass
qh32_bf16_q2 nps: #1qn 4 GPU fault 4 pass
qh64_bf16_q2 nps: #2 4 GPU fault 4 pass
qh8_bf16_q2 ps: #24 4 1 pass, 3 fail 4 pass
qh16_a16w8_q1 ps: #7 4 1 pass, 3 fail 4 pass
qh16_fp8_q1 nps: #11, ps: #12 8 2 pass, 6 fail 8 pass
qh16_fp8_q2 nps: #13, ps: #14 8 2 pass, 6 fail 8 pass
qh16_fp8_q4 nps: #19, ps: #20 8 2 pass, 6 fail 8 pass
qh128_fp8_q1 nps: #10, ps: #9 8 2 pass, 6 fail 8 pass
qh16_ds32_q1/q2/q4 ps: #8 12 3 pass, 9 fail 12 pass
Default run all 96 aborts (GPU fault at qh32_bf16_q1) 96 pass, all 21 kernels launched

MI355X:

Run Old New Notes
ltx_bf16_fp8kv_ps (bf16 Q, fp8 KV, PS) GPU fault on the first case (null address, stock a16w8 mask1_ps) passes that case; then rc 1 new's rc 1 comes from the LSE half: gfx950 has no LSE row for that kernel ("cannot get heuristic kernel", host side). Old never got that far
ltx_bf16_h32_h64_nps (32 heads qlen 1, 64 heads qlen 2) pass pass The reviewer's case. With the gfx942 gate, gfx950 keeps the stock 32-head kernel at qlen 1. Launches 64mx1 at qlen 2
9 runs with rc 1 on both (qh8_fp8_q1_ps, qh16_fp8_q2_ps, qh32_fp8_q{1,2,4}_nps, qh8_fp8_q4_nps, qh8_bf16_q{1,2}_ps, bf16_fp8kv_nps) rc 1 rc 1 All host-side dispatch refusals, the same on both: "cannot get heuristic kernel" (no mla_asm.csv row, mostly the LSE-on half of a run) or "nhead=8 and max_seqlen_q=1 not supported". In qh16_fp8_q2_ps the PR's qseqlen2_ps runs and passes the LSE-off half first

PR kernels launched by ltx: subQ16, subQ128, coex0_mask1, m32x4, 64mx1, qseqlen2, qseqlen2_ps, msk1 and a16w8 mask1_ps (9).

2. CI-equivalent run: the MLA op_tests aiter CI runs on MI300X

MI300X:

test old new kernels from this PR launched (new)
test_mla.py (default) ok 951 s ok 950 s #3 #22 #23 #25 #26
test_mla.py CI extra 1 ok 14 s ok 15 s #23
test_mla.py CI extra 2 ok 12 s ok 13 s —
test_mla.py CI extra 3 ok 19 s ok 20 s #26
test_mla.py CI extra 4 ok 16 s ok 14 s #26
test_mla.py CI extra 5 ok 29 s ok 26 s #26
test_mla.py CI extra 6 ok 14 s ok 14 s #26
test_mla_persistent.py ok 1165 s ok 1183 s #4 #7 #9 #12 #14 #20
test_mla_persistent_round_robin.py ok 6 s ok 7 s —
test_mla_decode_pagesize64.py ok 5 s ok 5 s —
test_mla_prefill_ps.py ok 5 s ok 5 s —
test_mla_reduce.py ok 45 s ok 43 s —
test_flydsl_mla_reduce.py ok 28 s ok 25 s —
test_mla_decode_gate.py ok 7 s ok 6 s —
test_mla_sparse.py ok 607 s ok 605 s #4 #7 #9 #12
test_mla_stage2_merge.py ok 16 s ok 16 s —
test_mla_flydsl.py ok 6 s ok 6 s —
test_mla_ltx.py ok 7 s (16 cases) ok 9 s (96 cases) all 21
test_mla_v4_nm.py ok 6 s ok 5 s —
test_mla_v4_kargpreld.py ok 6 s ok 6 s —
test_mla_v40_persistent.py ok 7 s ok 5 s —

MI355X:

test old new PR kernels launched (new)
test_mla.py (default) pass, 666 s pass, 660 s coex0_mask1, subQ128, subQ16, pfl subQ128, pfl subQ16
test_mla.py × 6 CI extra invocations pass pass subQ16, pfl subQ16
test_mla.py gfx950 extra (new in this PR): -c 21 8192 -b 1 4 -n 128,2 128,4 -d fp8 -kvd fp8 --no-causal pass, 9 s pass, 9 s msk0
test_mla_persistent.py pass, 643 s pass, 688 s a16w8 mask1_ps, qseqlen2_ps
test_mla_sparse.py pass, 567 s pass, 568 s a16w8 mask1_ps
test_mla_v4_nm.py pass, 1780 s pass, 1761 s none
10 other MLA op_tests (test_mla_persistent_round_robin, test_mla_decode_pagesize64, test_mla_prefill_ps, test_mla_reduce, test_flydsl_mla_reduce, test_mla_decode_gate, test_mla_stage2_merge, test_mla_flydsl, test_mla_v4_kargpreld, test_mla_v40_persistent) pass pass none

3. Extra runs (not in CI)

These are aiter's op_tests with non-default arguments, to reach the other kernels and KV pools above 4 GiB.

MI300X:

run args old new kernels launched (new) notes
mla_h32_h64 test_mla.py -n 32,1 32,2 32,4 64,1 GPU fault (rc 134) rc 1, 392 s #1q1 #1qn Old #1 faults ("Write access to a read-only page") at 32 heads, qlen 1. New passes every 32-head case and fails only at 64,1: "cannot get heuristic kernel", because aiter has no 64-head qlen-1 kernel on gfx942 (the same on old)
mla_fp8 test_mla.py -d fp8 -kvd fp8 fail (rc 1, 82 s) ok 343 s #10 #11 #13 #19 Old #13 fails the cos check at 16 heads, qlen 2 (71.9% / 71.0% of elements wrong)
mla_bf16_fp8kv test_mla.py -d bf16 -kvd fp8 ok 19 s ok 20 s —
mla_4g_bf16_h16 test_mla.py -c 65536 -b 64 --sequential-page-indices (KV > 4 GiB) ok * 15 s ok 15 s #3 #23 * Old is 2.8% wrong (29,252 of 1,048,576 and 58,974 of 2,097,152 elements) but passes the loose cos check. New is 0% wrong
mla_4g_bf16_h128 same, 128 heads ok 13 s ok 14 s #22
mla_4g_bf16_h32_h64 same, 32 and 64 heads rc 1 rc 1 #1q1 #1qn Only the 64,1 no-kernel gap, on both
mla_4g_fp8 same, fp8 ok 15 s ok 18 s #10 #11 #13 #19
pers_nps test_mla_persistent.py -nps rc 1 rc 1 #4 #7 #9 #12 #14 #20 The same cos_diff < 3e-2 assertion fails on old and new
pers_h8 test_mla_persistent.py -n 8,1 8,2 8,4 abort (rc 134) abort (rc 134) — Host side: aiter's metadata only supports heads in {16, 64, 128} (the same on both)
pers_ds32 test_mla_persistent.py -pl DS32_OPUS -blk 64 rc 1 rc 1 — The test asserts "mla_decode_fwd_ds32 is only supported on gfx950"
pers_3buffer test_mla_persistent.py -pl 3BUFFER -blk 64 rc 1 rc 1 #8 The same cos_diff < 3e-2 assertion fails on old and new
pers_varlen test_mla_persistent.py --varlen ok 161 s ok 162 s #4 #7 #9 #12 #14 #20

MI355X:

run args old new notes
mla_h32_h64 test_mla.py -n 32,1 32,2 32,4 64,1 rc 1 rc 1 Same on both; no PR kernel launched
mla_fp8 test_mla.py -d fp8 -kvd fp8 rc 1 rc 1 Both fail in stock qh64_qseqlen4_gqaratio16 at fp8 qlen 4 (~82 % of elements wrong). Not a PR file. The PR's qseqlen2 passes before that
mla_bf16_fp8kv test_mla.py -d bf16 -kvd fp8 pass pass
mla_4g_bf16_h16 -c 65536 -b 64 --sequential-page-indices (KV > 4 GiB) pass * pass * Old is 2.8 % wrong in subQ16 (qlen 1) and coex0_mask1 (qlen 2, 4) but passes the loose cos check. New is 0 %
mla_4g_bf16_h128 same, 128 heads pass pass subQ128, 0 % on both
mla_4g_bf16_h32_h64 same, 32/64 heads pass * pass * * Both 2.8 % wrong in stock MLA_A16W16_1TG_4W_16mx4_32nx1 (32 heads, not a PR file, no sp3 source)
mla_4g_fp8 same, fp8 rc 1 rc 1 Both fail in stock qh64_qseqlen4 (82.8 %). Old is also 3.0 % wrong in qseqlen2; new 0 %
pers_nps test_mla_persistent.py -nps GPU fault GPU fault Both fault at 48 heads in stock qh64_qseqlen1_gqaratio64_v3_ps (not a PR file). Reproduced alone on both
pers_h8 test_mla_persistent.py -n 8,1 8,2 8,4 rc 1 rc 1 Host-side limit, same on both
pers_ds32 -pl DS32_OPUS -blk 64 rc 1 rc 1 Same on both
pers_3buffer -pl 3BUFFER -blk 64 rc 1 rc 1 Same on both
pers_varlen test_mla_persistent.py --varlen pass pass a16w8 mask1_ps, qseqlen2_ps

1000s of AI-generated adversarial tests

Every kernel was checked against an fp32/fp64 PyTorch reference and, below 4 GiB, bit-for-bit against the old build with only the wait and race fixes, in a per-kernel suite of several hundred to ~1,800 cases (shapes, qlen, split counts, page sizes, empty and padded work items, inf/NaN/denormal inputs, NaN guard bands around every output), on real KV pools above 4 GiB (up to ~110 GB) with rows placed exactly at the wrap points, through static checks for unwaited loads and MFMA hazards, and with a branch-coverage build that reached every edge; every kernel also passed a 1-hour soak (0.2–2.2 M launches on CU-masked streams with injected stalls and memory-aggressor kernels running alongside, 0 failures), and most also got barrier-stall sweeps and negative-control builds with a fix removed.

SGLang gsm8k accuracy results:

MI300X:

Kernel Model / config gsm8k accuracy (old vs. new)
#1 MLA_A16W16_1TG_4W_32mx1_16nx1_Coex0_Msk1_QH16: bf16, 32 heads, qlen ≥ 2
Kimi-Linear-48B-A3B TP1, NGRAM 4 draft tokens 0.178 vs. 0.892
#1 MLA_A16W16_1TG_4W_32mx1_16nx1_Coex0_Msk1_QH16_Q1 (new): bf16, 32 heads, qlen 1
Kimi-Linear-48B-A3B TP1, no speculative decoding (old = …_QH16, the only 32-head kernel before this PR) 0.889 vs. 0.901
#2 MLA_A16W16_1TG_4W_64mx1_16nx1_Coex0_Msk1_QH16: bf16, 64 heads
DeepSeek-V2.5-1210 TP2, NGRAM 4 draft tokens 0.727 vs. 0.930
#3 mla_a16w16_qh16_m16x4_n16x1_coex0_mask1: bf16, 16 heads
Kimi-Linear-48B-A3B TP2, NGRAM 4 draft tokens 0.886 vs. 0.882
#4 mla_a16w16_qh16_m16x4_n16x1_coex0_mask1_ps: bf16, 16 heads, persistent
Kimi-Linear-48B-A3B TP1, persistent decode 0.897 vs. 0.899
#5 mla_a16w16_qh16_m32x4_n16x1_coex0_mask1: bf16, 16 heads, qlen ≥ 5
Kimi-Linear-48B-A3B TP2, NGRAM 8 draft tokens 0.876 vs. 0.877
#7 mla_a16w8_qh16_m16x4_n16x1_coex0_mask1_ps: bf16 Q, fp8 KV, persistent
Kimi-Linear-48B-A3B TP1, fp8 KV cache, persistent decode 0.895 vs. 0.894
#8 mla_a16w8_qh16_m16x4_n16x1_coex0_mask1_ps_page64_ds32
Not run: sglang never dispatches this kernel on gfx942 —
#9 mla_a8w8_qh128_m32x4_n16x2_msk0_ps: fp8, 128 heads, persistent
DeepSeek-V2.5-1210 TP4, attention DP 4, fp8 KV, fp8 Q †, persistent decode 0.925 vs. 0.920
#10 mla_a8w8_qh128_m32x4_n16x2_msk1: fp8, 128 heads, causal
DeepSeek-V2.5-1210 TP4, attention DP 4, fp8 KV, fp8 Q †, non-persistent decode 0.914 vs. 0.923
#11 mla_a8w8_qh16_qseqlen1_gqaratio16: fp8, 16 heads, qlen 1
Kimi-Linear-48B-A3B TP2, fp8 KV, fp8 Q †, non-persistent decode 0.892 vs. 0.901
#12 mla_a8w8_qh16_qseqlen1_gqaratio16_ps: fp8, 16 heads, qlen 1, persistent
Kimi-Linear-48B-A3B TP2, fp8 KV, fp8 Q †, persistent decode 0.889 vs. 0.898
#13 mla_a8w8_qh16_qseqlen2_gqaratio16: fp8, 16 heads, qlen 2
Kimi-Linear-48B-A3B TP2, fp8 KV, fp8 Q †, NGRAM 2, CUDA graphs disabled 0.892 vs. 0.896
same, CUDA graphs + sglang slot-0 fix ‡ 0.873 vs. 0.898
same, CUDA graphs, no sglang fix (fails on old and new alike: sglang bug ‡) 0.002 vs. 0.003
#14 mla_a8w8_qh16_qseqlen2_gqaratio16_ps: fp8, 16 heads, qlen 2, persistent
Kimi-Linear-48B-A3B TP2, fp8 KV, fp8 Q †, NGRAM 2, persistent decode 0.694 vs. 0.882
#19 mla_a8w8_qh64_qseqlen4_gqaratio16: fp8, qlen 3–4
Kimi-Linear-48B-A3B TP2, fp8 KV, fp8 Q †, NGRAM 4 0.485 vs. 0.881
same + sglang slot-0 fix ‡ 0.889 vs. 0.892
#20 mla_a8w8_qh64_qseqlen4_gqaratio16_ps: fp8, qlen 3–4, persistent, paged
Kimi-Linear-48B-A3B TP2, fp8 KV, fp8 Q †, NGRAM 4, persistent decode 0.877 vs. 0.875
#22 mla_dec_stage1_bf16_a16w16_subQ128_mqa128 + #25 mla_pfl_bf16_a16w16_causal_subQ128_mqa128: bf16, 128 heads, decode + causal prefill
DeepSeek-V2.5-1210 TP4, attention DP 4, prefix prefill forced onto MLA § (both kernels in one run) 0.901 vs. 0.924
#23 mla_dec_stage1_bf16_a16w16_subQ16_mqa16 + #26 mla_pfl_bf16_a16w16_causal_subQ16_mqa16: bf16, 16 heads, decode + causal prefill
Kimi-Linear-48B-A3B TP2, prefix prefill forced onto MLA § (both kernels in one run) 0.892 vs. 0.895
#24 mla_dec_stage1_bf16_a16w16_subQ16_mqa16_ps: bf16, 16 rows, persistent
Kimi-Linear-48B-A3B TP4 (8 heads per GPU, run natively ¶), NGRAM 2, persistent decode 0.875 vs. 0.873

† On gfx942 sglang always passes bf16 Q to mla_decode_fwd, so the a8w8 kernels are never launched in stock serving. A test-only shim quantized Q to per-tensor fp8 before the call, as sglang's DCP-ASM path does.
‡ This is an sglang bug, not a kernel bug: with CUDA graphs, padded Kimi KDA verify rows are allocated with new_empty, which puts NaN K/V in KV slot 0. The "slot-0 fix" zero-fills those rows. It is a local workaround and was not submitted to sglang.
§ Stock sglang sends non-speculative extend batches of MLA models to MHA, so mla_prefill_fwd is never called. A test-only shim routed extend batches with a cached prefix to MLA. These rows show the kernels compute correct attention on real traffic; they are not a stock sglang configuration.
¶ By default sglang pads 8 heads to 16 and turns persistent mode off. A test-only shim kept 8 heads and persistent mode, so that this kernel is launched.

MI355X:

Kernel Model / config old vs. new
#23 mla_dec_stage1_bf16_a16w16_subQ16_mqa16: bf16, 16 heads, qlen 1
Kimi-Linear-48B-A3B TP2, non-PS decode 0.895 vs. 0.901
#23 + #26 mla_pfl_bf16_a16w16_causal_subQ16_mqa16: decode + causal prefill
Kimi-Linear-48B-A3B TP2, prefix prefill forced onto MLA § 0.893 vs. 0.895
#3 mla_a16w16_qh16_m16x4_n16x1_coex0_mask1: bf16, 16 heads, qlen 2–4
Kimi-Linear-48B-A3B TP2, NGRAM 4 draft tokens 0.894 vs. 0.886
#5 mla_a16w16_qh16_m32x4_n16x1_coex0_mask1: bf16, 16 heads, qlen ≥ 5
Kimi-Linear-48B-A3B TP2, NGRAM 8 draft tokens 0.870 vs. 0.868
#7 mla_a16w8_qh16_m16x4_n16x1_coex0_mask1_ps: bf16 Q, fp8 KV, PS
Kimi-Linear-48B-A3B TP2, fp8 KV cache, persistent decode 0.892 vs. 0.892
#13 mla_a8w8_qh16_qseqlen2_gqaratio16: fp8, 16 heads, qlen 2
Kimi-Linear-48B-A3B TP2, fp8 KV, fp8 Q †, NGRAM 2, non-PS, CUDA graphs 0.030 vs. 0.872
#14 mla_a8w8_qh16_qseqlen2_gqaratio16_ps: fp8, 16 heads, qlen 2, PS
Kimi-Linear-48B-A3B TP2, fp8 KV, fp8 Q †, NGRAM 2, persistent decode 0.870 vs. 0.898
#22 mla_dec_stage1_bf16_a16w16_subQ128_mqa128 + #25 mla_pfl_bf16_a16w16_causal_subQ128_mqa128: 128 heads, decode + causal prefill
DeepSeek-V2.5-1210 TP4, attention DP 4, prefix prefill forced onto MLA § 0.927 vs. 0.926
#10 mla_a8w8_qh128_m32x4_n16x2_msk1: fp8, 128 heads, causal
DeepSeek-V2.5-1210 TP4, attention DP 4, fp8 KV, fp8 Q †, non-PS decode 0.918 vs. 0.929
#2 MLA_A16W16_1TG_4W_64mx1_16nx1_Coex0_Msk1_QH16: bf16, 64 heads
DeepSeek-V2.5-1210 TP2 (64 heads/rank), NGRAM 4 draft tokens 0.770 vs. 0.923

Not run in sglang:

  • msk0: no sglang config here asks for non-causal decode. It is covered by the new gfx950 CI line and the A/B.

Not run in sglang:

  • msk0: no sglang config here asks for non-causal decode. It is covered by the new gfx950 CI line and the A/B.

Note: I additionally fixed the bug mentioned in #6731. The bug was a race condition in mla_reduce_v1. I added a barrier.

No measurable cost. Every shape is within the ±1–2% run-to-run noise, except one shape that is 2.5% faster with the barrier. The geomean over 15 shapes is +0.2% warm / +0.6% cold on GPU 4, and −0.3% / −0.1% on GPU 5.

Shape Splits per tile Rows per block Massive path GPU 4 warm / cold GPU 5 warm / cold
32 × 2048, H32, q4 (issue #6731's shape) 5 4 yes +0.1% / +0.1% −0.1% / −0.1%
64 × 8192, H16, q4 5–6 4 yes +0.7% / +0.2% −1.0% / 0.0%
16 × 16384, H16, q2 19–20 2 yes −0.2% / +1.0% +0.4% / −0.4%
32 × 2048, H16, q1 8 1 yes +0.9% / 0.0% −2.3% / −0.8%
64 × 16384, H16, q1 5–6 1 yes +2.5% / −1.1% +0.1% / −0.3%
1 × 65536, H16, q1 293 1 yes +2.5% / +2.4% +2.5% / +2.5%
32 × 8192, H32, q1 5–6 1 yes 0.0% / +1.0% −2.2% / 0.0%
16 × 32768, H64, q1 5–6 1 yes −0.8% / +1.3% −0.4% / −0.3%
8 × 65536, H128, q1 5–6 1 yes −2.3% / +1.8% −0.8% / −0.3%
1 × 131072, H128, q1 38 1 yes −0.7% / −0.7% −0.7% / −1.5%
128 × 4096, H16, q1 3 1 no +0.7% / +0.7% −0.2% / 0.0%
256 × 2048, H16, q1 2 1 no −1.6% / +0.8% +0.4% / −0.4%
128 × 4096, H16, q2 3 2 no +0.7% / +0.4% +1.0% / −0.2%
64 × 4096, H128, q1 2 1 no 0.0% / +0.2% −0.3% / 0.0%
32 × 8192, H128, q2 2–3 2 no +0.4% / +1.1% −0.7% / −0.1%

Added a test_mla_reduce.py case (16 heads, dv 512, 32 tiles × 64 splits × 32 rows) that fails on every run on MI300X without the new mla_reduce_v1 row-loop barrier and passes with it.

Another note:

Non-persistent bf16 128-head causal decode with qlen > 1 always ran the unmasked decode kernel, so queries attended to future tokens; the fix sends that case to the masked build of the same kernel (mla_pfl_..._causal_subQ128_mqa128) and makes stage 2 merge only the splits each query actually wrote.

The default test_mla.py run already covers this bug through its 128-head qlen 2 causal case, but checkAllclose only logs failed! without raising, so CI passes even when that case fails.

PR Self-Review

Reviewed revision

2cd4f38

Behavior and intent

Answered above.

Validation and unverified scope

Answered above.

PR-specific question

This PR's only CI change is four added lines in .github/scripts/aiter_test.sh, inside the existing standard job's Tests step (aiter-test.yaml). It adds no new workflow, trigger, or permissions grant.

  • Trigger: the workflow runs on plain pull_request (not pull_request_target), so fork PR code always runs with a read-only GITHUB_TOKEN and no access to repo secrets — standard GitHub fork-PR isolation, unchanged by this PR.
  • Scope: the job that runs this script (standard) declares no elevated permissions: block; the only secret used anywhere in this workflow (GITHUB_TOKEN in check-signal) is in an unrelated, pre-existing job this PR doesn't touch.
  • Input: the new code detects the GPU architecture via aiter.jit.utils.chip_info.get_gfx() (hardware introspection, not attacker-controlled) and, only on gfx950, appends one hardcoded test_mla.py invocation (-c 21 8192 -b 1 4 -n 128,2 128,4 -d fp8 -kvd fp8 --no-causal) to the existing extra-test loop, same timeout 10m guard as every other entry in that loop. No PR title, body, branch name, label, or other PR-supplied text feeds into this logic.

Changed op tests

op_tests/test_mla_ltx.py — Compares torch golden vs. mla_decode_fwd specifically at large page IDs, large KV byte offsets, and >4 GiB KV pools (gfx942/gfx950 asm kernels) — i.e. it's the direct regression test for the 4 GiB KV-addressing bug this PR fixes. On main it only covered 2 presets (qh16_bf16_q1, qh128_bf16_q1), exercising 2 of the 26 gfx942 MLA kernels. This PR extends GFX942_PRESETS to 17 presets across non-persistent/persistent/prefill modes, with each preset's comment naming the exact .co kernel it targets — collectively covering every one of the 20 kernels this PR rebuilds, at the boundary condition the bug only manifests at. It's not redundant with any other op_test because no other existing test constructs a >4 GiB KV pool or large-byte-offset page layout for these kernels; ordinary op_tests use small KV pools that never cross the 32-bit offset wrap, so they structurally cannot catch this bug class.

op_tests/test_mla_reduce.py — Adds one new case to multi_row_cases[512]: (16, "32x64", 32, True) — 32 tiles, 64 splits each, 32 output rows, with the vectorized reference enabled (which requires uniform splits, satisfied here since all 32 tiles share split-count 64). This is the regression test for issue #6731: a missing __syncthreads() between per-row output passes in mla_reduce_v1_impl_massive, where warp 0 could start rewriting p_lds_lse_scale while warp 1 was still reading the previous row's value — intermittent, data-race-dependent corruption. It's not redundant with the existing 128:/512: cases because the race only manifests at this specific combination of many tiles × many splits × many rows; every existing case uses smaller tile/split/row counts that don't hit the warp-timing window where the race is observable.

Submission Checklist

@jonahbernard
jonahbernard requested a review from a team October 8, 2026 17:49
@github-actions github-actions Bot changed the title [ASM] [MLA] Fix and optimize the gfx942 MLA decode/prefill kernels [ASM] [HIP] [MLA] Fix and optimize the gfx942 MLA decode/prefill kernels Oct 8, 2026
@github-actions

github-actions Bot commented Oct 8, 2026

Copy link
Copy Markdown
Contributor

🏷️ CI Guide

Runs automatically on every PR:

  • ✅ Pre-checks (submodule verification, code formatting)
  • ✅ Aiter op tests (gfx942 + gfx950)
  • ✅ Triton tests on MI35X (only when aiter/ops/triton/** or related paths are changed)

Extended tests (opt-in via labels):

Label Tests
ci:gfx1250-ffm-triton Run the five-shard gfx1250 FFM Triton test suite
ci:triton-300x Run an additional Triton test job on MI300X in PRs (added automatically when gfx942 configs change); main branch always runs both MI35X and MI300X
ci:triton-355 Run the full Triton test suite on MI35X, not only the tests the change affects
ci:multi-gpu Aiter multi-GPU tests on the 8-GPU runner
ci:sglang SGLang integration tests: DeepSeek-R1-MXFP4 accuracy, Qwen 3.5 accuracy
ci:atom ATOM benchmark: DeepSeek-R1-0528, GPT-OSS-120B
ci:atom_full ATOM accuracy suite for PR and main models from ATOM models_accuracy.json
ci:vllm vLLM benchmark: GPT-OSS-120B, DeepSeek-R1-0528, Kimi-K2.5
ci:all All standard extended tests (excludes ci:atom_full)

Only add ci:atom_full for FlyDSL or Triton upgrades.
Add labels via the sidebar or gh pr edit 6277 --add-label <label>

One backend per PR:
A PR changes one kernel backend: [Triton/Gluon] (Triton and Gluon count as one), [HIP], [ASM], [CK], [OPUS] or [FlyDSL]. If the title ends up with two backend tags, split the PR -- as stacked pull requests when one part cannot merge without the other.

PR title tags & labels:
Component tags ([Triton/Gluon], [HIP], [CK], [ASM], ...) are added to the PR title and as PR labels automatically from the changed files and re-synced on every push — change-type tags like [fix]/[Perf], op tags like [MLA], and human labels (ci:*) are left untouched. Add the no-auto-title label to stop the title rewrites; labels stay in sync either way.

@jonahbernard jonahbernard changed the title [ASM] [HIP] [MLA] Fix and optimize the gfx942 MLA decode/prefill kernels [ASM] [HIP] [MLA] [Bugfix] Fix and optimize the gfx942 MLA decode/prefill kernels Oct 8, 2026
@valarLip
valarLip requested a review from fangche123 October 9, 2026 01:09
@zufayu
zufayu requested a review from amd-ruitang3 October 9, 2026 01:55
@zufayu
zufayu requested review from shengnxu and removed request for amd-ruitang3 October 9, 2026 05:51
@zufayu zufayu assigned shengnxu and unassigned amd-ruitang3 Oct 9, 2026

@jamesETsmith jamesETsmith left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Huge thanks for this @jonahbernard! Two nits:

  • First, I think we should add some tests to AITER to ensure that we don't regress here and run into this wrapping bug again in the future if the kernels change.
  • Second, about the description itself, in the speedup section you refer to the new/old times as the speedup. Maybe it's me, but I usually think of speedup as old/new (i.e. we want the number > 1.0). I think it might be easier on reviews if you showed the % faster (old/new - 1.0)

@jonahbernard

Copy link
Copy Markdown
Contributor Author

Huge thanks for this @jonahbernard! Two nits:

  • First, I think we should add some tests to AITER to ensure that we don't regress here and run into this wrapping bug again in the future if the kernels change.
  • Second, about the description itself, in the speedup section you refer to the new/old times as the speedup. Maybe it's me, but I usually think of speedup as old/new (i.e. we want the number > 1.0). I think it might be easier on reviews if you showed the % faster (old/new - 1.0)

Thank you @jamesETsmith for the review. I fixed both of those.

@alexioslyrakis-amd

Copy link
Copy Markdown
Contributor

Huge thanks for this @jonahbernard! Two nits:

  • First, I think we should add some tests to AITER to ensure that we don't regress here and run into this wrapping bug again in the future if the kernels change.
  • Second, about the description itself, in the speedup section you refer to the new/old times as the speedup. Maybe it's me, but I usually think of speedup as old/new (i.e. we want the number > 1.0). I think it might be easier on reviews if you showed the % faster (old/new - 1.0)

Thank you @jamesETsmith for the review. I fixed both of those.

Regarding testing, please check my PR which is now merged in #6223, I've added test cases for this particular issue there.

CC: @jamesETsmith

@jonahbernard

Copy link
Copy Markdown
Contributor Author

Huge thanks for this @jonahbernard! Two nits:

  • First, I think we should add some tests to AITER to ensure that we don't regress here and run into this wrapping bug again in the future if the kernels change.
  • Second, about the description itself, in the speedup section you refer to the new/old times as the speedup. Maybe it's me, but I usually think of speedup as old/new (i.e. we want the number > 1.0). I think it might be easier on reviews if you showed the % faster (old/new - 1.0)

Thank you @jamesETsmith for the review. I fixed both of those.

Regarding testing, please check my PR which is now merged in #6223, I've added test cases for this particular issue there.

CC: @jamesETsmith

yes thank you for those tests. I added more tests to them.

jamesETsmith
jamesETsmith previously approved these changes Oct 12, 2026

@jamesETsmith jamesETsmith left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM, thanks for adding the tests @jonahbernard! I don't have perms to really approve the PR, but marking it as approved by me to show all my requests were addressed.

@zufayu

zufayu commented Oct 14, 2026

Copy link
Copy Markdown
Contributor

@aiter-bot review

@aiter-bot

Copy link
Copy Markdown

ROCm/aiter PR #6277 — [ASM] [HIP] [MLA] [Bugfix] Fix and optimize the gfx942 MLA decode/prefill kernels

Replaces 20 of the 26 gfx942 MLA asm decode/prefill kernels with rebuilt binaries that address KV through 64-bit global addresses (fixing silent wrong-KV reads once a KV pool passes 4 GiB) plus wait/race/overflow/NaN fixes, adds a dedicated qlen-1 kernel for 32-head bf16 decode with its mla_asm.csv row and an asm_mla.cu dispatch tweak that selects it, and grows op_tests/test_mla_ltx.py from 16 to 96 gfx942 cases.

Review (advisory): 🔴 HIGH RISK
Validation (deterministic): NOT RUN — auto-validation disabled (REVIEW_AUTO_VALIDATE=0) and this box has no torch/aiter install to run the target op_tests/test_mla_ltx.py by hand; environment gap, not a PR defect
Perf (advisory): NOT RUN — same environment gap (8 idle gfx942 GPUs but no torch/aiter stack, so the base-vs-head manual form cannot run); the PR's own 197 speedup rows are author-reported

🔴 [verified] csrc/py_itfs_cu/asm_mla.cu:932 picks the new qSeqLen=1 routing for gqa_ratio==32 bf16 non-persistent decode whenever max_seqlen_q==1, with no gfx942 gate, but the qSeqLen=1 row was added only to hsa/gfx942/mla/mla_asm.csv — hsa/gfx950/mla/mla_asm.csv has only the qSeqLen=0 row for that combo and get_heuristic_kernel_mla exact-matches qSeqLen, so on gfx950 every 32-head bf16 non-persistent qlen-1 mla_decode_fwd (DeepSeek TP4; the very path test_mla.py -n 32,1 drives) now dies in the "cannot get heuristic kernel" check where it previously dispatched to MLA_A16W16_1TG_4W_16mx4_32nx1_Coex0_Msk1_QH16.co. Author must gate the new selection on gfx942 (or add a qSeqLen=1 row and kernel for gfx950) and run test_mla.py -n 32,1 on gfx950.
🔴 [verified] The 20 replaced kernels routed by hsa/gfx942/mla/mla_asm.csv are the MLA decode/prefill path SGLang/vLLM/ATOM consume (the PR's own gsm8k table runs SGLang against them, several rows via test-only shims), but the PR carries no ci:* label and .github/workflows/sglang_downstream.yaml runs downstream tests only behind ci:sglang/ci:all, so downstream integration is skipped pre-merge — the exact shape of aiter#3459, where an MLA decode kernel passed aiter CI with Atom skipped and went red after merge. Author must add ci:all (or at least ci:sglang plus ci:vllm) and require it green before merge.
⚠️ [verified] The PR fixes the 4 GiB 32-bit KV-offset wrap in 20 of 26 kernels but leaves 6 hsa/gfx942/mla/mla_asm.csv rows on unreplaced binaries — mla_a8w8_qh64_qseqlen1_gqaratio64_v3_ps (and its lse twin), mla_pfl_qh192_vh128_m32x8_n128x1_causal0/causal1, mla_a16w16_qh8_qseqlen1_gqaratio8_v3, mla_a8w8_qh8_qseqlen1_gqaratio8_v1 — all still reachable through mla_decode_fwd/mla_prefill_fwd (e.g. fp8 64-head persistent decode), and the PR says nothing about whether they share the wrapping pattern; if they do, KV pools past 4 GiB still silently read other tokens' KV through them. Author must state whether those 6 are immune to the 4 GiB wrap and fix them or file a follow-up.
📝 [verified] The 197 speedup rows for the kernels now routed by op_tests/test_mla_ltx.py's presets state only "MI300" — no ROCm version, driver, or clocks — so none of the +18-41% numbers can be re-run as written. Reviewer should ask for the measurement environment behind the speedup tables.
📝 [verified] The PR changes the default dispatch behavior of the MLA op class (20 kernel replacements plus the gqa_ratio==32 qSeqLen selection in csrc/py_itfs_cu/asm_mla.cu), and the de-facto owner of that path by commit count (minmengdie — top committer of asm_mla.cu, aiter/mla.py and hsa/gfx942/mla/) has not reviewed; jamesETsmith's approval is the only sign-off so far. Reviewer should ask minmengdie to approve the dispatch change before merge.

@zufayu

zufayu commented Oct 14, 2026

Copy link
Copy Markdown
Contributor

Where that review came from — I ran the bot on your PR to show what it does. It is not an automatic hook; nothing reviews your PR unless somebody asks.

Any reviewer on the aiter allowlist can ask for one, on any PR including their own. The trigger is a comment containing the words below — shown quoted here, because quoted lines deliberately do not trigger it:

@aiter-bot review

  • Reviews the PR at its current head. Comment again after pushing fixes for a fresh pass; a repeat on the same commit is deduped.
  • One review runs at a time on one box, roughly 20 minutes. If work is ahead of you the bot replies with your place in the queue, and if the runner is down it says so rather than leaving you waiting for a review that will never start.
  • The card is advisory. It never blocks a merge, 🔴 included — it is there to be argued with.

Feedback on the review itself is welcome; it is how the rules get better.

@shengnxu

shengnxu commented Oct 17, 2026 •

Copy link
Copy Markdown
Collaborator

This is big work on fixing 64git addr, btw, i think you can also fix some gfx950 co files at the same time, because some of the memory bound gfx950 mla kernel is sharing the same source asm file, while just re-compiled for gfx950, you can find the recompiled list by names or by searching gfx942 wmma instruction under gfx950 directory, then compile them with gfx950 compiler, any issue please connect with @minmengdie

…refill kernel too

mla_asm_decode_remap only forced ps=0 (and thus the masked-prefill-kernel
selection for causal qlen>1) on gfx942, so gfx950 kept running the plain
persistent decode kernel for this case, which has no per-query causal mask.
Meanwhile mla.py's masked_qh128_bf16 (which drives CAUSAL_PER_QUERY for the
stage-2 reduction) was already set for both gfx942 and gfx950, so stage 2
believed splits past each query's causal horizon were skipped on gfx950 too,
even though stage 1 never skipped them there.

gfx950 already ships and dispatches mla_pfl_bf16_a16w16_causal_subQ128_mqa128.co
(hsa/gfx950/mla/mla_asm.csv) with the 64-bit KV addressing fix from this PR,
so extending the gate just routes to an existing, already-tested kernel.
@jonahbernard

jonahbernard commented Nov 23, 2026 •

Copy link
Copy Markdown
Contributor Author

@jonahbernard Two items block this PR.

  1. CI. The only failure is test_moe_2stage.py on MI300X shard 5. main has the same failure (job), and [CK] [FlyDSL] [fused_moe] Keep CK-capable clamped SiLU on CK and ship its gfx942 instances #8353 is the fix. After [CK] [FlyDSL] [fused_moe] Keep CK-capable clamped SiLU on CK and ship its gfx942 instances #8353 merges, merge main into this branch. A trial merge has no conflicts.

  2. Review. The current head has no approval. Please answer ChuanLi1101's list:

    • Item 1: three decode kernels still wrap past 4 GiB (report). Will you rebuild them in this PR or in a follow-up?
    • Item 2: the gfx950 128-head persistent path with CAUSAL_PER_QUERY.
    • Item 5: the description has no PR Self-Review section.

Item 1: That will be done in a follow-up
Item 2: I just fixed it
Item 5: I just fixed it

Thanks!

fangche123
fangche123 previously approved these changes Nov 24, 2026
@ChuanLi1101

Copy link
Copy Markdown
Contributor

Thanks Jonah.

Item 2 is in. gfx950 now uses the same 128-head bf16 path as
gfx942 (ps=0, masked prefill when causal and qlen > 1), so
stage 1 and CAUSAL_PER_QUERY match.

Item 1 as a follow-up is OK for this PR. It is not a nit:
those three kernels are still used and still wrap past 4 GiB
(wrong KV, no error). Please open a follow-up — rebuild them,
or take xaguilar's patch that errors if the KV view is over
4 GiB.

Item 5: the Self-Review text is there, but aiter-bot still
wants the ### Reviewed revision / Behavior / Validation
headings. Please use that format.

I can approve the host/HIP/test side. Not the .co files.
Merge still needs shengnxu/fangche123. The MoE CI failure
is #8353, not this PR.

@jonahbernard

Copy link
Copy Markdown
Contributor Author

Thanks Jonah.

Item 2 is in. gfx950 now uses the same 128-head bf16 path as gfx942 (ps=0, masked prefill when causal and qlen > 1), so stage 1 and CAUSAL_PER_QUERY match.

Item 1 as a follow-up is OK for this PR. It is not a nit: those three kernels are still used and still wrap past 4 GiB (wrong KV, no error). Please open a follow-up — rebuild them, or take xaguilar's patch that errors if the KV view is over 4 GiB.

Item 5: the Self-Review text is there, but aiter-bot still wants the ### Reviewed revision / Behavior / Validation headings. Please use that format.

I can approve the host/HIP/test side. Not the .co files. Merge still needs shengnxu/fangche123. The MoE CI failure is #8353, not this PR.

Hi @ChuanLi1101 thank you for the comment.

  1. Can you please tell me what exactly you need to see before you approve this PR? (i.e., do you have to see the follow-up PR opened before you approve?)
  2. Is the aiter-bot necessary for merging? My PR description is very detailed.

Thanks!

zufayu
zufayu previously approved these changes Nov 25, 2026
@zufayu

zufayu commented Nov 25, 2026

Copy link
Copy Markdown
Contributor

ci failed

@jonahbernard
jonahbernard dismissed stale reviews from zufayu and fangche123 via 83b95f3 November 25, 2026 15:33
@github-actions github-actions Bot changed the title [ASM] [HIP] [FlyDSL] [MLA] [Bugfix] Fix and optimize the gfx942 MLA decode/prefill kernels [ASM] [HIP] [CI] [MLA] [Bugfix] Fix and optimize the gfx942 MLA decode/prefill kernels Nov 25, 2026
@github-actions github-actions Bot removed the FlyDSL label Nov 25, 2026
…masked prefill kernel too"

This reverts commit 2cd4f38.

Forcing ps=0 for gfx950 128-head bf16 decode breaks every persistent
128-head bf16 decode on gfx950. The gfx950 block at the end of
mla_asm_decode_remap still tests `persistent`, not `ps`, and remaps the
shape to gqa 32 / qSeqLen 4. The lookup then asks for (gqa 32, ps 0,
qSeqLen 4), which hsa/gfx950/mla/mla_asm.csv does not have, so
test_mla_persistent.py, test_mla_persistent_round_robin.py and
test_mla_sparse.py fail on MI35X with "cannot get heuristic kernel!
... gqa:32 ps:0 ... qseqlen:4".

The CAUSAL_PER_QUERY concern does not need this change.
masked_qh128_bf16 only feeds the stage-2 reduction in the
non-persistent branch of mla_decode_fwd. That branch passes
num_kv_splits_indptr, so persistent is false and ps is already 0 on
gfx950: causal qlen > 1 already selects
mla_pfl_bf16_a16w16_causal_subQ128_mqa128 there. Persistent decode
reduces with mla_reduce_v1 and runs the qh32_qseqlen4 *_ps kernels,
which have causal and msk0 variants.
@jhinpan

jhinpan commented Nov 25, 2026

Copy link
Copy Markdown
Contributor

@jonahbernard @ChuanLi1101

I pushed 2fb0a3a. This commit reverts 2cd4f38.

2cd4f38 caused the MI35X failures in runs 45291840508 and 45646607177. These three tests fail:

  • op_tests/test_mla_persistent.py
  • op_tests/test_mla_persistent_round_robin.py
  • op_tests/test_mla_sparse.py

Each test stops with this error:

cannot get heuristic kernel! q_type:bf16 kv_type:bf16 gqa:32 ps:0 ... qseqlen:4

Cause

  1. Before 2cd4f38, only gfx942 set ps = 0 for 128-head bf16 decode. 2cd4f38 also sets ps = 0 on gfx950.
  2. A gfx950 block at the end of mla_asm_decode_remap checks persistent, not ps.
  3. In persistent mode, this block changes the shape to gqa 32 and qSeqLen 4.
  4. The kernel lookup then asks for gqa 32, ps 0, and qSeqLen 4.
  5. hsa/gfx950/mla/mla_asm.csv has no kernel with these values.
  6. As a result, each persistent 128-head bf16 decode on gfx950 fails.

Why Item 2 does not need 2cd4f38

Item 2 asks if stage 1 and stage 2 skip the same KV splits on gfx950.

  • masked_qh128_bf16 controls CAUSAL_PER_QUERY. Only stage 2 (_fwd_kernel_stage2_asm) in non-persistent mode uses it.
  • In non-persistent mode, stage 1 runs with persistent=false. Because of this, ps is already 0 on gfx950.
  • For causal decode with qlen > 1, non-persistent mode selects mla_pfl_bf16_a16w16_causal_subQ128_mqa128. As a result, stage 1 and stage 2 agree on gfx950 without 2cd4f38.
  • The revert does not change this selection.
  • Persistent mode does not use CAUSAL_PER_QUERY. It uses mla_reduce_v1 for the reduction.
  • In persistent mode, stage 1 uses the qh32_qseqlen4 *_ps kernels. These kernels have causal and msk0 variants.
  • Before 2cd4f38, all MI35X accuracy checks for persistent 128-head bf16 decode passed in run 44713271121.

Test results

I ran the tests on MI355X with 128 heads, bf16 Q and KV, and qlen 2. Another job used the same GPU. These runs check only correctness.

Test Before the revert After the revert
test_mla_persistent.py Error above 11 of 11 checks pass
test_mla_sparse.py Error above 4 of 4 checks pass
test_mla_persistent_round_robin.py (LSE and CP round robin) Error above 112 of 112 checks pass
test_mla.py (non-persistent mode) 12 of 12 checks pass 12 of 12 checks pass
mla_decode_asm_query, 24 persistent flag sets 24 return NO_KERNEL 24 return a kernel

The counts include only the checks for 128 heads. The new CI run 45723741241 tests the full files.

get_gfx() returns the last GPU_ARCHS entry. With GPU_ARCHS="gfx950;gfx942"
the gate read gfx942 on a gfx950 GPU and skipped the test; with
"gfx942;gfx950" it would run the gfx950-only kernel on gfx942.
get_gfx_runtime() reads the arch from rocminfo and ignores GPU_ARCHS.
Comment thread .github/scripts/aiter_test.sh Resolved
@jonahbernard

Copy link
Copy Markdown
Contributor Author

@fangche123 @zufayu Can this be merged now? Thanks!

@zufayu
zufayu merged commit c2d0220 into ROCm:main Dec 3, 2026
124 of 130 checks passed
AndreasKaratzas added a commit that referenced this pull request Dec 3, 2026
Take main's rebuilt qseqlen2 .co files from #6277. They already fix both
LDS races, so this branch keeps only the qlen 2 regression check.

Co-authored-by: Claude <[email protected]>
Signed-off-by: Andreas Karatzas <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ASM ci:mi300x Run MI300X standard and OPUS CI on PRs CI HIP

Projects

None yet

Development

Successfully merging this pull request may close these issues.