[KongchangAI]
Concept解码阶段 / 生成阶段

Decode

The second stage of large language model inference, in which tokens are generated sequentially after the first token is produced. At each step the model reads the accumulated KV Cache and predicts the next token; this stage determines TPOT (Time Per Output Token).

Core Facts

Timeline (last 90 days)

Nov 1

Local AI inference is divided into two stages, Pre-Fill (reading the prompt) and Decode (generating new tokens); Decode speed is measured by the tokens per second shown by LM Studio or Ollama, while the Pre-Fill stage can be much slower than Decode.

Unverified50%
Oct 31

In a distributed inference architecture, interfaces between components must explicitly pass all state (including rejection status), otherwise unchecked implicit assumptions can lead to data cross-contamination.

Unverified50%
Oct 31

During cross-machine handoff, Decode only asked whether the task was complete and did not check whether the task had been rejected, so after Prefill rejected an overlong prompt and replaced it with a placeholder, Decode still reserved and read pages according to the original plan, exceeding the amount actually sent.

Unverified50%
Oct 23

The inference framework uses a read-write separation architecture: the Prefill stage uses ordinary 8-card machines and the Decode stage uses large machines with 64 or 128 cards; the minimum configuration is 64 read cards and 64 write cards, 128 cards in total, and reads and writes can be deployed in different data centers connected by fiber optics.

Unverified50%
Oct 19

The Decode phase is memory-bandwidth-intensive, requiring model weights and the KV cache to be reloaded from HBM at each step, which determines inter-token latency (ITL).

Unverified50%
Oct 19

The prefill phase performs one forward computation over the entire input to produce KV caches for all positions, and is compute-bound; the decode phase generates tokens autoregressively one by one and is memory-bandwidth-bound.

Unverified50%
Oct 11

Disaggregated inference decouples the compute-intensive prefill stage from the memory-bandwidth-intensive decode stage, allocating them to separate hardware resource pools best suited to each for independent scaling.

Unverified50%
Oct 11

The prefill stage is highly parallel with large throughput but latency that grows with context length, while the decode stage generates tokens auto-regressively and its speed is limited by memory bandwidth.

Verified65%
Oct 5

The Prefill (prompt processing) phase is compute-intensive and relies on the GPU's parallel matrix computation capability; the Decode (generation) phase is memory-bandwidth-intensive and depends more on VRAM bandwidth.

Unverified60%
Oct 4

The prefill phase requires processing all input tokens at once and is a compute-intensive operation, whereas the decode phase generates only one token per step and is a memory-bandwidth-intensive operation.

Unverified50%

16 more timeline events

All Facts (20)

Verified

The Prefill phase is a compute-intensive operation, while the Decode phase is a memory-bandwidth-intensive operation.

90%
Verified

LLM inference is divided into two phases: the prefill phase (compute-intensive) and the decode phase (memory-bandwidth-intensive).

90%
Verified

The prefill stage of Transformer inference is primarily bottlenecked by compute (FLOPS), while the decode stage is primarily bottlenecked by memory bandwidth.

80%
Verified

P/D Disaggregation (Prefill/Decode Disaggregation) deploys the Prefill and Decode stages on different nodes to independently scale according to their respective computational characteristics, while simultaneously optimizing throughput and time to first token (TTFT).

75%
Verified

In the inference pipeline, the Prefill stage is compute-intensive and time-consuming, while the Decode stage performs token-by-token autoregressive generation and is sensitive to latency.

75%
Verified

The Prefill phase is a compute-intensive task with high demands on compute power; the Decode phase is a memory-access-intensive task that is sensitive to GPU memory bandwidth.

75%
Verified

During autoregressive decoding, each newly generated token requires reading the full KV Cache, making the decoding stage almost always memory-bandwidth-bound rather than compute-bound.

75%
Verified

TTFT is determined by the Prefill phase and is compute-bound, while TPOT corresponds to the Decode phase and is memory-bandwidth-bound.

70%
Verified

The prefill stage is highly parallel with large throughput but latency that grows with context length, while the decode stage generates tokens auto-regressively and its speed is limited by memory bandwidth.

65%
Verified

Large model inference is divided into two phases, Prefill and Decode; Prefill is a major component of Time to First Token (TTFT), while Decode corresponds to Time Per Output Token (TPOT).

65%
Verified

LLM inference requests are divided into two phases—Prefill (input) and Decode (output); Prefill can read inputs in parallel with extremely high throughput, while Decode requires token-by-token serial inference and occupies significantly more GPU time.

65%
Verified

The Prefill stage of LLM inference is compute-intensive with GPU utilization close to 100%, while the Decode stage is memory-bandwidth-intensive with the bottleneck being HBM VRAM bandwidth.

65%
Unverified

传统混合部署中Prefill阶段的大批量计算会阻塞Decode阶段的token生成,导致TTFT波动剧烈

85%
Unverified

Separating Prefill and Decode to run on different resources is the mainstream architecture for optimizing resource utilization in current large-scale inference services.

70%
Unverified

LLM inference during the decode phase is typically memory-bandwidth-bound rather than compute-bound, because token-by-token generation requires loading the entire model weights but has extremely low arithmetic intensity.

70%
Unverified

The Prefill (prompt processing) phase is compute-intensive and relies on the GPU's parallel matrix computation capability; the Decode (generation) phase is memory-bandwidth-intensive and depends more on VRAM bandwidth.

60%
Unverified

The decode phase is a memory-bandwidth-intensive operation, as generating each new token requires reading the KV Cache of all historical tokens from GPU memory.

60%
Unverified

During the Decode phase of large models, because each step depends on the result of the previous step and can only be executed serially, hardware utilization is typically below 10%.

60%
Unverified

Local AI inference is divided into two stages, Pre-Fill (reading the prompt) and Decode (generating new tokens); Decode speed is measured by the tokens per second shown by LM Studio or Ollama, while the Pre-Fill stage can be much slower than Decode.

50%
Unverified

In a distributed inference architecture, interfaces between components must explicitly pass all state (including rejection status), otherwise unchecked implicit assumptions can lead to data cross-contamination.

50%

Source Articles