# docs: add layout algebra comment to make_tiled_copy_V_interleave_trans (#44) - #86
Open
XFDG wants to merge 1 commit into
Open
# docs: add layout algebra comment to make_tiled_copy_V_interleave_trans (#44)#86XFDG wants to merge 1 commit into
XFDG wants to merge 1 commit into
Conversation
Tencent#44) Answers the "what are thr_layout / val_layout" question from issue Tencent#44 by documenting the cuTe layout algebra for the FP8 V-tile smem→reg copy: - thr_layout (32,4,1,1):(4,1,0,0): 128 threads as 4 warps striding by 4 along N; each warp owns a (16,8) sub-tile of the 64-wide N. - val_layout (2,2,1,4):(1,2,4,4): 16 values per thread spanning 8 columns at 2 row-positions; the d*4 stride produces the V0/V1 interleave consumed by SM75_U16x8_LDSM_T (LDSM.1matrix). - raked_product / right_inverse mapping: how (M,N) smem coords are routed to (thread_id, value_id) so cute::copy can drive the LDSM fragment. No code changes; no rebuild required. Co-Authored-By: Claude <noreply@anthropic.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.
Summary
make_tiled_copy_V_interleave_trans()insrc/attention/decode/sm90/util_kernels.cuh, answering the "what arethr_layout/val_layout" question from issue [Question] How to Understand the thr_layout and val_layout in make_tiled_copy_V_interleave_trans? #44.thr_layout = (32,4,1,1):(4,1,0,0)— 128 threads as 4 warps striding by 4 along N; each warp owns a (16,8) sub-tile of the 64-wide N.val_layout = (2,2,1,4):(1,2,4,4)— 16 values per thread spanning 8 columns at 2 row-positions; thed*4stride produces the V0/V1 interleave consumed bySM75_U16x8_LDSM_T.raked_product/right_inversemapping — how (M,N) smem coords are routed to(thread_id, value_id)socute::copycan drive the LDSM fragment correctly.val_layoutstrides alone.Testing