Repository navigation
feat(wgmma): add 32-value SSA accumulator carrier - #685
Merged
Merged
Conversation
This was referenced Aug 7, 2026
Signed-off-by: Raul Estrada <[email protected]>
uurl
force-pushed
the
feat/605-wgmma-value-op
branch
from
August 7, 2026 09:20
4b9966a to
166b49e
Compare
… ptxas The carrier probe from NVIDIA#679 only ever assembled a single wgmma.mma_async under one fence/commit/wait. The value-form lowering template chains multiple MMAs inside the same asm region, so the feasibility claim needs a chained probe too. Parametrize the carrier harness on mma_count (kernel builder, template, constraints, and assertions) and add a second test that builds the mma_count = 2 shape: two chained wgmma.mma_async instructions under one fence/commit/wait, one descriptor pair per MMA. ptxas must assemble the sm_90a PTX with zero spill bytes while keeping all 32 accumulators live.
Collaborator
|
Gist: Step 2 of the #605 plan: an internal operation that carries all 32 accumulator values as plain values instead of behind a pointer, so later steps can keep them in registers across a WGMMA region. Nothing user-facing routes onto it yet, so merging it is risk-free by construction. I pushed one commit on top:
|
nihalpasham
approved these changes
Aug 8, 2026
nihalpasham
added a commit
to uurl/cuda-rust
that referenced
this pull request
Aug 8, 2026
nihalpasham
added a commit
to uurl/cuda-rust
that referenced
this pull request
Aug 8, 2026
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.
This PR is stacked on #679 and is the second of six planned PRs for #605.
Summary
Add an internal value-form BF16 WGMMA group that carries the 32 per-thread
f32accumulator values explicitly through SSA operands and results.The new
nvvm.wgmma_mma_group_values_m64n64k16_f32_bf16operation:f32accumulator values followed by one or moreu64descriptor pairs;
f32accumulator values;wait_group<0>sequence into oneconvergent inline-PTX region;
ld.f32/st.f32insidethe WGMMA lifetime.
The existing pointer-form deferred group remains unchanged and available as
the fallback path.
Motivation
#679 established that a real BF16
m64n64k16WGMMA can carry all 32per-thread accumulator values through tied inline-asm operands/results and
reach
ptxasforsm_90awithout spills.This PR turns that feasibility result into an internal dialect operation and
production lowering that later transformations can use to keep accumulators
register-resident across WGMMA regions.
Implementation
WgmmaMmaGroupValuesM64N64K16F32Bf16Op.f32accumulator operands;f32results;u64.MirToLlvmConversionimplementation.=foutputs;0..31;lconstraints for descriptors;Validation
The WGMMA backend feasibility test from #679 was also re-run successfully:
git diff --checkis clean.Scope
This PR does not yet:
wait_group<N>values;Those are left to subsequent PRs.