This chapter does two things. It walks the ten TPU generations as a sequence of answers to specific bottlenecks, and it sets up the one model the rest of the course reasons with: the roofline. The two are the same story. Every generation is Google moving a ridge point.
Ten generations in one table
| Chip | Public | Role | Matrix units | Dense peak per chip | HBM | HBM BW | Largest ICI domain | Source |
|---|---|---|---|---|---|---|---|---|
| TPUv1 | 2015 deployed | Inference | 1 × 256×256, int8 | 92 TOPS int8 | 8 GiB DDR3 | 34 GB/s | none (PCIe card) | [P-v1] |
| TPUv2 | 2017 | Training | 2 cores × 1 × 128×128 | 46 TFLOP/s | 16 GiB | 700 GB/s | 256, 2D torus | [P-v23] |
| TPUv3 | 2018 | Training | 2 × 2 × 128×128 | 123 TFLOP/s | 32 GiB | 900 GB/s | 1,024, 2D torus | [P-v23] |
| TPU v4 | 2020 | Training | 2 × 4 × 128×128 | 275 TFLOP/s | 32 GiB | 1,200 GB/s | 4,096, 3D torus + OCS | [P-v4] |
| TPU v5e | 2023 | Cost, serving | 1 × 4 × 128×128 | 197 TFLOP/s | 16 GB | 819 GB/s | 256, 2D torus | [D-v5e] |
| TPU v5p | 2023 | Scale training | 2 × 4 × 128×128 | 459 TFLOP/s | 95 GiB | 2,765 GB/s | 8,960, 3D torus + OCS | [D-v5p] |
| TPU v6e | 2024 | Cost, serving | 1 × 2 × 256×256 | 918 TFLOP/s | 32 GB | 1,638 GB/s | 256, 2D torus | [D-v6e] |
| TPU7x | 2025, GA 2026 | Inference and training | 2 chiplets × 2 × 256×256 | 2,307 TFLOP/s; 4,614 fp8 | 192 GiB | 7,380 GB/s | 9,216, 3D torus + OCS | [D-7x] |
| TPU 8t | announced 2026-04 | Training | not published | 12.6 PFLOP/s fp4 | 216 GB | 6,528 GB/s | 9,600, 3D torus | [G-8dd] |
| TPU 8i | announced 2026-04 | Inference | not published | 10.1 PFLOP/s fp4 | 288 GB | 8,601 GB/s | 1,152, Boardfly | [G-8dd] |
Peaks are BF16 unless stated. "2 × 4 × 128×128" means two TensorCores, each with four 128×128 matrix units. Google publishes only FP4 peaks for TPU 8. The JAX hardware table lists BF16 at 996 TFLOP/s for 8t and 1,100 TFLOP/s for 8i provisional [J-hw]. Neither chip had reached general availability as of 2026-10-23.
Each generation answers a bottleneck
TPUv1 (2015): inference throughput per watt
Google projected in 2013 that speech recognition alone could double its datacenter compute [P-v1, §1]. The answer was a PCIe coprocessor with one 256×256 int8 systolic array, 24 MiB of on-chip buffer and 8 GiB of DDR3 at 34 GB/s. It ran 15–30× faster than the K80 GPU and Haswell CPU it was measured against, at 30–80× better TOPS/W. Its own roofline exposed its limit: the ridge sat at 1,350 operations per weight byte, so most production models were memory-bound, and the paper estimates GDDR5 would have tripled performance [P-v1, §4, §7].
TPUv2 (2017): training
Training needs floating point, more memory bandwidth and many chips. v2 replaced DDR3 with HBM (700 GB/s, about 20× v1), added a programmable vector unit with bf16 multiply and fp32 accumulate, and added the inter-chip interconnect, ICI. Chips connect directly in a 2D torus with routers on the chip and no external switch [P-Norrie] [P-v23]. The array shrank to 128×128, because a 256×256 array wastes more of its cells on the matrix shapes real models produce [HC-v23, Why 128x128].
TPUv3 (2018): more of the same, cooled by liquid
Two matrix units per core, 940 MHz instead of 700, twice the HBM, and pods of 1,024 chips. Liquid cooling allowed the extra power [P-v23].
TPU v4 (2020): scale, failures and embeddings
v4 has three new pieces [P-v4]:
- A 3D torus of 4×4×4 cubes, joined by optical circuit switches (OCS). The switches let a 4,096-chip pod be re-cut into slices, route around failed racks, and use twisted torus shapes. They cost under 5% of the system.
- SparseCores for embedding lookups. They take about 5% of die area and run embedding-heavy models 5–7× faster.
- 128 MiB of shared CMEM on the chip.
TPU v5e and v5p (2023): one line for cost, one for scale
v5e is a single-core chip in 256-chip 2D pods, priced for serving and small training [D-v5e]. v5p is the training flagship: 95 GiB of HBM, 2,765 GB/s, and 8,960-chip pods [D-v5p].
TPU v6e Trillium (2024): a bigger matrix unit
v6e moved to 256×256 arrays, giving 4.7× v5e's peak per chip [G-v6e] [D-arch]. v1 had used a 256×256 int8 array; v2 through v5 used 128×128. By 2024 the matrix dimensions in production models were large enough to fill 256×256 arrays.
TPU7x Ironwood (2025): inference at training scale
Two compute chiplets per package, each seen by JAX as its own device. 192 GiB of HBM at 7,380 GB/s, native FP8 at 4,614 TFLOP/s, and 9,216-chip pods at about 10 MW [D-7x] [G-7x]. Google's launch post calls it "the first Google TPU for the age of inference". The HBM capacity is for KV caches and the bandwidth is for decode.
TPU 8t and 8i (announced April 2026): two chips
The first generation split by workload [G-8dd]:
- 8t keeps the 3D torus, scales the pod to 9,600 chips and doubles ICI bandwidth relative to Ironwood.
- 8i has 288 GB of HBM at 8,601 GB/s and 384 MB of on-chip SRAM, three times Ironwood's, sized to keep KV cache on chip. It replaces the torus with a lower-diameter "Boardfly" network of at most 7 hops, and replaces SparseCores with a collectives engine.
The rest of this chapter explains why decode traffic pushed Google there.
FLOPs outgrew bandwidth
From TPUv2 to Ironwood, per-chip BF16 FLOP/s grew 50× and HBM bandwidth grew 10.5×. Google's own retrospective gives the same shape: about 100× peak and 10× HBM over five generations, counting Ironwood's FP8 peak [P-Micro26]. The ratio of the two is the number this chapter is about.
| Chip | BF16 TFLOP/s | HBM GB/s | Ridge, FLOP/B |
|---|---|---|---|
| TPUv2 (2017) | 46 | 700 | 66 |
| TPUv3 (2018) | 123 | 900 | 137 |
| TPU v4 (2020) | 275 | 1,200 | 229 |
| TPU v5p (2023) | 459 | 2,765 | 166 |
| TPU7x (2025) | 2,307 | 7,380 | 313 |
Two times bound every kernel
A kernel spends time in two places: arithmetic and data movement. The Scaling Book models both as a count divided by a rate [SB1].
Time on arithmetic is work over peak FLOP/s, C. Time on data movement is bytes over the bandwidth W of whichever link carries them: HBM, ICI, PCIe or DCN.
With perfect overlap the kernel takes . With none it takes the sum, at most 2× worse. The course reasons from the max.
Arithmetic intensity is the ratio of the two counts: FLOPs per byte moved. A chip has an intensity too, the ratio of its two rates. A kernel is compute-bound when its intensity exceeds the chip's:
A kernel keeps the matrix units busy only if it does more arithmetic per byte than the chip can do per byte of bandwidth.
The right-hand side is the chip's ridge point. TPUv2's was 66 FLOP/B and Ironwood's is 313. For the chips used in this course, against HBM:
| Chip | BF16 | FP8 | INT8 | HBM BW | BF16 intensity |
|---|---|---|---|---|---|
| TPU v5e | 197 TFLOP/s | — | 394 TOP/s | 819 GB/s | 241 |
| TPU v5p | 459 TFLOP/s | 459 TFLOP/s | 918 TOP/s | 2.77 TB/s | 166 |
| TPU v6e | 918 TFLOP/s | 920 TFLOP/s | 1.84 POP/s | 1.64 TB/s | 560 |
| TPU7x Ironwood | 2.31 PFLOP/s | 4.61 PFLOP/s | — | 7.38 TB/s | 313 |
| TPU 8t | 996 TFLOP/sp | 5.98 PFLOP/sp | 996 TOP/sp | 6.53 TB/s | 153p |
| TPU 8i | 1.1 PFLOP/sp | 8.81 PFLOP/sp | — | 8.6 TB/s | 128p |
| H100 SXM | 989 TFLOP/s | 1.98 PFLOP/s | — | 3.35 TB/s | 295 |
| B200 (HGX) | 2.25 PFLOP/s | 4.5 PFLOP/s | — | 8 TB/s | 281 |
p provisional: from the JAX Pallas hardware table, not in Google's published spec.
Values come from Cloud TPU docs, the JAX hardware table for TPU 8's BF16, FP8 and INT8 rows, and NVIDIA product pages with sparse figures halved [D-7x] [J-hw] [G-8dd] [N-h100]. The Scaling Book uses 240 for v5e; the docs-based figure here is 241. v5p's ridge, 166, is lower than v5e's because v5p carries 3.4× the bandwidth for 2.3× the FLOPs. v5p and v6e list FP8 at the same rate as BF16, so FP8 on those chips saves bytes but not time [D-v5p] [J-hw].
A matmul's intensity is its batch
Take in bf16. It does FLOPs and moves bytes:
When the token batch is small next to the weight dimensions, weight bytes dominate, and every weight byte is used once per token. Intensity equals the number of tokens.
So a bf16 matmul on Ironwood is compute-bound once the token batch per replica exceeds about 313. On v5e the figure is 241 and on an H100 it is 295 [SB1]. The batch counts tokens, not sequences. Model sharding does not change it, because sharding divides FLOPs and bandwidth by the same factor.
The up-projection has and [SB6]. At in bf16 on one Ironwood chip (2,307 TFLOP/s, 7,380 GB/s [D-7x]):
- FLOPs: , so .
- Bytes: , nearly all of it the 470 MB weight matrix, so .
- Intensity: 63.4 FLOP/B against a ridge of 313. HBM-bound by 4.9×.
Solving Eq. 1.3 exactly for this shape puts the compute-bound batch at 329 tokens, slightly above the ridge, because activation bytes are not zero. The same step takes 579 µs on v5e and 142 µs on an H100. Computed by scripts/ch01_roofline.py.
Precision moves the ridge
Store the weights in int8 or fp8 and keep the math in bf16. FLOPs stay at , but weight bytes halve to , so intensity becomes about :
Each weight byte read supports 2 / (bytes per weight) FLOPs per token, so intensity is about 2B divided by bytes per weight. C is the peak for the precision the math runs in. Halving bytes per weight halves the batch needed; doubling the math rate doubles it back.
The Scaling Book writes this as , with the ratio of weight bits to activation bits and the BF16 peak [SB7]. For bf16 math the two forms agree. Formula 1.4 also covers low-precision math directly.
On v5e, int8 weights with bf16 math bring the compute-bound batch from 240 to 120 [SB1, Q2]. On Ironwood the example shape goes from 329 to 164.
Moving the math to low precision as well doubles . On Ironwood, fp8 math runs at 4,614 TFLOP/s [D-7x], so the ridge doubles to 625 and the compute-bound batch returns to 329. The step still gets faster: at batch 64 it drops from 64 µs to 32 µs, because the bytes halved. The batch at which the matrix units saturate is what stays put.
The provisional TPU 8i figures push this further. Its fp8 ridge is about 1,024 FLOP/B provisional. With fp8 weights and fp8 math, the example shape needs more than 557 tokens per chip to be compute-bound. Decode batches that large are rare, especially with long contexts, as Chapter 7 shows. Google's design answer for 8i was bandwidth and on-chip SRAM, not FLOPs: 8,601 GB/s of HBM and 384 MB of SRAM [G-8dd].
HBM-bound. Loading 474 MB takes 64.3 µs; the 30.1 GFLOP of math would take 13 µs.
The same roofline for a network link
Replace HBM with an inter-chip link and the model is unchanged. The Scaling Book's example splits the contracting dimension of across two chips [SB1]. Each chip multiplies its half, FLOPs, then the chips exchange bytes of bf16 partial sums:
Splitting the contracting dimension is worthwhile only if each chip's half of the matmul takes longer than shipping the partial result to the other chip.
The threshold now depends on , not on the batch. On v5e, with 45 GB/s one way per link, it is [SB1]. On Ironwood, the Cloud docs give 200 GB/s per link counting both directions, so 100 GB/s one way [D-7x]. The threshold becomes derived: no current model has a hidden dimension that large. Ironwood's FLOPs grew 11.7× over v5e while its per-link bandwidth grew 2.2×. Chapters 5 and 6 work through what that does to tensor parallelism.
What the HBM roofline leaves out
Three things the model above does not capture, each of which shows up in Chapter 10's profiles.
Vector-unit work has its own roofline. Elementwise ops, reductions and softmax run on the VPU, not the matrix units. On v5p the VPU peaks at about 7 TFLOP/s per core, a critical intensity of about 3 [SB1]. A dot product, at 0.5 FLOP/B, is memory-bound on any chip. These ops are cheap only when XLA fuses them into the matmul that produces or consumes their input.
Small transfers are latency-bound. Each ICI hop costs about 1 µs regardless of size. On v5e, any per-hop chunk under about 45 kB spends more time on latency than bandwidth [SB3]. That is the normal regime for decode-time collectives (Chapter 7).
Peak is not achievable peak. The Scaling Book states that H100s and B200s usually reach 80–85% of claimed peak FLOP/s, while TPUs get closer to 95% [SB1]. The book does not publish the measurements behind those figures, so treat them as practitioner estimates.