CPU, GPU AND RAM

SGLang on an RTX 4070: throughput, first output and cache exceptions

In this article
THE QUICK TAKE

Higher aggregate output delayed first output in this finite workload, and verified prefix reuse did not prevent every slow request.

Liangcheng Cao’s SGLang benchmark makes a familiar serving trade-off concrete: more simultaneous work increases total output while delaying each request’s first output. Its value is the published workload contract and preserved exceptions, rather than a claim that another GPU or application will behave identically. The experiment uses a small model on a local RTX workstation and measures the serving client’s observations.

Follow the finite workload

The pinned report identifies Qwen2.5-0.5B-Instruct, an RTX 4070 and SGLang 0.5.19 under WSL2. With concurrency rising from 1 to 8, output throughput rises from about 254 to 1548 tokens/s, while TTFT rises from about 17.8 to 68.0 ms. These figures belong to a fixed synthetic input and forced output length.

The client maintains a bounded number of active requests rather than replaying an independently specified production arrival process. Waiting for a client slot is outside request timing. This matters when translating latency: an application’s user can wait before submission as well as after it. The measured TTFT is therefore not a complete admission-to-answer service guarantee.

The streaming boundary is explicit

The actual client implementation parses server-sent events incrementally and watches cumulative completion-token counts. It records the first observed increase rather than assuming every transport chunk is a token. Duplicate final events do not create extra token timestamps.

The methodology distinguishes first output, the observed output interval and the terminal signal. Those are useful application-facing boundaries, but they do not expose individual GPU-kernel execution times. Several tokens arriving in one event are not assigned invented internal timestamps. Consequently a reported interval-per-token statistic should not be described as a complete trace of every generated token’s compute latency.

Reuse and repeats are not extra independent evidence

The study reports run-level summaries across repeated measured runs, rather than pooling requests to pretend there were more experimental repetitions. It also discloses that baseline points in the prompt- and output-length studies reuse observations from another server session. Those points remain the same observations even when plotted in several comparisons.

That disclosure affects the interpretation of smooth trends and confidence. Observed minimum-to-maximum ranges describe the available repeats; they are not confidence intervals for every future request. The repository’s public history is a sanitized edition with provenance mappings, not a complete original experiment timeline. None of these facts prevents using the measurements, but they should travel with the result.

A cache hit can coexist with a slow request

The cache experiment verifies a shared prefix of 1024 tokens. Its primary paired TTFT reduction is 57.84%, computed from block-level summaries, while an unexplained warm request takes about 4.19 seconds despite verified reuse. The observation is retained, and warm-up did not fully exercise that cached execution path.

This supports a qualified claim that reuse helped under the tested workload, not a promise that a cache hit always improves latency. It also does not establish a production hit rate or answer quality. For applying the case, use the benchmark-method guide to preserve timing boundaries and the stack-reproducibility guide to keep the exact runtime conditions. No server or GPU experiment was executed for this review.

Earn rental income from GPUs

Have idle GPUs or looking to fund AI infrastructure? Retrivium finds a rental platform, sets up the server and helps you assess income and costs with a pilot.

Explore GPU hosting
← All articles