179 questions
No questions match those filters.
What is the roofline model and how do you use it to rea...
This is one of the questions in the full AI/ML interview bank. Pro unlocks all 1789 questions; Premium includes the same bank plus the highest daily Practice limit.
See plansThe roofline model relates a workload’s arithmetic intensity — FLOPs performed per byte of data moved — to the hardware’s two hard limits: peak compute throughput and peak memory bandwidth. Plot arithmetic intensity on one axis and achieved performance on the other, and you get a “roofline”: below a certain intensity, you’re capped by memory bandwidth no matter how much compute is available; above it, you’re capped by compute instead.
LLM inference is a textbook memory-bound workload during decoding: each generated token requires loading the entire model’s weights (and the KV cache) but only performs a small amount of arithmetic against them, so the GPU spends most of its time waiting on memory bandwidth, not doing math. That single fact explains an entire category of optimization techniques: quantization reduces bytes moved per weight, speculative decoding amortizes one weight-load across multiple verified tokens, and batching lets you reuse the same weight load across more tokens at once — every one of these attacks the memory-bandwidth bottleneck the roofline model identifies, not the compute one.