XKV: Personalized KV Cache Memory Reduction for Long-Context LLM Inference
On the map: Efficient LLM inference and serving → KV cache optimization
Abstract (arXiv)
Recently the generative Large Language Model (LLM) has achieved remarkable success in numerous applications. Notably its inference generates output tokens one-by-one, leading to many redundant computations. The widely-used KV-Cache framework makes a compromise between time and space complexities. However, caching data generates the increasingly growing memory demand, that can quickly exhaust the limited memory capacity of the modern accelerator like GPUs, particularly in long-context inference tasks. Existing studies reduce memory consumption by evicting some of cached data that have less important impact on inference accuracy. But the benefit in practice is far from ideal due to the static cache allocation across different LLM network layers. This paper observes that the layer-specific cached data have very different impacts on accuracy. We quantify this difference, and give experimental and theoretical validation. We accordingly make a formal analysis and shows that customizing the cache size for each layer in a personalized manner can yield a significant memory reduction, while still providing comparable accuracy. We simulate the cache allocation as a combinatorial optimization problem and give a global optimal solution. In particular, we devise a mini- and sampling-based inference over a lightweight variant of the LLM model, so as to quickly capture the difference and then feed it into the personalized algorithms. Extensive experiments on real-world datasets demonstrate that our proposals can reduce KV cache memory consumption by 61.6% on average, improve computational efficiency by 2.1x and then increase the throughput by up to 5.5x.
Key facts. Cited by 2 papers in the map (data through 7 Oct 2026). Placed in KV cache optimization, one of 12 directions in Efficient LLM inference and serving. Builds on 31 of its 37 references that are in the map. First posted on arXiv 8 Dec 2024.
Builds on
31 of 37 references.
Closest ancestors · 10
Same direction, newest first
- 2024Ada-KV: Optimizing KV Cache Eviction by Adaptive Budget Allocation for Efficient LLM Inference16 Jul
- 2024Model Tells You Where to Merge: Adaptive KV Cache Merging for LLMs on Long-Context Tasks11 Jul
- 2024Attention Score is not All You Need for Token Importance Indicator in KV Cache Reduction: Value Also Matters18 Jun
- 2024PyramidKV: Dynamic KV Cache Compression based on Pyramidal Information Funneling4 Jun
- 2024PyramidInfer: Pyramid KV Cache Compression for High-throughput LLM Inference21 May
- 2024SnapKV: LLM Knows What You are Looking for Before Generation22 Apr
- 2024GEAR: An Efficient KV Cache Compression Recipe for Near-Lossless Generative Inference of LLM8 Mar
- 2023Model Tells You What to Discard: Adaptive KV Cache Compression for LLMs3 Oct
- 2023H2O: Heavy-Hitter Oracle for Efficient Generative Inference of Large Language Models24 Jun
- 2023Scissorhands: Exploiting the Persistence of Importance Hypothesis for LLM KV Cache Compression at Test Time26 May
Other references · 21
- 2017Attention Is All You Needcited by 59,932
- 2023GPT-4 Technical Reportcited by 18,132
- 2024The Llama 3 Herd of Modelscited by 14,192
- 2023Lost in the Middle: How Language Models Use Long Contextscited by 3,383
- 2023Efficient Streaming Language Models with Attention Sinkscited by 2,115
- 2023Code Llama: Open Foundation Models for Codecited by 2,105
- 2023LongBench: A Bilingual, Multitask Benchmark for Long Context Understandingcited by 1,378
- 2024KIVI: A Tuning-Free Asymmetric 2bit Quantization for KV Cachecited by 604
- 2024DistServe: Disaggregating Prefill and Decoding for Goodput-optimized Large Language Model Servingcited by 595
- 2024KVQuant: Towards 10 Million Context Length LLM Inference with KV Cache Quantizationcited by 571
- 2023FlexGen: High-Throughput Generative Inference of Large Language Models with a Single GPUcited by 567
- 2024Taming Throughput-Latency Tradeoff in LLM Inference with Sarathi-Servecited by 507
9 more
- 2019Multi-News: a Large-Scale Multi-Document Summarization Dataset and Abstractive Hierarchical Modelcited by 431
- 2023LooGLE: Can Long-Context Language Models Understand Long Contexts?cited by 200
- 2024You Only Cache Once: Decoder-Decoder Architectures for Language Modelscited by 135
- 2024PQCache: Product Quantization-based KVCache for Long Context LLM Inferencecited by 93
- 2024Infinite-LLM: Efficient LLM Service for Long Context with DistAttention and Distributed KVCachecited by 71
- 2023BigTranslate: Augmenting Large Language Models with Multilingual Translation Capability over 100 Languagescited by 60
- 2024ALISA: Accelerating Large Language Model Inference via Sparsity-Aware KV Cachingcited by 48
- 2022Optimizing Tensor Programs on Flexible Storagecited by 9
- 2024Efficient Sparse Attention needs Adaptive Token Releasecited by 4
Built on by
Citing papers per year: 2025: 1; 2026: 1.
2 papers.
Similar, not cited
Close in wording, no citation either way
- 2026KV Cache Optimization Strategies for Scalable and Efficient LLM Inference
- 2025WindowKV: Task-Adaptive Group-Wise KV Cache Window Selection for Efficient LLM Inference
- 2025LMCache: An Efficient KV Cache Layer for Enterprise-Scale LLM Inference
- 2025BaKlaVa -- Budgeted Allocation of KV cache for Long-context Inference
- 2024MiniKV: Pushing the Limits of LLM Inference via 2-Bit Layer-Discriminative KV Cache
- 2026Comparative Characterization of KV Cache Management Strategies for LLM Inference
- 2025TailorKV: A Hybrid Framework for Long-Context Inference via Tailored KV Cache Optimization
- 2024Keep the Cost Down: A Review on Methods to Optimize LLM' s KV-Cache Consumption