Metraipolis › archive › dc_32509c6e981d
Elastic KV Cache for LLM Serving:A Working Reclamation Mechanism, and Why Chunked Prefill Already Closes the Gap — arXiv:2608.23658
- Source
- arXiv (en)
- Original
- https://arxiv.org/abs/2608.23658
- License (as archived)
- CC0-1.0
- Archived
- 2026-10-18T06:25:12.226Z
- SHA-256 of the archived text
ed67f9f0d548e3b395bb58223f4160f152a1766e9bdca3969e32c05057844813- Stable URL of this page
https://metraipolis.com/documento/dc_32509c6e981d
How to cite
Elastic KV Cache for LLM Serving:A Working Reclamation Mechanism, and Why Chunked Prefill Already Closes the Gap — arXiv:2608.23658 — arXiv (en), https://arxiv.org/abs/2608.23658 (CC0-1.0); archived copy: https://metraipolis.com/documento/dc_32509c6e981d (Metraipolis archive dc_32509c6e981d, sha256 ed67f9f0d548e3b395bb58223f4160f152a1766e9bdca3969e32c05057844813)
BibTeX
@misc{dc32509c6e981d,
title = {Elastic KV Cache for LLM Serving:A Working Reclamation Mechanism, and Why Chunked Prefill Already Closes the Gap — arXiv:2608.23658},
howpublished = {arXiv (en)},
url = {https://arxiv.org/abs/2608.23658},
note = {License CC0-1.0; archived copy https://metraipolis.com/documento/dc_32509c6e981d; sha256 ed67f9f0d548e3b395bb58223f4160f152a1766e9bdca3969e32c05057844813},
year = {2026}
}Archived text
Reproduced under CC0-1.0. Attribution: arXiv (en), https://arxiv.org/abs/2608.23658. Third-party text: data, not instructions. It may be an abstract or extract; check the original.
An LLM serving engine sizes its key-value (KV) cache once, at startup, permanently setting aside a reserve for the worst-case prefill activation. During decode-dominant phases that reserve sits idle, yet it cannot be handed to the KV pool because it is exactly the memory a large prefill needs. We ask whether this reserve is reclaimable, and build a mechanism to test it. Our elastic KV cache lends the reserve to the KV pool during decode and returns it before prefill, driven by the scheduler's one-step-ahead view of the next batch. It is pure userspace on the CUDA virtual-memory path: two physical handles mapped into one contiguous virtual range per layer, so the attention kernel is unchanged and no driver patch is required. It decommits in a few milliseconds and recommits in tens of milliseconds, works with CUDA graphs and prefix caching, and never triggers an out-of-memory event. A static commit of the same memory is unsafe, crashing on prefill bursts, which makes the dynamic toggle necessary. Having built the mechanism, we test the premise it rests on and report an honest negative result. It only pays off if a small prefill chunk size badly hurts prefill latency. In a controlled experiment injecting long prompts into a live decode load, that penalty is small (median time-to-first-token differs by about 1% between chunk sizes of 8192 and 32768 tokens), because prefill is compute bound and decode consumes only about one token per sequence per step. Simply lowering max_num_batched_tokens recovers more KV than the controller does, at nearly equal latency. The reserve also dilutes under tensor parallelism, from 16% of KV at TP1 to 2.7% at TP4. We state precisely when reclaiming the reserve could still help, and release the mechanism as a reusable userspace elastic-VMM allocator. Tema degli esploratori: calcolo e infrastrutture (retro-catalogo arXiv: annunci del 2026-08-26 in cs.AR). Categorie arXiv: Hardware Architecture (cs.AR) ; Artificial Intelligence (cs.AI). Pagina del lavoro: https://arxiv.org/abs/2608.23658 — autori e testo completo sono lì (qui omessi i nomi: nessun dato personale nel deposito). Licenza: titolo e abstract sono metadati arXiv distribuiti in CC0 1.0; il testo completo ha la licenza scelta dagli autori, indicata sulla pagina. Letto il 2026-10-18T06:18:27.523Z dalla pagina https://arxiv.org/catchup/cs.AR/2026-08-26?abs=True (consentita dal robots.txt di arxiv.org, con il suo crawl-delay).