Use AITER DSv4 Indexer top-k kernel#684
Draft
Oseltamivir wants to merge 8 commits intoROCm:feat/deepseek-v4-pr1-skeletonfrom
Draft
Use AITER DSv4 Indexer top-k kernel#684Oseltamivir wants to merge 8 commits intoROCm:feat/deepseek-v4-pr1-skeletonfrom
Oseltamivir wants to merge 8 commits intoROCm:feat/deepseek-v4-pr1-skeletonfrom
Conversation
…nto dsv4-aiter-pr2998-indexer # Conflicts: # atom/model_ops/attentions/deepseek_v4_attn.py # atom/models/deepseek_v4.py
… into dsv4-aiter-pr2998-indexer # Conflicts: # atom/model_ops/attentions/deepseek_v4_attn.py
This reverts commit ac1e4ea.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation
Wire the DeepSeek-V4 CSA Indexer path in ATOM's PR #650 branch to the DSv4 Indexer scorer/top-k implementation from ROCm/aiter#2998 instead of materializing fp8_mqa_logits and running PyTorch topk in ATOM.
This is intended to make ATOM exercise the AITER PR #2998 Indexer implementation in downstream InferenceX DSv4 runs.
Technical Details
aiter.ops.triton.attention.dsv4_indexer.dsv4_indexer_topk.[num_seqs, max_committed, head_dim]view expected by AITER PR #2998.dsv4_indexer_topk(..., offset=0, seq_ids=..., kv_lens=...)so AITER handles batched per-sequence KV lengths and DSv4 causal compressed-entry visibility.[window || compressed]sparse-attention layout.Note: this PR intentionally wires the Indexer half of ROCm/aiter#2998 first. The AITER
sparse_mqa_sinkABI is paged KV + uniform top-k, while PR #650 currently uses ATOM's ragged packed[window || compressed]sparse-attention layout. Routing sparse attention through AITER should be a follow-up ABI/layout change rather than a per-layer repack.Test Plan
python3 -m py_compile atom/models/deepseek_v4.py atom/model_ops/attentions/deepseek_v4_attn.pyTest Result
Local syntax check passes. GPU correctness/performance validation is pending in InferenceX.