The Curse of Depth in Large Language Models

Open Access
Authors
  • Yefeng Zheng
  • S. Liu
Publication date 2025
Host editors
  • D. Belgrave
  • C. Zhang
  • H. Lin
  • R. Pascanu
  • P. Koniusz
  • M. Ghassemi
  • N. Chen
Book title 39th Annual Conference on Neural Information Processing Systems (NeurIPS 2025)
Book subtitle 2-7 December 2025, San Diego, California, USA and 30 November-5 December 2025, Mexico City, Mexico
ISBN (electronic)
  • 9798331338275
Series Advances in Neural Information Processing Systems
Event 39th Annual Conference on Neural Information Processing Systems
Pages (from-to) 181014-181046
Publisher Neural Information Processing Systems Foundation
Organisations
  • Faculty of Science (FNWI) - Informatics Institute (IVI)
Abstract
In this paper, we re-introduce the Curse of Depth, a concept that re-introduces, explains, and addresses the recent observation in modern Large Language Models (LLMs) where deeper layers are much less effective than expected. We first confirm the wide existence of this phenomenon across the most popular families of LLMs, such as Llama, Mistral, DeepSeek, and Qwen. Our analysis, theoretically and empirically, identifies that the underlying reason for the ineffectiveness of deep layers in LLMs is the widespread usage of Pre-Layer Normalization (Pre-LN). While Pre-LN stabilizes the training of Transformer LLMs, its output variance exponentially grows with the model depth, which undesirably causes the derivative of the deep Transformer blocks to be an identity matrix, and therefore barely contributes to the training. To resolve this training pitfall, we propose LayerNorm Scaling, which scales the variance of output of the layer normalization inversely by the square root of its depth. This simple modification mitigates the output variance explosion of deeper Transformer layers, improving their contribution. Our experimental results, spanning model sizes from 130M to 7B, demonstrate that \ours significantly enhances LLM pre-training performance compared to Pre-LN. Moreover, this improvement seamlessly carries over to supervised fine-tuning. All these gains can be attributed to the fact that LayerNorm Scaling enables deeper layers to contribute more effectively during training.
Document type Conference contribution
Note With supplementary ZIP-file
Language English
Published at
https://doi.org/10.52202/085713-5446 (Final published version)
Published at
Other links
Downloads
Supplementary materials
Permalink to this page
Back