LoomKV: Lossless KV Cache Compression from GPU Memory to SSD for LLM Serving
Zhu et al. in Inference & systems
Can lossless KV compression soften cache cliffs?
LoomKV: Lossless KV Cache Compression from GPU Memory to SSD for LLM Serving
Two separate KV limits can stall serving

Tiers retain prefixes; GPU pages limit concurrent requests. In Qwen3-30B-A3B, cutting tier capacity from 1200 to 1040 GB nearly halves goodput; a full pool queues despite cache hits.
One lossless code family, two places for KV

Tier mode compresses DRAM/SSD records, then restores exact KV bits before vLLM’s stock attention. Pool mode keeps GPU pages compressed for fused decode attention, whose different summation order can shift outputs at rounding precision.
A skewed byte distribution enables lossless coding

Qwen3-30B-A3B: top seven high-byte values cover ~94% on average. TileStream keeps low bytes verbatim; calibrated per-head 3+3-bit codes handle high bytes, with raw escapes. Across nine models, BF16 KV stores ~0.71 of raw size.
TileStream makes variable escapes parallel

Each 128-token record separates low, primary, secondary and raw streams. Grouped tile indexes let warps jump to escape bytes; normal loads write restored KV directly into scattered GPU pages.
Saved bytes count only when allocations shrink
A shorter record adds no capacity if each chunk still reserves its full raw size.
Tier mode uses exact-length DRAM objects; pool mode packs records into smaller shared-budget GPU pages. A worker defers length readback, letting the handler serve loads; rotating buffers overlap PCIe copies with GPU waits.
At the LMCache LRU cliff, tier mode lifts goodput
AgentX SSD-size table; Qwen3-30B-A3B, 64 sessions, 400 GB DRAM + 640 GB SSD, LMCache LRU, S=8. Goodput: engine TTFT ≤2 s, ITL ≤40 ms.
FragPack makes compressed GPU pages attention-ready
- 1
Order by consumer
FragPack permutes each K/V record into tensor-core thread fragments for coalesced reads.
- 2
Fit, then fuse
Records share a fixed GPU-page budget; overflow falls back to raw. Threads decompress straight into registers for attention, avoiding a full-KV write/read pass.
Fused attention is fast, with one shape exception

At full clock, fused BF16 decode takes 0.56–0.85× FA3 time across TP1 shapes. On TP2, it beats FlashInfer on 11 of 12 shapes; one request at 32K takes 1.23× FlashInfer time.
A larger GPU pool cuts queueing at 12 admissions
AgentX GPU-budget table; Qwen3-30B-A3B, 64 sessions, 54 GB/GPU, 400 GB DRAM + 2 TB SSD; hit rate 0.93–0.94. Net pool: 1.34× raw tokens.
Both cache levels were tight in an AI IDE trace
On Qwen3-30B-A3B with 128 GB DRAM + 512 GB SSD, raw LMCache averaged 21.9 s TTFT and 9.4 requests/min.
Open-loop, no FIFO proxy; TTFT includes vLLM queueing. Tier mode reached 11.6 requests/min and 3.9 s TTFT; pool mode, 15.0 and 1.8 s.
Where the evidence stops
Deployment scope
Tests cover one node at TP1/TP2 over PCIe; pipeline/expert parallelism, shared cache servers, MLA and FP4 remain untested.
Pool backend
Current pool mode supports BF16/FP8, 128-dimension heads, GQA groups up to 8, and 128-token blocks.
FP8 pool mode
Above 32K tokens at the power cap, FP8’s fused kernel takes 0.98–1.15× FlashInfer time; shared pages are sized for the hardest-to-compress layer.
Why it matters
- Lossless coding turns saved KV bytes into capacity without changing stored values.
- Choose tier mode for prefix eviction, pool mode for GPU queueing, and pool mode if both levels are short.
- The open question is how these results generalize beyond single-node TP1/TP2 tests and today’s pool-kernel shapes.
13 slides, 3 min
6 days ago