Repository navigation
Revert "[AMD][ROCm] Keep cos_sin_cache fp32 on HIP for fused QSA indexer kernel (#41282)" - #42541
Merged
HaiShaw merged 1 commit intoOct 5, 2026
Conversation
…xer kernel (sgl-project#41282)" This reverts commit f6fcda8.
michaelzhang-ai
requested review from
BBuf,
Edwardf0t1,
Fridge003,
HaiShaw,
Ying1123,
ch-wan,
ispobock and
merrymercy
as code owners
October 5, 2026 01:16
yctseng0211
approved these changes
Oct 5, 2026
Collaborator
Author
|
/rerun-failed-ci |
HaiShaw
approved these changes
Oct 5, 2026
This was referenced Oct 5, 2026
This was referenced Oct 6, 2026
4 of 5 tasks
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
#41282 keeps
RotaryEmbedding.cos_sin_cachefp32 on HIP. On HIP, every rope without a fused KV-cache write goes through thesgl_kernel.rotary_embeddingfallback, which reads the cache as the query dtype, so CUDA graph capture now fails:This fails
stage-a-test-1-gpu-small-amd(test_basic_sanity.py/test_basic_sanity_eagle3.py) on every AMD PR, so all AMD stage B/C lanes are skipped. Examples: run 37180583674, run 37187809051. #41282's own PR Test (AMD) runs stopped at the label gate, so stage-a never ran on it.Reverting unblocks AMD CI now. The forward fix that keeps the fp32 cache for the QSA indexer is #42483; it can re-land on top of this.
Modifications
git revert f6fcda8827:base.pyandmrope.pyare byte-identical to before #41282. Nothing has touched either file since.Effect on the QSA indexer:
_use_fused_prepalready requirescos_sin_cache.dtype == torch.float32, so on HIP it goes back to the unfused prep path it used before #41282. No functional break, only the fused prep on HIP is lost until #42483 lands.Checklist
stage-a-test-1-gpu-small-amdpassesCI States
Latest PR Test (Base): ⏳ Run #37250822113
Latest PR Test (Extra): ❌ Run #37250832996
Latest PR Test (AMD ROCm 10): ❌ Run #37250822085