You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
MMA: AtB/AtBt walks, mm entry points, generic KIND routing #12
Shape coverage. ThunderKittens' tcgen05 layer is {mm, mma} x {AB, ABt, AtB, AtBt} x {1-CTA, 2-CTA} — 16 entry points.
We have three: mma_abt, mma_ab (single-CTA), and mma_walk_cg2 (2-CTA, runtime K-major/MN-major via OperandWalk).
Missing:
AtB and AtBt walks. Mostly descriptor transpose-bit work inside the existing walk skeleton — the chunk geometry documented in the mma.rs header already covers both operand orders.
The mm (zero-initializing) variants as distinct entry points. We thread enable_d by hand, which is the same instruction but puts the accumulator-init invariant on the caller. Making mm its own entry point moves that into the type.
Intrinsic routing. We call tcgen05_mma_f16 / tcgen05_mma_f16_cg2, the f16-specialized wrappers. cuda-device also exposes tcgen05_mma_shared / tcgen05_mma_tensor taking a KIND const (0=f16, 1=tf32, 2=f8f6f4, 3=i8). Switching to the generic form and sourcing KIND from Element (#2) is what makes fp8 a new Element impl rather than a new MMA layer.
Worth confirming the generic intrinsic lowers identically for KIND=0 before switching — it should be the same PTX, but that is an assumption to check rather than assert.
Also available upstream and currently unused: tcgen05_mma_sp_* (sparse), tcgen05_mma_ws_* (weight-stationary, per dtype), tcgen05_shift_down. Not proposed here, noted so they are not rediscovered later.
Negative result from the examples work (#18): none of the four example kernels demanded anything in this issue.
Flash-attention forward, GEMM, softmax, and layernorm were each written against the API we would want, then checked for what they could not express. The MMA layer came through clean — mma_abt, mma_ab, and mma_walk_cg2 covered every multiply those kernels needed. What blocked them was the memory path (#21, #22, #25), the compute layer (#5, #6), and cluster scaffolding (#24).
That is evidence this issue can sit lower in the order than its number implies. AtB/AtBt walks and generic KIND routing are real gaps against ThunderKittens, but they are gaps no kernel we have tried to write has hit — unlike, say, #21, which stops a four-line softmax at line one.
Keeping it open, and the FP8 dependency in #16 still points here. Just recording that the priority evidence went the other way.
Activity
feitreim commentedon Jul 27, 2026
Negative result from the examples work (#18): none of the four example kernels demanded anything in this issue.
Flash-attention forward, GEMM, softmax, and layernorm were each written against the API we would want, then checked for what they could not express. The MMA layer came through clean —
mma_abt,mma_ab, andmma_walk_cg2covered every multiply those kernels needed. What blocked them was the memory path (#21, #22, #25), the compute layer (#5, #6), and cluster scaffolding (#24).That is evidence this issue can sit lower in the order than its number implies.
AtB/AtBtwalks and genericKINDrouting are real gaps against ThunderKittens, but they are gaps no kernel we have tried to write has hit — unlike, say, #21, which stops a four-line softmax at line one.Keeping it open, and the FP8 dependency in #16 still points here. Just recording that the priority evidence went the other way.
Examples crate: kernels written against the API we want (#20)
MMA walks build their own instruction descriptor (#34)