arXiv:2611.05991cs.DCNov 2026

Manuscript Offprint

arXiv:2611.05991

A Controlled Experimental Evaluation of Configuration and Cache Architecture in LLM Serving Engines

Muhammad Faizan Anwar, Sina Keshvadi

MUHAMMAD FAIZAN ANWAR, Thompson Rivers University, Canada

SINA KESHVADI, Thompson Rivers University, Canada

Multi-agent LLM applications repeat most of their prompt tokens across requests, and serving engines reuse the cached state of shared prefixes. vLLM and SGLang reuse it at different granularities, and benchmarks of their default deployments report large performance gaps, usually credited to the cache. Such comparisons rarely control for other configuration differences. One of them, whether a long prompt is prefilled in chunks, is set by each engine's defaults from the hardware and the release, and it confounds the comparison. We built a reproducible testbed on Kubernetes and a seeded multi-agent workload generator, and compared the two engines under vendor defaults and with chunked prefill matched. SGLang's configuration is the same in both arms, which makes it an internal control across independently provisioned deployments. Under defaults, vLLM's median time to first token is up to 64× SGLang's. Matching one setting removes 78% of the capacity gap where that gap is largest and 30 to 67% of the latency gap. Near saturation the remaining latency gap reflects queue growth. A fluid queue model driven only by a 4.4% throughput shortfall reproduces it, and shows that such a gap scales with the length of the benchmark run. What survives matching is a tail-latency advantage of 2.4 to 6.4× at equal throughput, consistent with cache-aware ordering of waiting requests. We derive six recommendations for comparing serving engines.

Additional Key Words and Phrases: LLM serving, KV cache, prefix caching, chunked prefill, performance evaluation, benchmarking methodology

1 Introduction

Applications built on large language models increasingly run as multi-agent workflows. A planner decomposes a task, workers call tools and reason over retrieved documents, and an aggregator merges their answers. Every call in such a workflow repeats the same system instructions, tool schemas and shared context. Across five agent and long-context workloads, 85 to 97% of prompt tokens are shared with at least one other request [16], and in a production LLM-based search service over 94% of request tokens recur across users [9]. Recomputing that shared state wastes the resource that limits a serving GPU. The limit is memory, not arithmetic (Section 2).

Two widely used open-source serving engines reuse shared prompts in different ways. vLLM stores its key-value (KV) cache in fixed-size blocks and reuses a block when its contents match a cached one [8]. SGLang keeps cached tokens in a radix tree, RadixAttention, and reuses a shared prefix of any length [21]. Operators choose between such engines, and size GPU fleets around them, on the evidence of benchmarks. The SGLang authors report throughput up to 6.4× higher than contemporaneous systems [21], and several serving systems for agent workloads take finer-grained prefix reuse as their starting point [2, 12, 16].

We deployed both engines on one NVIDIA L4 GPU under their documented defaults and measured the gap such benchmarks lead one to expect. It is large. With 8,192-token prompts that share 90% of their tokens, vLLM's median time to first token (TTFT) is 64.1× SGLang's. Near vLLM's saturation point the median gap is 36.4×, and the highest throughput SGLang sustains is 1.94 requests per second against 1.40 for vLLM. A gap of this size invites a simple explanation: the finer-grained cache wins.

That explanation has not been tested. The engines' defaults differ in a second respect that has nothing to do with caching. A long prompt's prefill can run as one uninterrupted step, during which

Authors' Contact Information: Muhammad Faizan Anwar, Thompson Rivers University, Kamloops, British Columbia, Canada, T00804579@mytru.ca; Sina Keshvadi, Thompson Rivers University, Kamloops, British Columbia, Canada, skeshvadi@tru.ca.

every running request waits, or it can be split into chunks interleaved with ongoing decoding [1]. This is a scheduler setting. On our hardware SGLang chunks long prefills by default and vLLM does not. Neither engine is misconfigured: vLLM 0.6.3 enables chunked prefill only above a 32,768-token context, and SGLang 0.4.1 enables it on any GPU with less than 25 GB of memory. A comparison of default deployments therefore varies two factors at once. It cannot say which of them produced the gap.

The particular pairing has since changed upstream. vLLM's V1 engine enables chunked prefill by default wherever possible, where V0 enabled it conditionally [17]. The confound is a property of defaults rather than of one release. Defaults depend on the GPU and the configured context length, and they change between versions, so a benchmark that does not record the configuration each engine actually resolved cannot state which pairing it measured. Comparisons made against V0-era vLLM, including the baselines behind widely cited speedups, fall within the configuration space we study.

This paper separates the two factors in a controlled experiment and asks four questions:

RQ1 How large is the performance gap between the two engines under their default configurations, and where in the load range does it appear?

RQ2 How much of that gap remains once both engines use the same chunked-prefill configuration?

RQ3 Why do latency and capacity measures of the remaining gap disagree near saturation?

RQ4 Does the gap grow with the degree of prefix sharing, as an explanation based on cache architecture predicts?

We built a testbed on Google Kubernetes Engine and a workload generator that reproduces bursty arrivals, agent dependency graphs and exact prefix sharing from a seed. We ran each engine under its vendor defaults and again with chunked prefill matched at a 2,048-token budget. Only vLLM's setting changes between the two arms. SGLang resolves the same configuration in both arms, so it serves as an internal control. Rebuilt on an independently provisioned cluster days later, its latencies agree with the first deployment within 0.5 to 11.7%. We report 99 runs and 63,288 requests, analysed as comparisons paired by seed.

Figure 1 summarises the answer. Matching one setting removes 78% of the capacity gap at the load where that gap is largest, and 30 to 67% of the latency gap across conditions. At that load the matched engines differ in throughput by 4.6%, yet their median TTFT still differs by 12.3×. The small shortfall leaves vLLM just short of the offered load, and beyond that point TTFT measures the growth of a queue rather than the speed of an engine. A fluid queue model driven only by the throughput shortfall reproduces the effect, and shows that the gap grows with the length of the benchmark run. What survives matching is narrower. At equal throughput SGLang retains a 2.4 to 6.4× advantage at the 95th percentile of TTFT, consistent with its cache-aware ordering of waiting requests but not isolated to it. The gap also fails the prediction of RQ4: it narrows as sharing grows and reverses at high sharing, a pattern the scheduling difference predicts as well as the cache does.

This paper makes four contributions:

(1) A controlled decomposition. We separate the performance gap between vLLM and SGLang into the part due to chunked-prefill configuration and the part that remains, with one engine serving as an internal control (Sections 5 and 6).

(2) A methodological result. Near saturation, TTFT amplifies small differences in capacity nonlinearly, so latency must be reported together with sustained throughput (Sections 4 and 6).

(3) A located residual. We characterise what survives matching through per-request distributions, tails and run-to-run variability (Section 7).

Figure

Fig. 1. One setting accounts for most of the gap. Each row shows the engine gap under vendor defaults (filled) and with chunked prefill matched on both engines (hollow), for every condition measured in both configurations. Latency gaps are vLLM's TTFT divided by SGLang's; the capacity gap is SGLang's sustained throughput divided by vLLM's. The right column gives the fraction of each default gap, on a log scale, that matching removes. Geometric means of three seed-paired runs; * marks a paired t-test on log values with p<0.05p < 0.05.

(4) A reproducible apparatus. We release a testbed defined entirely in code, a seeded workload generator, and the per-run logs behind every number reported here (Section 3 and Appendix A).