Conversation
The bench unset DSV4_QWEN_GQA_MMA_TILE for the base/long/flash modes,
but an unset variable means "enabled" in the dispatcher: mma_enabled is
`mma_tile == nullptr || strcmp(mma_tile, "0") != 0`. MMA is also checked
before flash and long, so all four modes ran the MMA kernel and printed
four identical rows.
Set the variable to "0" for the other modes instead. The four modes now
separate, and the production default is 10.7x faster than the fallbacks
it was silently being compared against:
rows=4096 offset=61440 base 1846.7 ms long 1405.5 ms
flash 1389.1 ms mma 129.5 ms
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.
Bug
The bench unset
DSV4_QWEN_GQA_MMA_TILEfor thebase/long/flashmodes, but in the dispatcher an unset variable means enabled:MMA is also checked before flash and long, so all four modes ran the MMA kernel and the bench printed four identical rows. Any comparison drawn from it was a kernel against itself.
Fix
Set the variable to
"0"for the other modes rather than unsetting it. The modes now separate, and the production default turns out to be 10.7x faster than the fallbacks it was silently being compared against:Test plan
CUDA_VISIBLE_DEVICES=0 build/tests/bench_qwen_gqa_prefill— before the fix all four mode rows were identical to within noise; after it they differ as above. Bench-only change, no engine code touched.