Skip to content

[AMD] Restore K3 MLA verify kernel path blocked by can_handle() guard - #34261

Merged
HaiShaw merged 2 commits into
sgl-project:mainfrom
1am9trash:k3-mla-verified-kernel-gate
Aug 10, 2026
Merged

HaiShaw merged 2 commits into
sgl-project:mainfrom
1am9trash:k3-mla-verified-kernel-gate

Conversation

@1am9trash

@1am9trash 1am9trash commented Aug 10, 2026 •

Copy link
Copy Markdown
Collaborator

Only impact K3, mi355 code path.

Motivation & Modifications

In PR #33981 we added a triton MLA verify kernel (verify_mla_fwd) to improve Kimi-K3 DSpark perf. It reused verify_splitkv.can_handle() as its eligibility gate.

PR #29677 (merged 2 days ago) added a guard to can_handle() rejecting cases where q_head_dim != v_head_dim. MLA is exactly that case, so can_handle() now returns False for K3 and verify_mla_fwd silently falls back to extend_attention_fwd The new kernel never runs.

This PR stops sharing verify_splitkv.can_handle(): verify_mla now owns its own copy, mirroring the split-KV gate line-for-line except the head-dim check.

Checklist

Review and Merge Process

  1. Ping Merge Oncalls to start the process. See the PR Merge Process.
  2. Get approvals from CODEOWNERS and other reviewers.
  3. Trigger CI tests with comments or contact authorized users to do so.
    • Common commands include /tag-and-rerun-ci, /tag-run-ci-label, /rerun-failed-ci
  4. After green CI and required approvals, ask Merge Oncalls or people with Write permission to merge the PR.

CI States

Latest PR Test (Base): ⏳ Run #31377064163
Latest PR Test (Extra): ❌ Run #31377063972

@1am9trash 1am9trash added amd run-ci CI: run the baseline test suite on this PR labels Aug 10, 2026

@HaiShaw HaiShaw left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

AMD gated.

@HaiShaw
HaiShaw merged commit 0977b22 into sgl-project:main Aug 10, 2026
70 of 99 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

amd jit-kernel run-ci CI: run the baseline test suite on this PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants