FastServe: Iteration-Level Preemptive Scheduling for Large Language Model Inference
Bingyang Wu (PhD Student · School of Computer Science, Peking University), Yinmin Zhong (School of Computer Science, Peking University), Zili Zhang (School of Computer Science, Peking University), Shengyu Liu (School of Computer Science, Peking University), Fangyue Liu (School of Computer Science, Peking University), Yuanhang Sun (School of Computer Science, Peking University), Gang Huang (School of Computer Science, Peking University), Xuanzhe Liu (School of Computer Science, Peking University), Xin Jin (School of Computer Science, Peking University)
23rd USENIX Symposium on Networked Systems Design and Implementation (NSDI '26) · Day 1 · All Your Networks Are Belong to ML
Overview
Large language models (LLMs) power a rapidly growing ecosystem of interactive applications, from chatbots and coding assistants to automated compilers, leading to massive surges in production inference traffic. However, serving LLMs efficiently while meeting strict interactive latency Service Level Objectives (SLOs) remains a formidable systems challenge. Traditional LLM serving frameworks rely on request-level continuous batching, where requests run to completion once scheduled. This run-to-completion policy creates severe head-of-line blocking, as long-running inference jobs trap GPU compute and memory resources, forcing short, latency-sensitive requests to languish in queues.

Key moments
- 0:00 Introduction and background of LLM inference phases
- 2:00 KV cache memory challenges and head-of-line blocking
- 4:00 Overview of Faster and iteration-level preemptive scheduling
- 6:00 Skip-Job MLQ design to handle unknown output lengths
- 8:00 GPU memory overhead and preemption trade-offs
- 9:30 Priority KV cache swapping mechanism using host memory
- 10:30 Evaluation results on end-to-end performance and throughput
- 12:00 Evaluation of proactive KV cache swapping and conclusion
FastServe: Iteration-Level Preemptive Scheduling for Large Language Model Inference
Speakers: Bingyang Wu, Yinmin Zhong, Zili Zhang, Shengyu Liu, Fangyue Liu, Yuanhang Sun, Gang Huang, Xuanzhe Liu, Xin Jin (Peking University)
Conference: USENIX NSDI
YouTube: https://www.youtube.com/watch?v=DLDwwYnojKw
Overview
Large language models (LLMs) power a rapidly growing ecosystem of interactive applications, from chatbots and coding assistants to automated compilers, leading to massive surges in production inference traffic. However, serving LLMs efficiently while meeting strict interactive latency Service Level Objectives (SLOs) remains a formidable systems challenge. Traditional LLM serving frameworks rely on request-level continuous batching, where requests run to completion once scheduled. This run-to-completion policy creates severe head-of-line blocking, as long-running inference jobs trap GPU compute and memory resources, forcing short, latency-sensitive requests to languish in queues.
In this talk presented at USENIX NSDI, Bingyang Wu from Peking University introduces FastServe, a novel LLM serving system that implements iteration-level preemptive scheduling. By capitalizing on the natural autoregressive iteration boundary of LLM decoding, FastServe breaks the run-to-completion paradigm to dynamically preempt and schedule requests at a fine-grained level. To achieve this without incurring prohibitive performance and memory penalties, the system introduces two core innovations: Skip-Job MLQ (Multi-Level Feedback Queue), which leverages known input lengths to bypass inappropriate priority queues, and priority KV cache swapping, which proactively offloads and prefetches KV cache states between GPU and host memory while hiding transfer overheads behind ongoing GPU compute.
This work matters because queueing delay, rather than raw execution time, frequently dominates end-to-end latency under heavy production loads. By tackling head-of-line blocking and memory thrashing simultaneously, FastServe delivers up to a 6.1× throughput improvement over state-of-the-art systems like vLLM while maintaining strict user-facing latency SLOs.
Background
▶ Watch: Introduction and background of LLM inference phases (0:00)
The systems architecture of LLM inference is fundamentally split into two distinct operational phases: the prefill phase and the decoding phase. When a request arrives, the serving engine processes all input (prompt) tokens in a single, computationally dense iteration, populating the initial internal states. Subsequently, the decoding phase generates output tokens autoregressively, producing exactly one token per iteration. Each decoding iteration depends on the Key-Value (KV) cache generated by all preceding tokens, transforming the KV cache into both an indispensable performance optimization and a severe memory bottleneck. As sequence lengths expand, the KV cache consumes massive amounts of high-bandwidth GPU memory, strictly limiting concurrent request capacity.
To maximize hardware utilization, modern serving engines deploy request-level continuous batching. While this improves upon static batching by dynamically inserting new requests into running batches as slots free up, it preserves a strict run-to-completion discipline. Once a request enters execution, the scheduler commits to finishing it before releasing its batch slot.
This design introduces a critical pathology: head-of-line blocking. In real-world workloads like ShareGPT and Alpaca, output lengths vary by orders of magnitude. A long-output request scheduled ahead of dozens of short-output requests blocks the pipeline, causing queuing delays to explode. Under high system load, queueing latency vastly outweighs actual kernel execution time.
In traditional operating systems, scheduling dilemmas of this nature are resolved using Shortest Remaining Processing Time (SRPT) algorithms or Multi-Level Feedback Queues (MLQ). However, applying these classical policies to LLM inference breaks down due to two unique constraints:
- Unknown Job Sizes: While input length is known upon arrival, output length is completely unknown in advance, making direct SRPT calculation impossible.
- Memory Footprint: Preempting a request requires preserving or reconstructing its multi-gigabyte KV cache. Discarding the cache forces expensive recomputation, while naive memory swapping stalls the GPU on slow PCIe transfers.
Key Findings
▶ Watch: Overview of Faster and iteration-level preemptive scheduling (4:00)
- Throughput Gains: FastServe dramatically outperforms existing serving architectures. Compared to FastTransformer, FastServe increases system throughput by 31× to 74× under identical latency SLOs. Compared to vLLM, it achieves a 2× to 6.1× throughput improvement.
- Domination of Queueing Delay: Empirical analysis of production traces (ShareGPT and Alpaca) reveals that queueing delays dominate end-to-end latency as arrival rates climb. Optimizing execution kernels alone is insufficient; scheduling policies must explicitly minimize wait times.
- Efficacy of Skip-Job MLQ: The Skip-Job MLQ scheduling policy improves performance by up to 13.9× over fixed priority scheduling, 8.9× over First-Come-First-Served (FCFS), and 1.8× over naive MLQ by accurately estimating initial prefill iterations without requiring prior knowledge of output lengths.
- Proactive KV Cache Swapping: Proactive offloading and prefetching of KV caches between GPU and host memory yields a 2.7× throughput improvement over reactive recomputation and a 1.7× improvement over reactive swapping by hiding PCIe transfer latency behind active GPU execution kernels.
Technical Deep Dive
▶ Watch: GPU memory overhead and preemption trade-offs (8:00)
The architectural foundation of FastServe rests on two tightly integrated components: the Skip-Job MLQ scheduler and the priority KV cache swapping engine.
Skip-Job MLQ Scheduler
Classical MLQ architectures push all incoming jobs into the highest priority queue, demoting them if they exceed specific execution quotas. However, in LLMs, the initial prefill phase takes significantly longer than individual decoding iterations due to massive parallel matrix multiplications over prompt tokens. If an MLQ scheduler forces a prefill to run across multiple rigid time quanta, the system faces a punishing dilemma: either preempt mid-iteration—destroying intermediate tensor states and wasting GPU compute—or wait for the entire prefill to finish, reintroducing head-of-line blocking.
FastServe resolves this via Skip-Job MLQ. Using lightweight profiling based on input token counts, the system estimates the exact execution time of the first prefill iteration. Instead of blindly routing new jobs to the topmost queue, Skip-Job MLQ drops the request directly into the highest priority queue whose time quantum is large enough to accommodate its initial prefill execution. Subsequent decoding iterations are demoted progressively through lower queues based on runtime consumption, while background promotion policies prevent starvation. This approximates an SRPT oracle policy without requiring a priori knowledge of final output lengths.
Priority KV Cache Swapping
Preemptive scheduling inherently multiplies the active memory footprint because the system must retain KV caches for preempted jobs that are not currently executing on the GPU. Storing all preempted KV caches in limited GPU memory is infeasible, while naive reactive offloading creates massive PCIe bottlenecks on the critical execution path.
FastServe implements a priority KV cache swapping mechanism that expands the memory hierarchy to include host CPU memory. Rather than reacting to memory exhaustion when allocations fail, the scheduler operates proactively. By tracking scheduling decisions ahead of time, FastServe anticipates which jobs will be scheduled next and asynchronously prefetches their KV caches from host memory into GPU memory, while simultaneously offloading inactive KV caches of preempted jobs. Because these PCIe transfers are overlapped with ongoing GPU computation kernels, data transfer overhead is largely hidden from the critical path.
Experimental Setup & Results
▶ Watch: Priority KV cache swapping mechanism using host memory (9:30)
The evaluation benchmarks FastServe against baseline systems including vLLM and FastTransformer across multiple model scales and hardware configurations. Workloads are driven by request traces extracted from real-world interactive datasets, specifically ShareGPT and Alpaca, which exhibit heavy-tailed distributions in input-to-output length ratios.
- End-to-End Performance: Under high-load scenarios constrained by strict tail-latency SLOs, FastServe sustains significantly higher request arrival rates than baseline architectures. Against vLLM, FastServe achieves a 2× to 6.1× multiplier in maximum supported throughput. Against FastTransformer, throughput increases by 31× to 74×, driven heavily by the elimination of head-of-line blocking.
- Component-Level Ablations:
- Scheduling Policies: Comparing Skip-Job MLQ against FCFS, fixed priority, and naive MLQ demonstrates that Skip-Job MLQ improves performance by up to 13.9×. FCFS suffers severely from long-output blocking, while naive MLQ falters when prefill times vastly outstrip decoding iterations.
- Memory Management Strategies: Evaluating three memory handling schemes—full recomputation, reactive swapping, and proactive swapping—proves that proactive management is essential at scale. Reactive swapping incurs heavy latency penalties because transfer costs hit the critical path. Proactive swapping delivers a 2.7× throughput boost over recomputation and a 1.7× boost over reactive swapping by effectively overlapping PCIe transfers with tensor execution.
Practical Implications
▶ Watch: Evaluation of proactive KV cache swapping and conclusion (12:00)
For infrastructure teams and model deployers, FastServe demonstrates that LLM serving performance cannot be solved purely through kernel-level optimizations (such as FlashAttention or custom CUDA kernels) or simple continuous batching. As interactive applications scale, queueing dynamics dictate overall user experience. Adopting iteration-level preemption is crucial for multi-tenant environments where short, latency-critical queries (like autocomplete or chat prompts) mix with long-running batch jobs (like code generation or document summarization).
However, deployers must account for specific hardware and system tradeoffs:
- Host-GPU Interconnect Bandwidth: Proactive KV cache swapping relies heavily on high-speed PCIe bandwidth between the host CPU and GPU. Systems with constrained PCIe gen speeds or bottlenecks may experience reduced overlap efficiency.
- Memory Overhead: Maintaining host-side KV cache pools requires substantial system RAM, shifting memory pressure partially from VRAM to host DRAM.
- Complexity: Integrating iteration-level preemption requires invasive modifications to the serving engine’s execution loop and memory allocator, making adoption in rigid legacy inference stacks challenging.
Key Takeaways
- Head-of-Line Blocking is a Primary Bottleneck: In interactive LLM workloads, traditional run-to-completion batching causes queuing delays that dwarf actual execution times under heavy loads.
- Iteration-Level Preemption Works: Exploiting the natural autoregressive boundaries of LLM decoding allows serving engines to pause and resume jobs safely at the granularity of single tokens.
- Skip-Job MLQ Approximates SRPT: By using input-length profiling to bypass inadequate priority queues, Skip-Job MLQ successfully handles unknown output lengths without sacrificing scheduling precision.
- Proactive KV Cache Management Hides Transfer Costs: Extending KV cache storage to host CPU memory and overlapping proactive PCIe transfers with GPU compute prevents memory swapping from entering the critical execution path.
- Significant Throughput Multipliers: FastServe achieves up to a 6.1× throughput improvement over vLLM and up to 74× over FastTransformer on real-world datasets like ShareGPT and Alpaca.
About the Speaker(s)
Bingyang Wu is a fourth-year PhD student in the School of Computer Science at Peking University, advised by Professor Xin Jin. His research focuses on systems and networking for machine learning, with a specific emphasis on optimizing large language model inference efficiency, scheduling algorithms, and distributed systems infrastructure.
Reviews
- Simon Wisk (Open Source Developer & AI Tooling Expert) — MUST SEE ★★★★★
→ Top-rated talks at 23rd USENIX Symposium on Networked Systems Design and Implementation (NSDI '26)
All talks from 23rd USENIX Symposium on Networked Systems Design and Implementation (NSDI '26)