[CK_Tile] Support for group size 128 for Preshuffle quant for 2d block scale gemm#3462
Merged
Conversation
- Split cpp file to reduce building time - Support multiple GemmConfig
- Update Readme
- Add support for rowcol and tensor GEMM operations
- Update README
ThomasNing
requested changes
Dec 19, 2025
Contributor
ThomasNing
left a comment
There was a problem hiding this comment.
Please also add the tests
ThomasNing
requested changes
Jan 7, 2026
| using QuantGroupSize = ck_tile::QuantGroupShape<ck_tile::sequence<1, 64, 128>>; | ||
| return RUN_GEMM_EXAMPLE_PREC_TYPE; | ||
| }; | ||
| lut[hash_multiple_strings( |
Contributor
There was a problem hiding this comment.
Our runtime for the example preshuffle quant is too long could we reduce that? Also, should we add the preshuffle quant case and non-preshuffle quant case for 1x128x128 in example and test?
ThomasNing
reviewed
Jan 9, 2026
| static_assert(BlockGemmShape::kK % AQuantGroupSize::kK == 0); | ||
| static_assert(BlockGemmShape::kM % BQuantGroupSize::kM == 0); | ||
| static_assert(BlockGemmShape::kN % BQuantGroupSize::kN == 0); | ||
| // static_assert(BlockGemmShape::kN % BQuantGroupSize::kN == 0); |
Collaborator
Author
There was a problem hiding this comment.
resolved, uncommented these changes.
ThomasNing
approved these changes
Jan 14, 2026
shumway
pushed a commit
that referenced
this pull request
Jan 15, 2026
…k scale gemm (#3462) * formatted * formatted * formatting * formatting * formatting * [CK TILE GEMM] Refactor block_scale_gemm examples - Split cpp file to reduce building time - Support multiple GemmConfig * [CK TILE GEMM] Refactor block_scale_gemm examples - Update Readme * enable prefill shapes * [CK TILE GEMM] Refactor block_scale_gemm examples - Add support for rowcol and tensor GEMM operations * [CK TILE GEMM] Refactor block_scale_gemm examples - Update README * adding preshuffle quant as new parameter and its associated new files * remove debugging statements * adding test * enable preshuffle quant with permuteN * updating readme and correcponding gemmconfigs * updating cmake file * fixing CI failures for grouped quant gemm * debugging permuteN * debugging * debugging PermuteN * initial commit * resolving merge conflicts * adding test cases * initial commit with prints * debugging * fine-grained working * debugging medium grained * fixing the tile window * formatting * enabling prefill shapes * working prefill shapes * formatted * clean up * code cleanup * bug fix after merging with develop * G128 working for both prefill and decode shapes for preshufflequant * clean up after merging with develop * fixing group 64 for decode shapes * non preshufflequant working for group size 128 * enable preshuffleb and preshufflequant with variour group sizes * reduce build time by splitting example into diff datatype files * Adding tests for preshuffleQuant * address review comment * fix for gfx1201 * compile time fix for gfx1201 * clang formatted --------- Co-authored-by: Cong Ma <congma13@amd.com> Co-authored-by: Thomas Ning <Thomas.Ning@amd.com> Co-authored-by: Agarwal <khuagarw@ctr2-alola-login-03.amd.com>
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.
Proposed changes
Adding support for group size 128 for both prefill and decode shapes of 2d block scale gemm.
For prefill: NIterations needs to share the same value of quant scale.
For decode: blocks need to share the same value of quant scale.
This PR needs to be merged after #3445
Checklist
Please put an
xinto the boxes that apply. You can also fill these out after creating the PR. If you're not sure, please don't hesitate to ask.clang-formaton all changed filesDiscussion
If this is a relatively large or complex change, feel free to start a discussion by explaining why you chose the solution you did and what alternatives you considered