paper-with-me

홈 › Papers

HCAttention: Extreme KV Cache Compression via Heterogeneous Attention Computing for LLMs

2025-07-26 · Dongquan Yang, Yifan Yang, Xiaotian Yu, Xianbiao Qi, Rong Xiao arxiv

Processing long-context inputs with large language models presents a significant challenge due to the enormous memory requirements of the Key-Value (KV) cache during inference. Existing KV cache compression methods exhibit noticeable performance degradation when memory is reduced by more than 85%. Additionally, strategies that leverage GPU-CPU collaboration for approximate attention remain underexplored in this setting. We propose HCAttention, a heterogeneous attention computation framework that integrates key quantization, value offloading, and dynamic KV eviction to enable efficient inference under extreme memory constraints. The method is compatible with existing transformer architectures and does not require model fine-tuning. Experimental results on the LongBench benchmark demonstrate that our approach preserves the accuracy of full-attention model while shrinking the KV cache memory footprint to 25% of its original size. Remarkably, it stays competitive with only 12.5% of the cache, setting a new state-of-the-art in LLM KV cache compression. To the best of our knowledge, HCAttention is the first to extend the Llama-3-8B model to process 4 million tokens on a single A100 GPU with 80GB memory.

📄 PDF Abstract BibTeX arXiv:2507.19823

Code (0)

등록된 구현이 없습니다.

Similar Papers 제목 키워드 기반

EMS: Adaptive Evict-then-Merge Strategy for Head-wise KV Cache Compression Based on Global-Local Importance

2024-12-11 · Yingxin Li, Ye Li, Yuan Meng, Xinzhu Ma 외

As large language models (LLMs) continue to advance, the demand for higher quality and faster processing of long contexts across various applications is growing. KV cache is widely adopted as it stores previously generat…

MosaicKV: Serving Long-Context LLM with Dynamic Two-D KV Cache Compression

2026-07-01 · Sheng Qiang, Ruiwei Chen, Yinpeng Wu, Jinyu Gu 외 arxiv

Long-context LLM services now sustain prompts with hundreds of thousands to millions of tokens, making the key-value (KV) cache a first-order serving cost. Because the cache grows linearly with context length, it can exh…

Homogeneous Keys, Heterogeneous Values: Exploiting Local KV Cache Asymmetry for Long-Context LLMs

2025-06-04 · Wanyun Cui, Mingwei Xu

Recent advances in Large Language Models (LLMs) have highlighted the critical importance of extending context length, yet the quadratic complexity of attention mechanisms poses significant challenges for efficient long-c…

X-EcoMLA: Upcycling Pre-Trained Attention into MLA for Efficient and Extreme KV Compression

2025-03-14 · Guihong Li, Mehdi Rezagholizadeh, Mingyu Yang, Vikram Appia 외

Multi-head latent attention (MLA) is designed to optimize KV cache memory through low-rank key-value joint compression. Rather than caching keys and values separately, MLA stores their compressed latent representations, …

GPU

HeteroCache: A Dynamic Retrieval Approach to Heterogeneous KV Cache Compression for Long-Context LLM Inference

2026-01-20 · Zhiyuan Shi, Qibo Qiu, Feng Xue, Zhonglin Jiang 외 arxiv

The linear memory growth of the KV cache poses a significant bottleneck for LLM inference in long-context tasks. Existing static compression methods often fail to preserve globally important information. Although recent …