← All questions
System DesignHard· Roofline Model· Performance Analysis

How would you use the roofline model to evaluate a prop...

To evaluate an architectural change, you calculate the arithmetic intensity (AI) of the new operation and compare it against the original. For example, a depth-wise convolution typically has an AI of approximately kernel_size/2, which is often well below the hardware’s ridge point. If the original matmul was compute-bound at a given batch size, replacing it with a memory-bound operation like a depth-wise convolution will likely decrease performance, as the new operation will be limited by memory bandwidth rather than the GPU’s compute throughput.

Code playground (Python)