In tiled matrix multiplication, tile shape sets the dimensions of each program’s work. BLOCK_M × BLOCK_N defines its output tile; BLOCK_K sets the width of each slice accumulated along K. These choices determine which values are loaded together and reused on-chip. section 5.0 section 5.5.4
Tile dimensions affect both implementation and performance:
- Square output tiles balance reuse between A and B; rectangular tiles may run faster for a particular matrix shape or GPU. section 5.5.4
- Each program accumulates its output tile across K-slices. The initial kernel assumes dimensions divide evenly by the tile sizes; a later version handles incomplete edge tiles and K remainders. section 5.5.5 section 5.10
- Autotuning can compare tile shapes alongside warp counts and software-pipeline stages. section 5.10
Figure 5.12 Tiled matrix multiplication for the 4 × 4 numerical example. Program (0, 0) owns C 00. It multiplies A 00 by B 00 for the first K slice, carries the resulting accumulator into the second slice, and adds A 01B 10 before storing C 00. Programs (0, 1), (1, 0), and (1, 1) perform the same K-loop pattern independently for the other output tiles.
Trace how four programs each own an output tile and update its accumulator across the two K-slices of a 4 × 4 product. section 5.5.4

