Karthik Balasubramanian ML Inference & GPU Systems
Kernel Engineering Series · Interactive Lab Companion to Part 3: Climbing the CUDA GEMM Ladder · Part 2: Silicon Bottleneck · Source on GitHub

Climbing the CUDA GEMM Ladder: Eliminating the Byte Tax

Every rung is a physics experiment against one enemy: moving bytes that don't earn their keep. Step through all 8 kernels from my_matmul_kernels.py—watching each optimization crush one silicon bottleneck and immediately expose the next.

Target GPU
132 SMs · 61.8 TFLOP/s FP32 · 3.35 TB/s HBM3 · FP32 Ridge 18.4 FLOP/B
HBM / Global Memory (slow, 32B sectors) Shared Memory / SRAM (fast on-chip) Registers / Accumulators (fastest) Warp Tile / Broadcast / Tensor Core
Navigate: ← → or 1–9  ·  Space Play/Pause
Rung 1 · Global Memory Baseline

Naive MatMul (Uncoalesced Sector Explosion)

Presets:
Loading animation...
Bottleneck Crushed —
Next Wall Exposed —

Live Roofline Shift (FP32 CUDA Cores)

Analytical model (not measured GPU runs): Ceilings = official NVIDIA datasheet specs; X-axis = exact closed-form HBM AI from my_matmul_kernels.py; dot height below roof illustrates on-chip stall headroom from CUDA literature.
First-Principles Physics

Why Naive MatMul Starves the SM

Failure Mode & Nsight Compute Diagnostic

What Breaks If You Slip — and What Moves in ncu

    Rung 1 / 9

    The Full GEMM Ladder at a Glance

    Click any row to jump directly to its live simulation · All numbers derived analytically for FP32 (4 B/float, 32B sectors)

    Rung Kernel / Mechanism Tile Hierarchy HBM AI (FP32) SMEM / MIO Pressure Bottleneck Fixed Next Bottleneck Exposed