The Curse of Depth in Large Language Models
Wenfang Sun, Xinyuan Song, Pengxiang Li, Lu Yin, Yefeng Zheng, Shiwei Liu
摘要
In this paper, we introduce the Curse of Depth, a concept that highlights, explains, and addresses the recent observation in modern Large Language Models (LLMs) where nearly half of the layers are 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 (LNS), 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. Across a wide range of model sizes (130M to 7B), our experiments show that LNS consistently outperforms previous normalization and scaling techniques in enhancing LLM pre-training performance. 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. Our code is available at LayerNorm-Scaling.
问 Lune
几分钟读透这篇 Paper,不用再花一下午。
Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。
已有 20 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。
脉络
- Don't be lazy: CompleteP enables compute-efficient deep transformers 引用了 Language Models are Few-Shot Learners
- Measuring Massive Multitask Language Understanding 引用了 Language Models are Few-Shot Learners
- Going deeper with Image Transformers 引用了 Language Models are Few-Shot Learners
- CogView: Mastering Text-to-Image Generation via Transformers 引用了 Language Models are Few-Shot Learners
- CogView: Mastering Text-to-Image Generation via Transformers 引用了 On Layer Normalization in the Transformer Architecture
- SiameseNorm: Breaking the Barrier to Reconciling Pre/Post-Norm 引用了 Going deeper with Image Transformers
- SiameseNorm: Breaking the Barrier to Reconciling Pre/Post-Norm 引用了 CogView: Mastering Text-to-Image Generation via Transformers
- SiameseNorm: Breaking the Barrier to Reconciling Pre/Post-Norm 引用了 Language Models are Few-Shot Learners
- SiameseNorm: Breaking the Barrier to Reconciling Pre/Post-Norm 引用了 On Layer Normalization in the Transformer Architecture
- Why Do We Need Warm-up? A Theoretical Perspective 引用了 On Layer Normalization in the Transformer Architecture
- Normalization in Attention Dynamics 引用了 On Layer Normalization in the Transformer Architecture
引用它的顶会 Paper20
- Don't be lazy: CompleteP enables compute-efficient deep transformersNolan Dey, Bin Claire Zhang, Lorenzo Noci, Mufan Bill Li 等NeurIPS 2025 · 77 次引用
- Flow Caching for Autoregressive Video GenerationYuexiao Ma, Xuzhe Zheng, Jing Xu, Xiwei Xu 等ICLR 2026 · 20 次引用
- Normalization in Attention DynamicsNikita Karagodin, Shu Ge, Yury Polyanskiy, Philippe RigolletNeurIPS 2025 · 10 次引用
- Why Do We Need Warm-up? A Theoretical PerspectiveFoivos Alimisis, Rustem Islamov, Aurelien LucchiICML 2026 · 8 次引用
- SiameseNorm: Breaking the Barrier to Reconciling Pre/Post-NormTianyu Li, Dongchen Han, Zixuan Cao, Haofeng Huang 等ICML 2026 · 7 次引用
它引用的 Paper20
- Language Models are Few-Shot LearnersTom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah 等NeurIPS 2020 · 64,255 次引用
- Measuring Massive Multitask Language UnderstandingDan Hendrycks, Collin Burns, Steven Basart, Andy Zou 等ICLR 2021 · 7,905 次引用
- On Layer Normalization in the Transformer ArchitectureRuibin Xiong, Yunchang Yang, Di He, Kai Zheng 等ICML 2020 · 1,388 次引用
- Going deeper with Image TransformersHugo Touvron, Matthieu Cord, Alexandre Sablayrolles, Gabriel Synnaeve 等ICCV 2021 · 1,279 次引用
- CogView: Mastering Text-to-Image Generation via TransformersMing Ding, Zhuoyi Yang, Wenyi Hong, Wendi Zheng 等NeurIPS 2021 · 1,026 次引用
相关 Paper
- Mix-LN: Unleashing the Power of Deeper Layers by Combining Pre-LN and Post-LNPengxiang Li, Lu Yin, Shiwei LiuICLR 2025
- GPAS: Accelerating Convergence of LLM Pretraining via Gradient-Preserving Activation ScalingTianhao Chen, Xin Xu, Zijing Liu, Pengxiang Li 等NeurIPS 2025 · 2 次引用
- When Does Sparsity Mitigate the Curse of Depth in LLMsYao Yao, Xinyuan Song, Sebastian Pokutta, Max Zimmer 等ICML 2026 · 5 次引用
- Bounded Hyperbolic Tangent: A Stable and Efficient Alternative to Pre-Layer Normalization in Large Language ModelsHoyoon Byun, Youngjun Choi, Taero Kim, Sungrae Park 等ICML 2026 · 2 次引用
- SeeDNorm: Self-Rescaled Dynamic NormalizationWenrui Cai, Defa Zhu, Siyuan Qiao, Qingjie Liu 等ICLR 2026 · 7 次引用
