heat to the air · one row per building, more on the roofs
Sized in powerone square = one hall
A big cloud data centre · ≈30 MW
A frontier AI campus · ≈1 GW
Gold: the hall on the next screen. Each one draws ≈17 MW, cooling included.
Plans now run to several gigawatts. Sites are picked for power first: a grid connection, or gas for turbines on site. Land is the easy part.
1
2
3
4
5
6
100s MW–GW
FRONTIER SITES
≈60
HALLS PER GIGAWATT
≈470 k
GPUS PER GIGAWATT
≈17 MW
ONE HALL, ALL-IN
A data centre for AI is described by how much power it draws, not how big it is. Every number on the next screens comes out of this budget.
Power ingrid to rack
Grid
100–400 kV lines
Substation
→ ≈10–35 kV
Switchgear
+ backup gensets
UPS + batteries
rides through blips
Busway / PDUs
≈415 V to each row
Backup generation
gas turbines / diesel
Data hall108 NVL72 racks in 3 aisle pairs
hot aisle · contained
cold aisle
CDU
hot aisle · contained
cold aisle
CDU
hot aisle · contained
CDU
Network row
spine switches · fibre overhead to every rack
Heat out≈ all of the power
Facility water loop
≈30–40 °C
Heat exchangers / chillers
only on hot days
Dry coolers / towers
on the roof
Heat to the air
or reused
1
2
3
4
5
6
≈14 MW
IT LOAD · THIS HALL
108
NVL72 RACKS
≈7,800
GPUS
≈1.2
PUE · OVERHEAD
≈60 halls
PER GIGAWATT CAMPUS
≈0
WATER IF DRY-COOLED
Every watt that goes in at the top comes out as heat on the right. The racks in between turn a little of it into tokens.
Scale-out networkleaf · spine · core · fibre
Core
Core
Core
Core
Spine
Spine
Spine
Spine
Spine
Spine
Spine
Spine
Leaf
Leaf
Leaf
Leaf
Leaf
Leaf
Leaf
Leaf
8 racks drawn · a hall has 108 · each GPU has its own NIC into a leaf
gold: one GPU to a GPU in another rack · 5 switches
Per GPU, each wayinside vs outside the rack
NVLink, inside the rack
1.8 TB/s
This network, between racks
100 GB/s (800 Gb/s NIC)
50 GB/s (400 Gb/s NIC)
18–36× slower. Work that talks constantly stays inside a rack; lighter traffic crosses here.
What crosses racks
gradients · pipeline activations · KV caches
Front-end network
separate · storage, the internet, control
1
2
3
4
5
6
400–800 Gb/s
PER GPU · 50–100 GB/S
1 NIC
PER GPU
≤ 5
SWITCHES, ANY 2 GPUS
18–36×
NVLINK VS THIS
Any GPU in the hall can reach any other in a few hops, at full speed for every GPU at once. It's still far slower than the copper inside a rack, so jobs are laid out around that gap.
Front view≈1.4 t · 48U
Power
10 compute trays
9 NVSwitch trays
8 compute trays
Power
NVLink spinescale-up · copper
18 NVSwitch chips · 2 per switch tray
72 B200 GPUs · each column is one compute tray
One GPU's 18 links drawn in full; every GPU has the same. More than 5,000 copper cables run down the back of the rack.
72 × 1.8 TB/s ≈ 130 TB/s
Scale-outfibre · to other racks
Spine
Spine
Leaf
Leaf
Leaf
Leaf
This rack (gold) and thousands more · 400 Gb/s per GPU
Power & cooling≈120 kW in and out
Power shelves
AC → DC
Busbar
DC down the back
Manifolds
cold in · hot out
CDU
to facility water
Blue in, brick out: heat leaves in water
1
2
3
4
5
72
B200 GPUS
13.8 TB
HBM3E IN TOTAL
130 TB/s
NVLINK
≈120 kW
PER RACK
1.4 EF
FP4 · VENDOR PEAK
5,000+
COPPER CABLES
Compute traytop view · back on the left, front on the right
NVLink
to the spine
in out
GB200 superchipboard
Grace CPU
72 Arm Neoverse V2 cores
LPDDR5X
480 GB
B200
192 GB
B200
192 GB
GB200 superchipboard
Grace CPU
72 Arm Neoverse V2 cores
LPDDR5X
480 GB
B200
192 GB
B200
192 GB
ConnectX-7
400 Gb/s · OSFP
ConnectX-7
400 Gb/s · OSFP
ConnectX-7
400 Gb/s · OSFP
ConnectX-7
400 Gb/s · OSFP
BlueField-3
DPU · storage
BlueField-3
DPU · storage
Fans + PSU input
48 V DC from busbar
1
2
3
4
5
4 + 2
B200 + GRACE
768 GB
HBM3E ON THE TRAY
960 GB
LPDDR5X
72
NVLINKS OUT THE BACK
4 × 400G
NICS OUT THE FRONT
≈6 kW
ALL LIQUID-COOLED
Cold plates sit on all 6 chips; quick-disconnects at the back let a tray slide out without draining the rack.
Switch traytop view · back on the left
Spine
connectors · 144 links
NVSwitch chip 1
72 NVLink ports · 28.8 Tb/s
1 port per GPU in the rack: GPU 1 … GPU 72
NVLink SHARP
adds up numbers inside the switch
NVSwitch chip 2
72 NVLink ports · 28.8 Tb/s
1 port per GPU in the rack: GPU 1 … GPU 72
NVLink SHARP
adds up numbers inside the switch
Mgmt + BMC
front ports, no data
Cold plates
on both chips
Power in
48 V busbar
1
no link between chips
2
3
4
2
SWITCH CHIPS
144
NVLINK PORTS
3.6 TB/s
PER CHIP, EACH WAY
9 × 2 = 18
CHIPS PER RACK
1 hop
BETWEEN ANY 2 GPUS
1.8 TB/s per GPU, 18–36× the cluster network: work that needs constant communication stays inside the rack. Each GPU sends 1/18 of its traffic through each of the 18 chips.
GB200 superchipone board · top view
Grace CPU72 Arm cores
LPDDR5X
480 GB · ≈0.5 TB/s
C2C
900 GB/s
B200
192 GB
B200
192 GB
NVLink, 18 links per GPU
to the back of the tray → the switch trays
C2C to the second GPU
Cold plates
on all three chips · ≈2.7 kW per board
Memory one GPU can usedrawn to scale
How much
192 GB · own HBM3e
480 GB · Grace's LPDDR5X
How fast
8 TB/s · own HBM3e
0.9 TB/s · C2C
0.13 TB/s · PCIe Gen 5 x16
Grace's memory is a slower overflow tier: ≈9× slower than HBM, but ≈7× faster than reaching a CPU over PCIe, and the GPU reads it directly.
1
2
3
4
5
6
1 + 2
GRACE + B200
384 GB
HBM3E · 2 GPUS
480 GB
LPDDR5X
900 GB/s
NVLINK-C2C
≈7×
PCIE GEN 5 X16
In an ordinary server the CPU sits behind PCIe. Here it's joined to its GPUs by a fast, coherent link, so its memory works as overflow for theirs.
B200 packagedies joined by a 10 TB/s bridge (NV-HBI)
Silicon interposerCoWoS-L
HBM3e
24 GB
HBM3e
24 GB
HBM3e
24 GB
HBM3e
24 GB
HBM3e
24 GB
HBM3e
24 GB
HBM3e
24 GB
HBM3e
24 GB
Die 074 SMs
L2 cache
~63 MB
NVLink PHY
9 of 18 links
Die 174 SMs
L2 cache
~63 MB
NVLink PHY
9 of 18 links
NVLink domain72 GPUs in one rack
8 of the 71 other B200s
NVSwitch chips ×18
in the rack's 9 switch trays
Every GPU, this one too, has 18 links: one to each switch chip. Any GPU reaches any of the other 71 in one hop.
Reticle limit ≈858 mm²
why there are two dies
1
2
3
4
5
6
192 GB
HBM3E · 8 STACKS
8 TB/s
HBM BANDWIDTH
148
SMS · 74 PER DIE
1.8 TB/s
NVLINK 5 · 18 LINKS
~1.2 kW
POWER IN GB200
208 B
TRANSISTORS
Compare: B300 vs B200
taller memory stacks
L2 cache
outside the SM · ~126 MB
SM1 of 148 · identical copies
Shared memory / L1
256 KB SRAM · up to 228 KB as shared
TMA
copies tiles in
Warp scheduler
16 warps queue
Registers
64 KB
Tensor core
5th gen
Warp scheduler
16 warps queue
Registers
64 KB
Tensor core
5th gen
Warp scheduler
16 warps queue
Registers
64 KB
Tensor core
5th gen
Warp scheduler
16 warps queue
Registers
64 KB
Tensor core
5th gen
Tensor memory
256 KB · holds the running result tiles
4 schedulers
4 × 64 KB
128 CUDA cores
4 tensor cores
B200 has no RT cores
1
2
3
4
5
6
128
CUDA CORES
4
TENSOR CORES
256 KB
REGISTERS
228 KB
SHARED MEMORY
256 KB
TENSOR MEMORY
2,048
THREADS IN FLIGHT
One instructionD = A × B + C · a 16 × 8 × 16 tile
A · 16 × 16
×
B · 16 × 8
+
C · 16 × 8
=
D · 16 × 8
each D number: 16 multiplies + 1 add · 2,048 multiply-adds in all
Shared memory
A and B tiles, copied in by the TMA
Tensor memory
C in, D out · kept between tiles
Tensor core · 1 of 4 in this SM
all 2,048 multiply-adds in one instruction, then the next K slice
Fewer bits, more mathsdense peak per GPU
BF16
16 bits
≈2.5 PF
FP8 (E4M3)
8 bits
≈5 PF
FP4 (E2M1)
4 bits
≈10 PF
red sign · gold exponent · blue mantissa
1
2
3
4
5
D = A×B + C
ONE INSTRUCTION
592
PER B200 (4 × 148)
2,048
MULTIPLY-ADDS
2×
PER HALVING OF BITS
≈10 PF
FP4 · DENSE · PER GPU
Halve the bits and the same silicon does twice the multiplies, and every weight takes half the memory and bandwidth. That's why the move to FP8 and FP4 matters so much.
Cross-sectionone stack, side view · not to scale
DRAM die 1
DRAM die 8
3 GB
TSVs: copper wires drilled through every die, straight down to the base.
Base logic die
Silicon interposer
CoWoS-L
Compute die
B200 · 1 of 2
1,024 wires
The stack sits millimetres from the compute die, joined through the interposer.
8 stacks per B200
8 × 24 GB = 192 GB · ≈8 TB/s
12-high on B300
36 GB per stack · 288 GB
Three makers
SK hynix · Samsung · Micron
Why stack? A memory stick has a 64-bit bus. Stacking puts 1,024 wires within millimetres of the GPU, which is where the bandwidth comes from.
1
2
3
4
5
24 GB
PER STACK
≈1 TB/s
PER STACK
1,024
BITS WIDE
192 GB
B200 · 8 STACKS
≈8 TB/s
B200 · ALL STACKS
Decode reads every weight once per token, so a B200 can stream its whole 192 GB about 40 times a second at most.
Memorythe visible difference
B200
8 × 8-high = 192 GB
B300
8 × 12-high = 288 GB
What changed
B200
B300
Why it matters
HBM3e
192 GB
288 GB
longer contexts
Dense FP4
≈10 PF
≈15 PF
+50%, vendor figures
Attention exp()
1×
2×
faster softmax in the SFUs
NVLink
1.8 TB/s
1.8 TB/s
unchanged
Scale-out NIC
400 Gb/s
800 Gb/s
ConnectX-8
Power
≈1.2 kW
≈1.4 kW
per GPU in an NVL72
FP64
high
much lower
Ultra drops HPC maths
Lineageone generation a year
Hopper H100
2022 · 80 GB
H200
2024 · 141 GB
Blackwell B200
2024 · 192 GB
Blackwell Ultra B300
2025 · 288 GB
Rubin
2026 · HBM4
288 GB
HBM3E PER GPU
20.7 TB
PER GB300 NVL72
12-high
STACK HEIGHT
2×
ATTENTION EXP
800G
NIC PER GPU
Figures are vendor peak numbers, rounded. Check them against Nvidia's datasheets before publishing.
1 · Text → tokens
The
791
capital
6864
of
315
France
9822
is
374
2 · Token ids → vectors
Each id picks a row from a 128,256 × 4,096 table: 4,096 numbers per token (8 drawn).
3 · 32 transformer blocks
block 1 (bold) → block 32 · each adds to the stream
residual stream ↑
4 · Last vector → scores
Final norm + unembed
4,096 → 128,256
One score (logit) for every token in the vocabulary.
5 · Scores → probabilities
Paris
86%
the
4%
a
2%
located
1.5%
known
1.0%
6 · Pick one
Sampler
temperature 0.7 · top-p 0.9
“ Paris”
id 12366
↻ loop until a stop token
7 · Append and repeat
“The capital of France is Paris” goes back in. Only the new token runs through the blocks; the others are remembered in the KV cache.
KV cache
keys + values of past tokens
8 B
PARAMETERS
32
BLOCKS
4,096
NUMBERS PER TOKEN
128,256
VOCABULARY
≈16 GFLOP
PER TOKEN (2 × PARAMS)
16 GB
WEIGHTS AT BF16
Text in, numbers outLlama 3's tokenizer
“The capital of France is”
24 characters
Tokenizer
a fixed list of 128,256 pieces
The
791
␣capital
6864
␣of
315
␣France
9822
␣is
374
␣ = a leading space, which is part of the token
What the model receives: [791, 6864, 315, 9822, 374]
five whole numbers, nothing else
How text gets cutthe same rules for every input
Common words: one token
␣Paris
␣the
Rare words: several pieces
␣tok
enizer
illustrative split
Numbers: up to 3 digits each
202
6
“2026” → 2 tokens
Same word, different ids
capital
␣capital
with and without the space
English averages about 4 characters a token. Code and other languages usually take more tokens for the same text.
1
2
3
4
5
5
TOKENS
128,256
POSSIBLE TOKENS
≈4 chars
PER TOKEN, ENGLISH
0
LETTERS THE MODEL SEES
The model never sees text, only these ids. Everything it learns about spelling, it learns from which ids tend to follow which.
A lookup, not a calculationid → row
The
791
␣capital
6864
␣of
315
␣France
9822
␣is
374
Embedding table
128,256 rows × 4,096
rows in id order
4,096 numbers each
→ residual stream
What a row holdslearned in training
Rows start random. Training moves them so tokens used in similar ways end up with similar rows.
2 of 4,096 directionsillustrative
France
Germany
Italy
Paris
Berlin
Rome
countries together, capitals together
It's only a starting point: the same row for “ capital” whether it means a city or money. The blocks after this work out which.
1
2
3
4
5
4,096
NUMBERS PER TOKEN
≈525 M
PARAMETERS IN THE TABLE
≈1 GB
AT BF16
0
MULTIPLIES · A LOOKUP
Each vector is the token's starting point in the residual stream. Everything the model does from here is added onto it.
Five streams, one per token4,096 numbers each, top to bottom
The
capital
of
France
is
block 1
+ attn
+ MLP
block 2
+ attn
+ MLP
block 32
+ attn
+ MLP
⋮ 3–31 the same
↓ the last column (“is”) goes on to the output head
Add, never overwriteone block, written out
x ← x + attention(x)
tokens look at each other
x ← x + MLP(x)
each token alone
One number of “is”, through the first blocks
embedding
0.30
+ attn 1
+0.15
+ MLP 1
−0.10
+ attn 2
+0.25
= after 2
0.60
illustrative values · one of 4,096 numbers
1
2
3
4
5
4,096
WIDE, ALL THE WAY DOWN
64
ADDITIONS · 2 PER BLOCK
5
STREAMS, ONE PER TOKEN
0
NUMBERS OVERWRITTEN
Every layer reads the stream and adds something back. Nothing is overwritten, so early information survives to the end, and a layer that has nothing to add can add almost zero.
Three projectionsone head · the same 3 matrices for every token
W_Q
4,096 → 128
W_K
4,096 → 128
W_V
4,096 → 128
x · token vector
query
key
value
The
q(The)
k(The)
v(The)
capital
q(capital)
k(capital)
v(capital)
of
q(of)
k(of)
v(of)
France
q(France)
k(France)
v(France)
is
q(is)
k(is)
v(is)
Next, “is” compares its query with every key, then takes a mix of the values.
Grouped-query attention32 q heads · 8 kv heads
k head 1
v head 1
k head 2
v head 2
k head 3
v head 3
k head 4
v head 4
k head 5
v head 5
k head 6
v head 6
k head 7
v head 7
k head 8
v head 8
Every 4 query heads share one key and one value head, so the KV cache is 4× smaller.
1
2
3
4
5
128
NUMBERS IN EACH q, k, v
32
QUERY HEADS
8
KEY/VALUE HEADS
≈42 M
ATTENTION PARAMS PER BLOCK
Attention is the only step where tokens share information. Everything else in the model works on one token at a time.
Weights for every pairrow asks, column answers
keys →
The
The
1.00
−∞
−∞
−∞
−∞
capital
capital
0.35
0.65
−∞
−∞
−∞
of
of
0.10
0.60
0.30
−∞
−∞
France
France
0.05
0.30
0.15
0.50
−∞
is
is
0.03
0.32
0.05
0.52
0.08
Dashed cells are later tokens, masked out before softmax.
The row for “is”score, then softmax
1 · Score: q(is) · k / √128
The
0.49
capital
2.86
of
1.00
France
3.35
is
1.47
2 · Softmax: exponentiate, divide by the total
The
0.03
capital
0.32
of
0.05
France
0.52
is
0.08
Scores 0.5 apart become weights several times apart: the biggest score dominates.
1
2
3
4
n²
SCORES PER HEAD
÷ √128
SCALING
−∞ → 0
MASKED
1.00
EACH ROW SUMS TO
The causal mask is why a chat model can only look backwards: when it writes a token, the tokens after it don't exist yet. Weights here are illustrative, not from a real model.
Mix the valuesfor “is” · head 7
The
× 0.03
capital
× 0.32
of
× 0.05
France
× 0.52
is
× 0.08
v · value
weight
what it gives
Sum
128 numbers
× W_O
all 32 heads → 4,096
+ stream
added onto “is”
52% of France's value and 32% of capital's: “is” now carries “capital of France”.
32 heads at oncethe “is” row of each · illustrative
Gold: head 7, the one on the left. Each head gathers something different; W_O combines them all.
1
2
3
4
5
52%
FROM “FRANCE”
32%
FROM “CAPITAL”
32 × 128
= 4,096 · HEADS JOINED
1
ADDITION ONTO THE STREAM
After attention, “is” carries the context it needs: the next layers can tell that what follows should be a capital, and France's.
residual stream
RMSNorm
rescale to unit size
Attention
32 query heads · 8 KV heads · each token reads the ones before it
RMSNorm
rescale to unit size
MLP · SwiGLU
4,096 → 14,336 → 4,096 · each token on its own
Attention moves information between tokens: “is” learns it's about France.
The MLP looks things up: France + capital → Paris. Most of the facts live here.
Each step adds a small change rather than replacing the vector. That's what lets 32 blocks stack.
1
2
3
4
5
6
≈42 M
ATTENTION PARAMS
≈176 M
MLP PARAMS
32 / 8
Q / KV HEADS
128
NUMBERS PER HEAD
≈80%
OF PARAMS IN MLPS
Scoresquery row reads key columns
keys → (what each token offers)
The
The
1.00
capital
capital
0.35
0.65
of
of
0.10
0.60
0.30
France
France
0.05
0.30
0.15
0.50
is
is
0.03
0.32
0.05
0.52
0.08
Rows sum to 1. Dashed cells are masked: a token can't see the future.
What happensfor the token “is”
1
Make q, k, v
q = what am I looking for, k = what do I hold, v = what I pass on
2
Score
dot q(“is”) with every earlier k, divide by √128
3
Softmax
turn scores into weights that sum to 1 (the bottom row)
4
Mix
take 52% of v(France) + 32% of v(capital) + …
5
Project out
one more matrix, then add onto the residual stream
32
HEADS PER LAYER
128
DIMS PER HEAD
n²
SCORES PER LAYER
8 KV heads
SHARED BY 4 Q HEADS EACH
128 K
MAX CONTEXT (TOKENS)
Real heads specialise: some track the previous word, some match brackets, some look up the subject. The weights in this grid are illustrative, not from a real model.
DenseLlama 3 8B
token vector · 4,096 (16 drawn)
up-project · 14,336 hidden units (56 drawn) · gate × up
down-project · back to 4,096
Each hidden unit tests the token for one pattern and, if it matches, writes a little back. Every unit runs, every token: 176 M multiply-adds per layer.
Mixture of expertse.g. 128 experts, 8 used per token
token “Paris”
Router
scores all 128
128 experts · the 8 bright ones run for this token, the rest sit idle
Total parameters grow with the number of experts; compute per token grows only with the number used. Models like DeepSeek-V3 (671 B total, 37 B active) and Qwen3 MoE work this way.
1
2
3
4
5
176 M
DENSE MLP · PER LAYER
100%
WEIGHTS USED
671 B
DEEPSEEK-V3 TOTAL
37 B
ACTIVE PER TOKEN
≈5%
FRACTION THAT RUNS
MoE trades memory for speed: all 671 B parameters must sit in GPU memory, but each token only pays for 37 B. That's why big MoE models want racks like the NVL72.
Six optionsUS launch prices · ceilings for 32B at Q4_K_M
memory · teal = 32B at Q4
bandwidth
price
ceiling
RTX 5060 Ti 16 GB
16 GB
448 GB/s
$429
doesn't fit
RTX 3090, used
24 GB
936 GB/s
≈$800 used
≈49 tok/s
RX 7900 XTX
24 GB
960 GB/s
$999
≈51 tok/s
RTX 4090
24 GB
1,008 GB/s
$1,599
≈53 tok/s
RTX 5090
32 GB
1,792 GB/s
$1,999
≈94 tok/s
Mac Studio, M4 Max
128 GB →
546 GB/s
≈$3,500
≈29 tok/s
dashed line: 19 GB of weights · ceiling = bandwidth ÷ 19 GB · real speeds land below · prices move
1
2
3
4
memory
DECIDES WHAT FITS
bandwidth
DECIDES THE SPEED
≈94 tok/s
FASTEST HERE · 5090
128 GB
MAC · SLOWER, BUT FITS 70B
A 4090 is much faster than a 3090 at prefill, but decode barely moves: its bandwidth is only ≈8% higher. For local models, memory and bandwidth are the specs that matter.
One pass, all tokens together
The
capital
of
France
is
…
+1,995 more
X
2,000 × 4,096
×
W
4,096 × 4,096 · fetched once from memory
=
out
2,000 × 4,096
One weight, 2,000 uses: the tensor cores, not memory, set the pace.
32 layers ↑
wave · K,V left behind
RooflineB200 · BF16
FLOPs per byte read →
ridge ≈281
speed ↑
prefill · 2k tokens
decode · 1 chat
Prefill sits on the flat roof: compute-bound.
KV cache writtenLlama 3 8B · BF16
Every token leaves a key and value in every layer: 2,000 × 128 KB ≈ 262 MB. Decode reads it back on every step.
Chunked prefill
a 100k-token prompt is cut into chunks that share steps with other chats' decode, so nobody's reply freezes while it's read
chunk 1
chunk 2
chunk 3
chunk 4
chunk 5
blue = a slice of the long prompt · green = everyone else's decode
1
2
3
4
5
≈32 TFLOP
2 × 8B × 2K TOKENS
≈2,000
FLOPS PER BYTE FETCHED
≈15–30 ms
ON ONE B200 · ROUGH
length²
ATTENTION COST, LONG PROMPTS
Prefill is the reading half: it sets time to first token, and it's the half that loves raw FLOPs (and lower precision like FP8).
What fits in 32 GBweights + KV cache + a little working space
0
32 GB
8B · BF16
weights ≈16 GB
fits · lots of room for long chats
8B · 4-bit
≈5 GB
fits · fast, small quality loss
32B · Q4_K_M
weights ≈19 GB
fits · the sweet spot for 32 GB
70B · Q4_K_M
weights ≈42 GB
doesn't fit · needs two cards or offloading
teal = weights · purple = KV cache for an ≈8k-token chat · red = over the limit
Speed ceiling1,792 GB/s ÷ bytes per token
8B · 4-bit
≈360 tok/s
8B · BF16
≈110 tok/s
32B · Q4_K_M
≈90 tok/s
Each token reads every weight once, so halve the bytes and you double the ceiling. Real speeds land below it.
One user, whole GPUa chat over two minutes
GPU busy
you
ask
read reply… type
ask again
think
ask
Dark blue = prefill, green = decode, dashed = idle. The GPU waits on you most of the time, and when it works it's batch 1: far left on the roofline.
1
2
3
4
32 GB
GDDR7 ON THE CARD
1,792 GB/s
MEMORY BANDWIDTH
≈90 tok/s
CEILING · 32B AT Q4
batch 1
MOST OF THE TIME
Laptops and phones run the same maths with less memory and bandwidth, so they use smaller models (≈1–8B) at 4-bit.
Dispatch: the token's vector goes to those 8 GPUs (all-to-all)
Each expert runs its small MLP
Combine: 8 answers come back, weighted, and are summed
Twice over NVLink per MoE layer, ≈60 layers, every step.
Everyone at onceone MoE layer · traffic between GPU pairs (256 pairs drawn)
darker = more tokens sent. Thousands of chats' tokens scatter to their experts, so traffic is spread over every link.
1
2
3
4
5
671 B
PARAMETERS IN TOTAL
37 B
USED PER TOKEN
8 of 256
EXPERTS PER LAYER
≈13.5 TB
HBM IN THE RACK
130 TB/s
NVLINK, WHOLE RACK
The rack acts like one giant GPU: 72 GPUs share one NVLink fabric, so experts can live anywhere in it.
32 blockssame design · own weights
residual stream ↓
block 1 (bold) → block 32 · each reads the stream and adds back
Roughly what each depth doesfor “is”, the last token
Early layers · roughly 1–8
grammar · nearby words
“of France” is a phrase; “is” needs a subject.
Middle layers
words combine into meaning
“capital of France” becomes one idea, carried on “is”.
Late layers · roughly 25–32
facts · the next word
capital of France → Paris. The last vector now points at “ Paris”.
A tendency found by interpretability research, not a rule: the jobs overlap and vary by model.
1
2
3
4
5
32
BLOCKS, ONE DESIGN
≈218 M
PARAMETERS PER BLOCK
≈7 B
IN ALL 32 BLOCKS
4,096
NUMBERS ON THE STREAM
Stacking the same block is the whole model. Depth is what lets it build from words to meaning to the answer, one small addition to the stream at a time.
1 · Final norm + unembed
last vector of “is”
4,096 numbers
Final norm + unembed
4,096 → 128,256
2 · Scores (logits)one per vocabulary entry · 48 of 128,256 drawn
“ Paris”
3 · Softmax → probabilitiesall 128,256 add up to 1
Paris
86%
the
4%
a
2%
located
1.5%
known
1.0%
+ 128,251 more, mostly near 0% · illustrative numbers
4 · The sampler picks one
Sampler
temperature 0.7 · top-p 0.9
“ Paris”
id 12366
Temperature
below 1 sharpens
Top-p 0.9
drop the long tail
Temperature 0
always the top one
same probabilities, different settings, different picks
1
2
3
4
5
128,256
SCORES, ONE PER TOKEN
≈525 M
UNEMBEDDING PARAMETERS
86%
FOR “ PARIS”
1 token
CHOSEN PER PASS
The model never outputs a word. It outputs a probability for every token in its vocabulary, and the sampler makes the choice: at temperature 0, always “ Paris”.
Four passeseach one adds a token
pass 1 · the whole prompt (prefill)
The
capital
of
France
is
32 blocks
Paris
pass 2 · only the newest token
The
capital
of
France
is
Paris
32 blocks
.
pass 3 · only the newest token
The
capital
of
France
is
Paris
.
32 blocks
It
pass 4 · only the newest token
The
capital
of
France
is
Paris
.
It
32 blocks
is
grey tokens aren't run again: their keys and values are kept (next screen)
One after another8B · BF16 · one B200 · batch 1
Time, one chat
Paris
.
It
is
home
to
each box ≈2 ms · none can start early
Each pass needs the token the last one picked, so they can't overlap. Speed is counted in tokens per second.
≈2 ms per pass
16 GB of weights ÷ 8 TB/s
≤ ≈500 tokens per second
one chat's ceiling on this GPU
The prompt's 5 tokens took one pass together. Every new token costs a pass of its own.
1
2
3
4
5
1 token
PER PASS
≈2 ms
ONE PASS · 8B, B200
≈500 tok/s
CEILING, ONE CHAT
in order
NO PASS CAN RUN AHEAD
Generation is a loop: run the model, pick a token, append it, run again. That's why a model's output speed is measured in tokens per second.
The cacheone K and one V per token, per layer
The
capital
of
France
is
Paris
.
It
layer 1
layer 32
↓ 32 layers
purple: saved and reused · gold: computed this pass
Memory for computeLlama 3 8B · BF16
128 KB per token
32 layers × 8 KV heads × 128 × 2 (K, V) × 2 bytes
One chat's cache, by length
1K tokens
128 MB
8K tokens
≈1 GB
32K tokens
≈4 GB
128K tokens
≈16 GB
the weights
16 GB, for every chat at once
At 128K tokens one chat's cache is as big as the whole model. Without it, every pass would redo every earlier token's K and V in all 32 layers.
1
2
3
4
128 KB
PER TOKEN
≈1 GB
ONE 8K-TOKEN CHAT
≈16 GB
AT 128K = THE WEIGHTS
1 column
ADDED PER TOKEN
Each new token computes only its own keys and values and reads everyone else's from the cache. It trades memory for compute, and it grows with every token.
Less memory to readfewer bytes per token
Quantisation
fewer bits per weight · 16 GB at BF16 → ≈4–5 GB at 4-bit
only a few experts run per token · ≈5% of weights read
More tokens per passmore out of each read
Speculative decoding
guess several tokens cheaply, check them all in one pass
the guesser: a draft model · EAGLE heads · multi-token prediction · n-gram lookup
Paris ✓
. ✓
It ✓
was ✗
one pass checks 4 guesses: 3 accepted, 1 fixed · 4 tokens for 1 read of the weights
Less wasted attention workmostly memory traffic too
FlashAttention
computes attention in tiles · the score grid never goes to HBM
Sliding-window attention
look back only a fixed number of tokens
Sparse attention
look at a chosen few earlier tokens, not all of them
Controlling the outputthe one group that isn't about speed
Constrained decoding
mask any token that would break the JSON or grammar
Sampling settings
temperature · top-p · how the pick is made
1
2
3
4
16 GB
READ PER TOKEN · 8B BF16
≈4–5 GB
SAME MODEL, 4-BIT
32 → 8
KV HEADS WITH GQA
≈1 FLOP
PER BYTE · DECODE, BATCH 1
Generating a token reads every weight and does about one multiply per byte, so the GPU waits on memory. Almost every trick here reads fewer bytes, or gets more tokens from each read.
hover readclick open← → previous / next stepesc zoom out