the.ai

Systems / Hardware

verified

Kernel Fusion

A chain of simple operations — add a bias, apply an activation, scale the result — each reads its input from main memory and writes its output back, even though the next step wants exactly what was just written. Fusing them into one kernel keeps the intermediate on chip and crosses the boundary once instead of three times. The arithmetic is unchanged; the traffic is not.

Viz primitive · budget-splitfused-ops = 3

fused-ops holds 38% of the budget; rest holds the remaining 62%.

Operations a single kernel keeps on chip against those that still round-trip through main memory. Drag the fusion width to watch the traffic collapse into one pass.

3

Reviewed by opendroid · 2026-08-04

  • arXiv:2007.00072 — Data Movement Is All You Need: A Case Study on Optimizing Transformers
  • arXiv:2205.14135 — FlashAttention: Fast and Memory-Efficient Exact Attention with IO-Awareness