D-LLM: A Token Adaptive Computing Resource Allocation Strategy for Large Language Models

Yikun Jiang, Huanyu Wang, Lei Xie, Han Zhao, Zhang Chao +2 more
2/3/2026

No official code found. Best implementation: Jyk-122/D-LLM (24 stars, last commit 2025-04-09).

Abstract

Large language models have shown an impressive societal impact owing to their excellent understanding and logical reasoning skills. However, such strong ability relies on a huge amount of computing resources, which makes it difficult to deploy LLMs on computing resource-constrained platforms. Currently, LLMs process each token equivalently, but we argue that not every word is equally important. Some words should not be allocated excessive computing resources, particularly for dispensable terms in simple questions. In this paper, we propose a novel dynamic inference paradigm for LLMs, namely D-LLMs, which adaptively allocate computing resources in token processing. We design a dynamic decision module for each transformer layer that decides whether a network unit should be executed or skipped. Moreover, we tackle the issue of adapting D-LLMs to real-world applications, specifically concerning the missing KV-cache when layers are skipped. To overcome this, we propose a simple yet effective eviction policy to exclude the skipped layers from subsequent attention calculations. The eviction policy not only enables D-LLMs to be compatible with prevalent applications but also reduces considerable storage resources. Experimentally, D-LLMs show superior performance, in terms of computational cost and KV storage utilization. It can reduce up to 45% computational cost and KV storage on Q&A, summarization, and math solving tasks, 50% on commonsense reasoning tasks.

DOISemantic Scholar

Code Implementations(1)

Jyk-122/D-LLMCommunity66%

[NeurIPS 2024] Implementation of paper - D-LLM: A Token Adaptive Computing Resource Allocation Strategy for Large Language Models

243Shell, PythonMay 22, 20241 years ago

Similar Papers

Cite this paper

@article{jiang2026dllm,
  title  = {D-LLM: A Token Adaptive Computing Resource Allocation Strategy for Large Language Models},
  author = {Yikun Jiang and Huanyu Wang and Lei Xie and Han Zhao and Zhang Chao and Hui Qian and John C. S. Lui},
  year   = {2026},
  doi    = {10.52202/079017-0055},
  url    = {https://doi.org/10.52202/079017-0055},
  journal = {NEURIPS 2024 2024}
}

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

Discussion