Enabling KV Caching of Shared Prefix for Diffusion Language Models

Younghun Go, Jaehoon Han, Changyong Shin, Chuck Yoo, Gyeongsik Yang
5/26/2026
cs.LGcs.AI
diffusion-flow

No confident code implementation found for this paper.

Abstract

Key-value (KV) caching for shared prefixes is essential for high-throughput large language model (LLM) serving, but it faces critical challenges in emerging diffusion language models (DLMs). In DLMs, bidirectional attention means that updating any token dynamically alters the entire context and its corresponding KVs.

Show full abstract

Thus, existing caching techniques developed for LLMs, which assume that KVs remain invariant once computed, corrupt the shared prefix KVs. Our experiments show that applying these techniques to DLMs causes model accuracy to collapse to near zero. To unlock high-throughput DLM serving, we propose bidirectional prefix caching, BiCache, the first KV caching technique for shared prefixes in DLMs. BiCache is designed based on key observations from our comprehensive analysis: shared prefix KVs remain stable and reusable in shallow layers, while the depth of shallow layers depends on the fraction of shared prefix tokens in each request. Thus, BiCache dynamically identifies a safe layer depth for reusing shared prefix KVs and eliminates redundant computation. Evaluations demonstrate that BiCache significantly improves serving throughput by 36.3%-98.3% compared to existing techniques without accuracy collapse (only 0-1.8% difference).

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{go2026enabling,
  title  = {Enabling KV Caching of Shared Prefix for Diffusion Language Models},
  author = {Younghun Go and Jaehoon Han and Changyong Shin and Chuck Yoo and Gyeongsik Yang},
  year   = {2026},
  eprint = {2606.07571},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2606.07571v4}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2606.07571.svg)](https://codeofpaper.com/paper/2606.07571)

Discussion