Skip to content

Field Notes

How LLM Serving Works: From One Request to a GPU Cluster

31 min read
Jiong Zhang
Jiong Zhang

Head of AI Infra & Systems NOKIA

Benchmark Context

The editorial claim assessment records no quantitative performance or cost claims for this contribution.

Read the benchmark standard →

For people who know the Transformer but have never served one.

This is the machinery underneath LLM serving, for anyone who knows the Transformer but has never served one. The companion article it points to — which of these mechanisms to pick, and what each costs — runs as a four-part serial from late October. Every number below is recomputed from a stated illustrative configuration or attributed to the paper it came from; none of it is my own measurement.

You already know what a Transformer computes. You can explain attention, you know what a forward pass does, and given a checkpoint and a GPU you could generate text with it tonight.

Serving is what happens when that stops being the hard part.

The moment a second user shows up, questions appear that the model architecture has no opinion about. Who gets the GPU first? Where does one person’s half-finished conversation sit while somebody else’s request is running? What does “fast” even mean, when one user is waiting for a first word and another is watching words appear one at a time? A model answers none of this. A serving system does.

This article is a tour of that system, built for someone who knows the model and has never run one in production. We will follow two requests that arrive at the same instant: a short chat turn, and a 32,000-token document somebody wants summarised. They are about to have very different days, and the reasons why are the whole subject.

By the end you should be able to trace both of them through every stage of a real serving stack, say what each stage is deciding, and name the measurement that would tell you whether that stage is where your problem lives.

One thing this article deliberately does not do: tell you which design is better. Every mechanism here has a cost, and weighing those costs is a separate job that needs its own article — the companion piece does exactly that. Read this one first and that one will make sense. Read this one alone and it should still feel complete.

1. One request, all the way through

Before any detail, here is the whole machine.

Every box outside the GPU exists because requests have to share the GPU. Illustrative.

Follow the short chat turn. It leaves the user’s browser and hits a router, which decides which machine should handle it. That machine is a replica: one complete, loaded, ready-to-run copy of the model, together with the software that drives it. The request does not go straight onto the GPU. It lands in a queue, because the GPU is busy with other people. A scheduler eventually picks it up and folds it into a batch with whatever else is running. The batch executes on the GPU. A token comes out. Then — and this is the part that surprises people coming from model-land — the request goes back to the scheduler and does it all again for the next token, and the next, hundreds of times.

That loop is the single most important thing on the diagram. A request is not one trip through the system. It is one trip to produce the first token, and then a long series of much smaller trips, one per token after that.

Notice how much of the picture has nothing to do with matrix multiplication. Routing, queueing, admission, batching, memory bookkeeping — none of it appears anywhere in the model definition, and all of it exists for exactly one reason: the model is expensive and many people want it at once. A serving system is the machinery of sharing.

Three resources get contested in that sharing, and the rest of this article tracks all three:

  • Compute — what the GPU actually does.
  • Memory — what each in-flight request leaves sitting in GPU memory while it runs.
  • Time — including, importantly, all the time nobody is computing anything on your behalf.

Most engineers new to serving assume the third is a rounding error. It usually is not.

2. What a request actually does, and what it leaves behind

Generating an answer is not one forward pass. It is a forward pass over the prompt, and then one more forward pass per output token.

The same operators, in two shapes. The phase names are the vocabulary the rest of the stack is built on.

The first pass is prefill. It takes the whole prompt at once, runs it through the model, and produces the first output token. For the document request, this is a single enormous pass over 32,000-odd tokens.

Every pass after that is decode. Each one takes the single token just produced, runs it through the model, and produces one more. If the answer is 512 tokens long, that is one prefill plus 511 decode passes. Decode is sequential by nature: the model cannot produce token 200 without knowing token 199, because token 199 is part of its input.

This is the first thing that makes serving strange. The expensive-looking part — grinding through a 32,000-token prompt — is one pass. The cheap-looking part — emitting a few hundred short tokens — is hundreds of passes, and typically dominates the wall clock.

The state that changes everything

Attention at step t needs the keys and values of every earlier token. Recomputing them from scratch on every step would mean re-running the entire prompt for every single output token, which is quadratic and absurd. So serving systems do the obvious thing: compute each token’s keys and values once, and keep them.

That store is the KV cache, and it is the most consequential object in the stack. It converts a compute problem into a memory problem, and memory does not compress under pressure.

Two properties matter enormously and neither is obvious from the model code. First, the KV cache is per request — every concurrent user has their own, and two users can share only the stretch where their text is identical, which in practice means a common opening rather than a whole conversation. Second, it grows with context length, linearly, every single token, and it is not released until the request finishes.

Put numbers on it, for a 70B-class model in BF16 spread across four 80 GB cards (the full configuration is in Appendix B; everything here is recomputed from it, not measured):

The weights are fixed overhead. What is left over is the only thing that serves concurrency.

Each token costs about 320 KiB of KV. After the weights and working overhead are accounted for, roughly 159 GB is left as the KV pool. The short chat turn needs a fraction of a gigabyte, so hundreds of them fit side by side. The document request needs nearly 11 GB, so about 14 of them fill the entire machine.

Fourteen. Same hardware, same model, same software — a workload change alone moved the ceiling by a factor of nearly fifty.

This is also why how that pool is managed turns out to matter as much as how big it is. Early serving systems reserved each request a contiguous block sized to its maximum possible length; measurements on those systems found only 20.4% to 38.2% of KV memory was holding real token state, with the rest lost to reservation and fragmentation [2]. We will come back to what fixed that in section 5 (What an inference engine is for).

Key idea. A request is one prefill pass, which yields the first token, plus one decode pass for every token after it, and it parks a block of GPU memory for its entire lifetime that grows with every token it has seen. Capacity is therefore not a property of the GPU alone — it is a property of the GPU and the shape of your traffic together.

3. What people mean by “fast”

“The model is slow” is not a diagnosis, because a request has two completely different ways of feeling slow.

Two shapes of “slow”. They are different problems and they have different causes.

Time to first token (TTFT) is how long the user stares at nothing. It covers queueing, scheduling and the prefill pass. Inter-token latency — also called time per output token, or TPOT — is the gap between consecutive tokens once generation is under way. A stall here makes text stutter even though the first word was instant.

These separate cleanly, and keeping them separate is most of the skill. A long TTFT and a stuttering stream almost never have the same cause.

TTFT — what it measures: Queue + schedule + prefill, up to the first token; typically hurt by: Queueing under load; a long prompt; a cold replica

Inter-token latency (TPOT) — what it measures: The gap between consecutive output tokens; typically hurt by: Other work interrupting decode; a full KV pool; oversized batches

End-to-end latency — what it measures: Everything, until the last token; typically hurt by: Either of the above, plus simply a long answer

Throughput — what it measures: Tokens or requests completed per second, fleet-wide; typically hurt by: Small batches; idle GPUs; memory limits

Goodput — what it measures: Throughput counting only requests that met their target; typically hurt by: Everything above — this is the honest one

That last row deserves a pause, because it is the metric that separates people who have operated a serving system from people who have benchmarked one. A cluster can post magnificent throughput while failing nearly everyone, simply by admitting far more work than it can finish on time: the tokens all get produced eventually, and the users all leave. Goodput counts only the requests that actually arrived within their promised time [3]. It is throughput with the self-deception removed.

One more habit worth adopting immediately: look at distributions, not averages. Tail latency — the ninety-ninth percentile, the slowest one in a hundred — is what users actually notice and what your on-call rotation is actually paged for. An average can look excellent while one request in fifty times out, and the average will never tell you.

4. Why one model stresses a GPU in two different ways

Here is a fact that offends intuition: during decode, a very expensive GPU sits mostly idle at the small effective batch a single request implies, and adding more computing power to it would barely help. Batching, later in this section, is the move that reclaims it.

To see why, you need one idea about how GPUs work.

Arithmetic happens at the narrow end. Everything else is the cost of getting operands there.

A GPU’s arithmetic units cannot read model weights from main memory. Data has to be hauled from high-bandwidth memory (HBM) through progressively smaller and faster levels until it reaches registers. That haul, not the arithmetic, is usually the slow part. Modern attention kernels are built around this fact, restructuring the computation specifically to move fewer bytes rather than to do less maths [5].

So the question that decides performance is not “how many operations?” but the ratio between them: arithmetic intensity, the number of operations performed per byte moved. Plot achievable performance against it and you get the roofline [4], which is the frame the standard analyses of Transformer inference cost are built on [1].

The same model, the same card, two phases on opposite sides of the bend.

Below the bend, you are waiting for bytes and your arithmetic units idle. Above it, you are genuinely computing. On this card the bend — the ridge point — sits at 295 operations per byte.

Now place our two phases.

Prefill has thousands of tokens flowing through one set of weights, so a single read of those weights is amortised across all of them. Its intensity is high, it lands on the flat part, and it uses the GPU as advertised.

Decode is the opposite, and for a reason worth stating precisely. To produce one token for one user, the machine reads all the model weights — every one of them — and performs a tiny amount of arithmetic with each. On top of that, attention must re-read that user’s entire KV history to produce a single token, which lands near 8 operations per byte, roughly 37 times below the ridge. Decode is not slow because the GPU is weak. Decode is slow because the GPU spends its time fetching.

This is why batching exists

If reading the weights is the expensive part, and that read produces one token for one user, then the obvious move is to make it produce one token for many users. Read the weights once, apply them to thirty users’ current tokens, emit thirty tokens. The read is amortised thirty ways. This is batching, and on the memory-bound side of the roofline it is close to free throughput.

Which immediately raises a scheduling question. If batches are formed once and held until every member finishes, then short requests are trapped waiting for long ones, and their slots sit idle.

Same requests, same finishing times. Only the rule for who may occupy a slot has changed.

Continuous batching — deciding batch membership fresh on every iteration rather than once per batch — closes those gaps [8]. It is now standard, and it is the reason a modern engine’s scheduler runs on every single step.

There is one more lever, and it is a model-architecture decision that exists purely for serving. Since decode is bottlenecked on re-reading the KV cache, making the KV cache smaller makes decode faster. Multi-query attention shares a single key-value head across all query heads [6]; grouped-query attention is the middle ground, with several query heads sharing each KV head [7]. The configuration in this article uses 64 query heads against 8 KV heads — an eight-fold reduction in KV traffic and KV storage against giving every query head its own, chosen for exactly this reason.

Key idea. Prefill and decode run the same model but can stress different resources. Long-prompt prefill offers substantial weight reuse, while small-batch dense decode often runs into memory-bandwidth limits. Batching improves weight reuse, but accommodating more concurrent requests also requires more KV storage.

5. What an inference engine is for

Sections 2 (What a request actually does, and what it leaves behind) and 4 (Why one model stresses a GPU in two different ways) set up a squeeze. Bigger batches make decode efficient. Bigger batches need more concurrent requests. More concurrent requests need more KV pool. The pool is fixed. And a long prefill dropped into the middle of all this monopolises the GPU while everyone else’s tokens stop.

The inference engine — vLLM, SGLang, TensorRT-LLM and their relatives — is the component that manages exactly this squeeze. It is worth understanding as four answers to four concrete problems.

Four mechanisms, one loop. None of them makes the model faster; they make the machine divisible.

Problem: slots idle while a batch waits for its slowest member. The answer is continuous batching, from the previous section — rebuild the batch every iteration [8].

Problem: KV memory is reserved for lengths that never materialise. The answer is to stop reserving. Paged KV splits each request’s cache into small fixed-size blocks handed out on demand, so a request holds only what it has actually used, and waste is bounded to less than one block per request [2]. The name is a deliberate echo of operating-system virtual memory, and the analogy is exact. Continuous batching already worked before paging existed; what paging changed is how many requests you can afford to keep in the batch at once.

Problem: a 32,000-token prefill freezes every other user’s token stream. The answer is chunked prefill: slice the long prompt into pieces and feed one piece per iteration alongside the running decodes, so decode never has to stop and wait [9]. Our document request stops being an event that happens to the other users and becomes a background task that shares with them.

Problem: the same prefix gets recomputed endlessly. Every request carrying the same system prompt does identical prefill work. A prefix cache keeps those computed keys and values and lets later requests start from where the shared part ended. Hit rates in reported benchmark suites span roughly 50% to 99% depending on workload [10] — which is a polite way of saying this mechanism is either transformative or irrelevant, and which one depends entirely on your traffic.

Put together, these turn the GPU from something a request occupies into something requests share by the step.

Key idea. An engine’s job is to divide one GPU’s time and memory among many requests. It does this by re-deciding what to run on every iteration, by handing out KV memory in small pieces instead of large reservations, and by chopping up any piece of work large enough to starve the others.

6. The replica is the unit of capacity

Now zoom out one level. In our illustrative configuration, the model’s roughly 141 GB of BF16 weights cannot fit on a single 80 GB GPU. We therefore distribute the model across four GPUs.

Two cuts through one model. Both hold a single copy of the weights between them.

Tensor parallelism cuts every layer across GPUs, so all of them work on the same token simultaneously and must exchange partial results inside each layer [11]. It makes a single request faster, and it demands a fast local interconnect, because that exchange happens at every layer of every pass. When this article says the model runs at TP=4, this is what it means.

Pipeline parallelism cuts between layers instead: each GPU owns a contiguous run of layers and hands activations to the next [12]. It communicates far less and tolerates slower links, but a stage has nothing to do until the stage before it is done, so it needs enough requests in flight to stay busy.

Here is the part that trips people up. Neither of these is the same as adding a replica. Both are ways to make one model fit and run. They do change what that one copy can hold — this configuration’s KV pool exists only because four cards are pooled — but there is still exactly one copy of the model. Serving more users than it can hold means running more replicas — and each replica is a full extra copy of the weights, paid for again.

So a replica is: one complete set of weights, one engine, and one KV pool. And it is the KV pool that fixes its ceiling. Recall section 2 (What a request actually does, and what it leaves behind) — on this configuration, roughly 159 GB of pool means about 690 concurrent short chats, or about 14 concurrent document requests. That ceiling is hard, and it is a storage ceiling rather than a latency promise: how many of those requests meet their targets is a separate question. Past it, requests do not run slower; they wait, or they get evicted and have their work redone.

This makes replicas the natural unit of capacity planning. “How much traffic can we serve?” resolves to “how many replicas, each holding how many of which kind of request?” — and because those two request types differ by a factor of nearly fifty, the answer depends more on your traffic mix than on your GPU count.

7. More than one replica, and the decision that creates

The moment there are two replicas, something genuinely new appears: a choice about where a request goes. That choice did not exist a section ago, and it is not a minor operational detail — it is a first-class performance problem.

Two cluster-level decisions, neither of which has a default right answer.

A router sits in front of the replicas. The naive job is load balancing: send work to whoever is least busy. But section 5 (What an inference engine is for) gave the router a reason to care about something else. If a request’s prefix is already cached on replica A, sending it there skips prefill for the cached part — all of it, if the whole prompt has been seen before.

And now the two goals fight. The replica with your cached prefix is popular precisely because it has the prefix, so it is busy. The idle replica is idle because nothing there matches. Cache affinity and load balancing pull in opposite directions, and the router has to commit before it can observe how either would have turned out [14]. There is no default answer; there is only a guess about which cost is larger for your traffic.

The second cluster-level idea follows from the phase split in section 4 (Why one model stresses a GPU in two different ways). If prefill and decode want different things from the hardware, why run them on the same hardware at all? Prefill/decode disaggregation puts them in separate pools: prefill instances do prompts, decode instances generate tokens, and the KV cache is handed across when a request moves from one to the other [3][15].

The gain is real. Our document request can no longer stall anyone’s token stream, because it is not on those GPUs. The costs are equally real and worth naming plainly: the KV cache now crosses a network — on the order of a gigabyte for a single request [3] — both pools need their own copy of the weights, and somebody must choose the ratio between prefill and decode capacity. Choose it badly and one pool idles while the other is the bottleneck, which is a failure mode a single mixed pool simply cannot have.

Key idea. Above one replica, placement becomes a performance decision. Sending a request to the replica that can execute it fastest and sending it to the replica that is least busy are different instructions, and a router that optimises either one in isolation will find the other one’s failure mode.

8. The ground moves, and promises break

Everything so far assumed a fleet that exists and stays put. Two more layers make that assumption honest.

Underneath the replicas is a substrate that supplies GPUs, and it moves. Starting a fresh replica is not instant: the container image has to be pulled, the runtime initialised, and every byte of weights fetched and loaded — 141 GB of them on this configuration. Measurements on a production serverless platform, running a model small enough to fit on a single card, still report time-to-first-token above 40 seconds on a cold instance, against roughly 30 milliseconds per token once warm [13]. A model the size of ours has far more to move, but that figure comes from a different model on a different platform, so read it as the scale of the gap rather than a number to expect. That gap is the entire reason autoscaling an LLM service is harder than autoscaling a web service — by the time a new replica is ready, your traffic spike may have come and gone.

GPU supply can also be taken away. Cheap preemptible capacity can be reclaimed by the provider mid-request, which means the serving system needs a plan for losing a machine that is holding live KV state [16].

On top sits the contract: what the service actually promised. An SLO turns a vague “should be fast” into something checkable — say, first token within two seconds for 99% of requests. Once that exists, goodput from section 3 (What people mean by “fast”) becomes measurable, and so does failure [18].

And failure in a serving system has a specific shape worth knowing before you meet it. A study of 156 high-severity incidents on one hyperscale LLM serving platform found roughly 60% were rooted in the inference engine itself, with timeouts the single largest category within that [17]. Not the model. Not the hardware. The serving layer.

Timeouts deserve the last word, because they are where the stack bites back. A request that times out has already consumed prefill compute and KV memory, and it holds that memory until it is cleaned up. If the client then retries, the retry arrives at a system that is already over capacity, carrying the same prompt, needing the same pool. This is how an overloaded serving system goes from degraded to collapsed: not gradually, but through a retry storm that converts a latency problem into a capacity problem.

9. The whole stack on one page

Everything we have walked through sorts into six layers. They are a conceptual framework rather than a law of nature, but they are the coordinate system used across this series, and they are useful for one specific purpose: when something is wrong, they tell you where to look.

  • L0 Capacity — where GPUs come from, what they cost, whether they can be taken away.
  • L1 Substrate — how GPUs become running replicas: cold start, image pulls, device sharing.
  • L2 Engine — how one replica divides its time and memory: batching, KV blocks, chunked prefill.
  • L3 Replica — how a replica is composed: parallelism, and whether phases are split apart.
  • L4 Routing — which replica a request goes to, and whether it is admitted.
  • L5 Contract — what was promised, and what happens when it is not met.

That list reads bottom-up, which is not the order this article took. We started in the middle, at the engine, worked outward through the replica and routing, and only then went down to the substrate and up to the contract — because that is the order in which the mechanisms explain each other, not the order in which a stack is assembled. As a diagnostic, neither order matters much: start where the symptom points.

Every mechanism in this article has one home, and every layer has a symptom that points at it. Illustrative.

First token is slow, generation is fine — what it usually implicates: Queueing ahead of prefill, or a very long prompt; what to measure first: TTFT split into queue time and prefill time; layer: L4, L2

First token is fast, then the stream stutters — what it usually implicates: Decode being interrupted or starved; what to measure first: Inter-token latency distribution, not its mean; layer: L2

Fine when quiet, collapses under load — what it usually implicates: The KV pool is full; requests queue or get evicted; what to measure first: Concurrent requests against pool occupancy; layer: L2, L3

One replica hot, others idle — what it usually implicates: Routing is optimizing cache hits over balance; what to measure first: Per-replica queue depth alongside hit rate; layer: L4

Slow only just after scaling up — what it usually implicates: Cold start — weights are still loading; what to measure first: Time from replica start to first served token; layer: L1

Capacity disappears without warning — what it usually implicates: Instances were reclaimed; what to measure first: Preemption events against served load; layer: L0

Errors rather than slowness — what it usually implicates: Timeouts, and retries amplifying load; what to measure first: Error class breakdown and retry rate; layer: L5

The single most common mistake is to start at L2 because that is where the interesting machinery is. Start where the symptom points instead: the table gives a first place to look, not a diagnosis.

10. What you can do now

Go back to the two requests from the beginning — the short chat and the 32,000-token document, arriving together — and check yourself. Answers follow each question.

Why does the document request take so much longer to produce its first token? Its prefill is a single pass over 32,000 tokens, and it may also have queued behind other work. Both live inside TTFT, which is why TTFT has to be split into queue time and prefill time before it means anything.

Why does the document request slow down the chat user, even though they are different requests? They share a GPU. Before chunked prefill, a long prefill occupies the device and the chat user’s decode steps simply stop. The chat user experiences this as a stutter, not as a slow start.

Why can the machine hold hundreds of chats but only about fourteen documents? Because the KV cache grows linearly with context and is held for the request’s whole life. At 320 KiB per token, a 33,280-token request claims nearly 11 GB of a 159 GB pool.

If you add a second replica, what new problem have you bought? Placement. You now have to decide where each request goes, and cache affinity and load balancing will not agree.

Your dashboard shows record throughput and users are complaining. What is wrong? You are measuring throughput instead of goodput. The system is admitting more work than it can finish on time and completing it eventually rather than usefully.

If those felt answerable, you have what you need.

The obvious next question is the one this article kept refusing: given all these mechanisms, which should I actually use? Every one of them trades something. Chunked prefill protects decode and lengthens prefill. Disaggregation removes interference and adds a network transfer. Cache affinity saves computation and creates hot spots. Choosing among them means knowing which constraint is binding right now, and what becomes binding after you change it. That is the subject of the companion article, and you are now equipped to read it.

Appendix

Appendix A: Glossary

Admission control — Deciding whether a queued request may enter the running batch at all, rather than how fast it runs once there.

Arithmetic intensity — Operations performed per byte moved from memory. The number that decides whether you are compute-bound or memory-bound.

Batching — Running several requests through the model together so one read of the weights serves all of them.

Chunked prefill — Splitting a long prompt across several iterations so it shares the GPU with ongoing decode instead of blocking it.

Cold start — The delay between deciding to run a new replica and that replica serving traffic, dominated by fetching and loading weights.

Cache affinity — Routing a request to the replica that already holds its cached prefix, trading load balance for saved prefill.

Compute-bound — Limited by arithmetic throughput rather than memory traffic. Prefill is normally here.

Continuous batching — Recomputing batch membership every iteration, so finished requests leave and waiting ones join immediately.

Decode — The phase producing every token after the first, one forward pass per token.

Disaggregation (prefill/decode) — Running prefill and decode on separate pools of GPUs, transferring the KV cache between them.

End-to-end latency — Total time from request arrival to the final token.

Engine — The software on a replica that schedules requests, manages KV memory and drives the GPU. vLLM and SGLang are engines.

Goodput — Throughput counting only requests that met their latency target. The metric that does not flatter an overloaded system.

Grouped-query attention (GQA) — Several query heads sharing one key-value head, cutting KV size and the bytes decode must re-read.

HBM — The GPU’s main memory. Large, fast by normal standards, and still the bottleneck during decode.

Inter-token latency (TPOT) — The gap between consecutive output tokens once generation has started.

KV cache — Stored keys and values for tokens already processed, kept so attention need not recompute them. Per request, grows with context, freed only at the end.

KV pool — The GPU memory left for KV cache after weights and overhead. It sets a replica’s concurrency ceiling.

Load balancing — Distributing requests to keep replicas evenly busy.

Memory-bound — Limited by memory traffic rather than arithmetic. Decode is normally here.

Multi-query attention (MQA) — One key-value head shared by all query heads; the most aggressive form of KV reduction.

Paged KV — Storing the KV cache in small fixed-size blocks allocated on demand instead of one reservation per request.

Pipeline parallelism — Splitting a model into consecutive stages of whole layers across GPUs, communicating only at stage boundaries.

Preemption — Losing a GPU instance to the provider mid-flight, typically on cheaper reclaimable capacity.

Prefill — The first forward pass, over the whole prompt, producing the first output token and the prompt’s KV entries.

Prefix cache — Reusing the KV cache of a shared leading portion of text across requests, so common prompts are computed once.

Replica — One complete loaded copy of the model plus its engine and KV pool. The unit of serving capacity.

Ridge point — The arithmetic intensity at which a device stops being memory-bound and becomes compute-bound.

Router — The component choosing which replica serves each request.

Scheduler — The part of an engine deciding, every iteration, which requests run in the next batch.

SLO — A stated service objective, such as a first token within two seconds for 99% of requests.

Substrate — The layer turning raw GPUs into running replicas: images, device allocation, sharing, startup.

Tail latency — High-percentile latency, such as P99. What users notice and averages conceal.

Tensor parallelism — Splitting every layer across GPUs so they compute one token together, exchanging partial results within each layer.

Throughput — Work completed per unit time, regardless of whether it was completed on time.

TTFT — Time to first token: queueing plus scheduling plus prefill.

Appendix B: The input card

Every number in the body is recomputed from these assumptions. They are illustrative assumptions, not measurements — a plausible configuration chosen so the arithmetic is reproducible, not a system anybody benchmarked.

Model — 70B-class dense, BF16

Layers — 80

Query heads / KV heads — 64 / 8 (GQA)

Head dimension — 128

Cards — 4, at 80 GB each, TP=4

Peak compute / HBM bandwidth — 989 TFLOP/s BF16 dense / 3.35 TB/s per card (H100 SXM5 datasheet)

Per-card framework overhead — 5 GB

Short request — 700 tokens (500 in, 200 out)

Long request — 33,280 tokens (32,768 in, 512 out)

From which: KV per token is 320 KiB; weights are 141 GB total, about 35.25 GB per card; the KV pool is about 159 GB; concurrency is about 690 short requests or about 14 long ones; the context ratio is 47.5; the ridge point is 295 FLOP/byte (989 TFLOP/s over 3.35 TB/s) and KV attention under 8:1 GQA sits near 8 FLOP/byte, a gap of about 37.

Both request sizes count prompt plus output, because the KV cache holds both. The body rounds the long prompt to 32,000 when describing it in prose, and quotes the full 33,280 whenever the pool is being divided up.

The same card drives the companion article, and a single check recomputes every one of these numbers from the assumptions above rather than trusting the text.

Appendix C: Where this comes from

This article makes no claim to novelty. It is an explanation, and it follows three rules so the explaining stays honest.

Mechanism claims cite either a deeply read paper or a declared anchor. The companion article rests on a corpus of 172 works, of which 15 were read end to end. That is a different frame from the 127-work impact selection behind the journey article, so the two counts do not compare. Mechanism-level statements here draw on those 15, or on a short list of classic works outside that corpus which a serving primer cannot avoid: continuous batching, IO-aware attention kernels, KV-head reduction, model parallelism and the roofline are anchored explicitly.

No source is quoted. Every mechanism is restated in plain language and attributed. Anchors in particular are cite-only, because their full text is not held locally and a quote that cannot be checked against its source has no business appearing in an article about being careful.

Numbers are labelled by kind. Numbers taken from a paper are attributed to it. Numbers from the input card are recomputed, and are illustrative assumptions rather than measurements. Nothing here was measured by me.

Appendix D: References

Unmarked entries were read end to end for the companion article and are part of its 172-work corpus. Entries marked Anchor sit outside that corpus and are cited as background only.

  1. Pope et al., Efficiently Scaling Transformer Inference, arXiv:2211.05102, 2022. Anchor.
  2. Kwon et al., Efficient Memory Management for Large Language Model Serving with PagedAttention, SOSP, 2023.
  3. Zhong et al., DistServe: Disaggregating Prefill and Decoding for Goodput-optimized Large Language Model Serving, 2024.
  4. Williams, Waterman and Patterson, Roofline: An Insightful Visual Performance Model for Multicore Architectures, CACM 52(4), 2009. Anchor.
  5. Dao et al., FlashAttention: Fast and Memory-Efficient Exact Attention with IO-Awareness, arXiv:2205.14135, 2022. Anchor.
  6. Shazeer, Fast Transformer Decoding: One Write-Head is All You Need, arXiv:1911.02150, 2019. Anchor.
  7. Ainslie et al., GQA: Training Generalized Multi-Query Transformer Models from Multi-Head Checkpoints, EMNLP, 2023. Anchor.
  8. Yu et al., Orca: A Distributed Serving System for Transformer-Based Generative Models, OSDI, 2022. Anchor.
  9. Agrawal et al., Taming Throughput-Latency Tradeoff in LLM Inference with Sarathi-Serve, 2024.
  10. Zheng et al., SGLang: Efficient Execution of Structured Language Model Programs, 2023.
  11. Shoeybi et al., Megatron-LM: Training Multi-Billion Parameter Language Models Using Model Parallelism, arXiv:1909.08053, 2019. Anchor.
  12. Huang et al., GPipe: Efficient Training of Giant Neural Networks using Pipeline Parallelism, NeurIPS, 2019. Anchor.
  13. Lou et al., HydraServe: Minimizing Cold Start Latency for Serverless LLM Serving in Public Clouds, 2025.
  14. Yuan et al., DualMap: Enabling Both Cache Affinity and Load Balancing for Distributed LLM Serving, 2026.
  15. Patel et al., Splitwise: Efficient generative LLM inference using phase splitting, arXiv:2311.18677, 2023. Anchor.
  16. Miao et al., SpotServe: Serving Generative Large Language Models on Preemptible Instances, 2023.
  17. Ranganathan et al., Enhancing Reliability in AI Inference Services: An Empirical Study on Real Production Incidents, 2025.
  18. Lysensten et al., SLO-Guard: Crash-Aware, Budget-Consistent Autotuning for SLO-Constrained LLM Serving, 2026.