Repository navigation
Description
From #40's benchmark table (B200, 148 SMs):
softmax — rows x columns x planes
128x128x2 2 blocks 0.0508 ms 2.6 GB/s
512x128x2 8 0.0507 10.3
4096x128x2 64 0.0514 81.7
32768x128x2 512 0.1171 286.5
262144x128x2 4096 0.7749 346.4
524288x128x2 8192 1.4827 362.1
The floor is flat at ~51 us all the way out to 64 blocks. Adding 32x the work
costs nothing, which means the kernel is not doing any work worth measuring — it
is waiting. And 362 GB/s is far below what HBM3e on a B200 will do, so the
"memory-bound" label #40 was built around is wrong for this kernel as written.
Why
One tile per CTA, single-thread issue, and a blocking wait at both ends: the TMA
load completes before anything starts, and the TMA store completes before the
kernel exits. Nothing is ever in flight. Each CTA pays full memory latency
twice with no other work to hide it, and the flat floor is that latency, not
bandwidth.
This is a property of how the example is written, not of the library — the
pipeline primitives (SharedTileRing, SemaphoreRing) exist and the GEMM uses
them to good effect. Softmax simply does not.
What would fix it
- Multiple tiles per CTA, pipelined through
SharedTileRing, so a load is in
flight while the previous tile is being reduced. - Overlap the store with the next tile's load rather than waiting on it — this
is exactlytma_store_wait_readversustma_store_wait(TMA store path #9 exposed both), and
exactly lcsf and the rest of the prototype layer #15'slcsfmotivation.
Worth doing, and worth doing carefully
The value here is not a faster softmax — it is that this is the first
performance finding this project has produced from measurement rather than from
reading ThunderKittens, and the fix exercises the pipeline layer against a
kernel whose current numbers are known. Whatever lands should be re-measured
against the table above, and #40's harness makes that one command.
Note also that % of peak cannot be reported for GB/s today: the NVIDIA HGX B200
page states flops per GPU but not HBM bandwidth per GPU, so #40 deliberately
prints no ratio rather than an unsourced one. Sourcing a bandwidth figure would
make this issue's target concrete.
Activity
feitreim commentedon Jul 28, 2026
it seems like membw on the B200 is ~7.7GB/s https://arxiv.org/html/2512.02189v1#S5
softmax: the band was never in registers, and that was the 362 GB/s (#47
Put a clock on the register ladder: a streamed band costs, and #47 sa…
Put a clock on the register ladder: a streamed band costs, and #47 sa…
The pin moves to 20a5616, and two doc claims did not survive the audit
The pin moves to 20a5616, and two doc claims did not survive the audit