Self-Decomposing Diffusion for Code Generation

Lize Shao, Zichen Xie, Zhizhen Chen, Zhe Zeng, Wenxi Wang
10/20/2026
cs.CL

No confident code implementation found for this paper.

Abstract

Diffusion language models (DLMs) are emerging as a promising paradigm for code generation, offering the potential for fast, parallel decoding. However, generating complex programs remains challenging, as their interdependent components must maintain consistent interfaces, data flows, and shared assumptions. Aggressive parallel decoding can compromise these dependencies and undermine program correctness, while conservative decoding sacrifices efficiency. To address this trade-off, we propose planning program decomposition before implementation to coordinate interdependent units during parallel generation. We introduce Self-Decomposing Diffusion for Code (SDDC), a novel framework that decomposes complex programs and implements their units in parallel, entirely through diffusion. SDDC first generates a contract specifying the program's decomposition and inter-unit dependencies, then uses it to guide coordinated parallel implementation. Across five benchmarks and two 7B diffusion backbones, SDDC substantially improves the accuracy--latency trade-off, raising pass@1 by up to 31.1 percentage points while decoding 7.5--13.7$\times$ faster than the base models, and outperforming a fine-tuning baseline by up to 23.5 points with lower latency.

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{shao2026selfdecomposing,
  title  = {Self-Decomposing Diffusion for Code Generation},
  author = {Lize Shao and Zichen Xie and Zhizhen Chen and Zhe Zeng and Wenxi Wang},
  year   = {2026},
  eprint = {2610.27600},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2610.27600v1}
}

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/2610.27600.svg)](https://codeofpaper.com/paper/2610.27600)

Discussion