14Transpose a large matrix at close to copy bandwidth. Why is the naive version slow, and what does each fix buy?▼mediumNewNVIDIA3 replies○ sign inA transpose moves every byte exactly once, so a device copy is the honest ceiling. Why the naive kernel pays eight times the write traffic, why staging through shared memory does nothing until you pad, and the counter that tells the two problems apart.Open full answer →
19A take-home gives you a working layernorm kernel at a tenth of memory bandwidth. Make it fast and justify every change.▼hard★ EssentialNewAnthropic4 replies○ sign inNormalization reads a row and writes a row, so a copy sets the ceiling and everything else is overhead you can remove. The six changes in the order a reviewer wants them, what each is worth, and the one that is a correctness fix rather than a speed fix, with the measured error that proves it.Open full answer →