liveBook · Manning

Compute-bound

As explained in Domain-Specific Small Language Models

A performance regime where execution is limited by available compute units rather than memory transfer rate.

Compute bound describes a regime where performance is limited by available compute units rather than memory-transfer rate. Compare arithmetic intensity—operations divided by bytes accessed—with hardware ops/byte: exceeding the hardware ratio indicates compute-bound execution. section 4.3.1

Use the distinction to guide GPU inference optimization:

  • Calculate the device’s ops/byte ratio; the T4 example reaches 216.6 ops/byte. section 4.3.1
  • Calculate model or layer arithmetic intensity and compare it with the hardware ratio. section 4.3.1
  • Inspect computationally demanding Transformer attention layers before choosing optimizations. section 4.3.1

Attention arithmetic intensity

For an attention computation, estimate memory movement and floating-point work, then divide the totals. One worked calculation produces 71,303,168 bytes moved, 2,160,066,560 operations, and 30.29 ops/byte; comparing this with the T4’s 216.6 ops/byte indicates memory-bound rather than compute-bound behavior. section 4.3.1

How Domain-Specific Small Language Models covers it

How deep it goes
Quantifies hardware and model arithmetic intensity, then applies the comparison to Transformer attention layers.
Examples
Uses a T4 ratio of 216.6 ops/byte and an attention calculation yielding 30.29 ops/byte.
What you can do after
Evaluate whether an inference workload is compute bound or memory bound on specific hardware.
How it connects
Connects GPU inference with memory-bound execution, arithmetic intensity, Transformer attention, and hardware ops/byte.

Also explained in

Compare how 5 books explain compute-bound →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Domain-Specific Small Language Models. The section links point to the parts of the book it draws on.