Manuscript Offprint

arXiv:2610.17948

HaloBlock: Faster and Better Decoding for Diffusion Large Language Models

Zhaohui Zheng, Chenhang He, Jinrui Zhang, Ming-Ming Cheng, Lei Zhang

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

Zhaohui Zheng 1^{1} Chenhang He 1^{1} Jinrui Zhang 1^{1} Ming-Ming Cheng 2^{2} Lei Zhang †1^{\dagger 1}

1^{1} The Hong Kong Polytechnic University 2^{2} College of Computer Science, Nankai University

†^{\dagger} Corresponding author (cslzhang@comp.polyu.edu.hk).

Code

Abstract. Diffusion large language models (dLLMs) have attracted increasing research attention due to their bidirectional attention and arbitrary order decoding. However, there are two issues in dLLMs inference: the decoding difficulty is dominated by the tokens on the right side of the block, and the block-wise decoding inherently suffers from boundary contextual discontinuity. To tackle these limitations, we propose HaloBlock, a difficulty-aware adaptive halo mechanism for dLLM inference. We first leverage bidirectional cumulative entropy to characterize block decoding difficulty. Then, based on the bidirectional decoding difficulty, we adaptively allocate bidirectional halo regions on both sides of each block to mitigate boundary contextual discontinuity. The difficulty-aware design of HaloBlock smooths cross-block context propagation and lowers decoding difficulty for hard tokens, yielding better generation quality and faster convergence. Evaluated on LLaDA-8B-Instruct, Dream-7B-Instruct and LLaDA-1.5 across mathematical reasoning and code generation benchmarks, HaloBlock demonstrates consistent accuracy improvements and higher inference efficiency. Source codes are publicly available at https://github.com/PolyU-VCLab/HaloBlock.

KEYWORDS: Diffusion Large Language Models, PolyU VCLab

1 Introduction

Diffusion large language models (dLLMs) [1–3] have recently emerged as a promising alternative to the classic autoregressive (AR) LLMs, attracting rapidly growing research attention due to their parallelism. Equipped with inherent bidirectional attention and arbitrary-order decoding, dLLMs exhibit remarkable performance on long-range understanding and controllable editing tasks [4, 5]. Despite their architectural advantages, dLLMs suffer from substantially high inference overhead and the convergence difficulty in decoding text. Pioneering works [6, 7] have established block diffusion for semi-autoregressive decoding and key-value (KV) cache for inference acceleration, both of which have become the standard components in modern dLLM inference.

While block-wise decoding successfully alleviates the difficulty of global decoding, it introduces new challenges. The first is the inherent imbalanced difficulty in intra-block decoding. Fig. 1(a) shows the sawtooth-shaped variation in per-token NFE across token index. The left-side tokens receive stronger support from preceding context, which significantly reduces their decoding difficulty, whereas tokens on the right benefit far less from contextual cues and thus face substantially higher decoding difficulty (a failure example is shown in Fig. 1(b)). This position-dependent convergence heterogeneity is broadly consistent with the observations in adaptive parallel decoding literature [8, 9], but its intra-block form in block-wise dLLM inference has not been identified or formalized. Furthermore, as the total forward passes per block are dictated by the hardest tokens, this uneven difficulty distribution becomes a non-trivial issue on inference efficiency. We refer to this imbalanced difficulty in intra-block decoding as left-dominance effect. Second, a less discussed issue is the contextual discontinuity at block boundaries. This discontinuity arises primarily from the asynchronized KV cache update across blocks, a fundamental limitation of block-wise decoding designs [7]. During intra-block

Visual Computing Lab · The Hong Kong Polytechnic University

1 / 17

VC

Figure

(a) Token-wise NFE

Prompt: Becky bought 20 apples for 45 cents each and received a $1 discount. Kelly bought 20 apples for 50 cents each and received a 10 percent discount. How much more did Kelly pay than Becky?

Figure

Answer: First, calculate the total cost for Becky's apples before the discount:\n20 apples * 45 cents/apple = 90\n\nythenreceiveda90\n\ny then received a1 discount, so her final cost is:\n90−90 -1 = 89\n\nNext,calculatethetotalcostforKelly′sapplesbeforethediscount:\n20apples∗50cents/apple=89\n\nNext, calculate the total cost for Kelly's apples before the discount:\n20 apples * 50 cents/apple =100\n\nKelly received a 10 percent discount, so her final cost is:\n100∗(1−0.10)=100 * (1 - 0.10) =100 * 0.90 = 90\n\nNow,findthedifferencebetweenKelly′sandBecky′sfinalcosts:\n90\n\nNow, find the difference between Kelly's and Becky's final costs:\n90 -89=89 = 1\n\n### 1

(b) Illustrative examples

Figure 1. Illustration of the inference for dLLMs using LLaDA-8B-Instruct. (a) Token-wise Number of Function Evaluations (NFE). (b) An example of mathematical reasoning. The reasoning errors are highlighted in red bold. We see the left-dominance effect in block-wise decoding. Zoom in for a better view.

decoding iterations, the KV cache outside the current block is held constant. This forces intra-block to interact with stale context and thus undermines cross-block semantic coherence.

To address the above challenges, we propose HaloBlock, a token-difficulty-aware decoding scheme for dLLMs. Specifically, we first employ bidirectional cumulative entropy as a token-level metric to represent the token decoding difficulty. Based on the estimated difficulty, we adaptively allocate halo regions to both ends of each decoding block. The left halo consists of already decoded tokens from preceding blocks, while the right halo is composed of masked placeholder tokens. With bidirectional attention, these halo regions effectively expand the receptive field of the current block and refresh the contextual information at boundaries, alleviating the boundary contextual discontinuity caused by asynchronous KV cache updates. As a result, HaloBlock retains sufficient contextual coverage for high-uncertainty regions, which eases the decoding difficulty and achieves faster decoding convergence. Our contributions are as follows:

  • We reveal the key structural limitations, i.e., left-dominance effect and boundary contextual discontinuity, in block-wise decoding of dLLMs.

  • We present HaloBlock, a training-free difficulty-aware decoding framework that adaptively allocates halos to each block, which effectively reduces the decoding difficulty and smooths the context generation at block boundaries.

  • Experiments on representative dLLM, including LLaDA-8B-Instruct, Dream-7B-Instruct, and LLaDA-1.5, verify the effectiveness of HaloBlock, which yields clear improvements in generation accuracy and even achieves a modest speedup in inference.

References (31)