Repository navigation
perf(hip): deep-K staging in the m32 n64 verify twin (bit-identical, +10% Ripple DFlash2 decode) - #359
Merged
Conversation
The n64 m32 twin serves Ripple's narrow long-K verify GEMMs (down 5120x40960, o, fc), where 80 CTAs walking K one 32-K step per two barriers sit at ~100 GB/s. Stage KS=4 steps per barrier interval and run their WMMAs in ascending k: same operands, same order, so outputs are bit-identical to m128_f16a. gfx1151 kbench 43410492618 (0 differing outputs): down M17 1151 -> 821 us, o 290 -> 205, fc M16 718 -> 506. n128 keeps KS=1 (wide shapes lose occupancy). Co-Authored-By: Claude Opus 5.5 <[email protected]>
AzeezIsh
added a commit
that referenced
this pull request
Nov 13, 2026
Contributor
Author
|
Post-merge (e851e96), both AMD boxes green:
|
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.
Deep-K staging in the n64 instantiation of the 32-row verify twin from #354 (
w4a16_m32_f16a_body<NT, KS>). It stages KS K-steps of A and B per barrier. n64 now uses KS=4 and n128 keeps KS=1, because wide N got worse at KS4 (gate/up went from 647 to 921 µs). The change is applied to both separate copies ofw4a16_gemm.cu(27B and 35B-A3B); Flash-Next and Nemotron symlink to them.The summation order is unchanged, so the output is bit-identical and ST-995 is not needed.
Evidence (DevLab Strix runner, gfx1151)
kbench (
scripts/devlab/kbench_dn/w4a16_m32_deepk.hipon devlab/engine-study): 0 diffs against KS1 on every shape.Ripple-65B + DFlash2, end to end (C1 mixed, steady all-decoding):
probe-ripple_dflash.jsonis byte-identical to main in both rounds.27B NVFP4, C8, NUM_DRAFTS=3, 2 rounds (43426517156):
27B is neutral.
🤖 Generated with Claude Code