Pipeline Parallelism with Controllable Memory
Penghui Qi, Xinyi Wan, Nyamdavaa Amar, Min Lin
摘要
Pipeline parallelism has been widely explored, but most existing schedules lack a systematic methodology. In this paper, we propose a framework to decompose pipeline schedules as repeating a building block, and show that the lifespan of the building block decides the peak activation memory of the pipeline schedule. Guided by the observations, we find that almost all existing pipeline schedules, to the best of our knowledge, are memory inefficient. To address this, we introduce a family of memory efficient building blocks with controllable activation memory, which can reduce the peak activation memory to 1/2 of 1F1B without sacrificing efficiency, and even to 1/3 with comparable throughput. We can also achieve almost zero pipeline bubbles while maintaining the same activation memory as 1F1B. Our evaluations demonstrate that in pure pipeline parallelism settings, our methods outperform 1F1B by from 7% to 55% in terms of throughput. When employing a grid search over hybrid parallelism hyperparameters in practical scenarios, our methods demonstrate a 16% throughput improvement over the 1F1B baseline for large language models. The implementation is open-sourced at https://github.com/sail-sg/zero-bubble-pipeline-parallelism.
问 Lune
几分钟读透这篇 Paper,不用再花一下午。
Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。
已有 3 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。
脉络
- PipeOffload: Improving Scalability of Pipeline Parallelism with Memory Optimization 引用了 Efficient large-scale language model training on GPU clusters using megatron-LM
- PipeOffload: Improving Scalability of Pipeline Parallelism with Memory Optimization 引用了 DAPPLE: a pipelined data parallel approach for training large models
- FlashAttention: Fast and Memory-Efficient Exact Attention with IO-Awareness 引用了 Language Models are Few-Shot Learners
- Efficient large-scale language model training on GPU clusters using megatron-LM 引用了 DAPPLE: a pipelined data parallel approach for training large models
- Efficient large-scale language model training on GPU clusters using megatron-LM 引用了 Language Models are Few-Shot Learners
- FlashAttention-2: Faster Attention with Better Parallelism and Work Partitioning 引用了 FlashAttention: Fast and Memory-Efficient Exact Attention with IO-Awareness
- Synergistic Tensor and Pipeline Parallelism 引用了 Efficient large-scale language model training on GPU clusters using megatron-LM
- Synergistic Tensor and Pipeline Parallelism 引用了 FlashAttention-2: Faster Attention with Better Parallelism and Work Partitioning
- Synergistic Tensor and Pipeline Parallelism 引用了 Language Models are Few-Shot Learners
- SlimPipe: Memory-Thrifty and Efficient Pipeline Parallelism for Long-Context LLM Training 引用了 FlashAttention: Fast and Memory-Efficient Exact Attention with IO-Awareness
- SlimPipe: Memory-Thrifty and Efficient Pipeline Parallelism for Long-Context LLM Training 引用了 Efficient large-scale language model training on GPU clusters using megatron-LM
- SlimPipe: Memory-Thrifty and Efficient Pipeline Parallelism for Long-Context LLM Training 引用了 DAPPLE: a pipelined data parallel approach for training large models
引用它的顶会 Paper3
- SlimPipe: Memory-Thrifty and Efficient Pipeline Parallelism for Long-Context LLM TrainingZhouyang Li, Yuliang Liu, Wei Zhang, Tailing Yuan 等SC 2025 · 5 次引用
- Synergistic Tensor and Pipeline ParallelismMengshi Qi, Jiaxuan Peng, Jie M. Zhang, Juan Zhu 等NeurIPS 2025 · 2 次引用
- PipeOffload: Improving Scalability of Pipeline Parallelism with Memory OptimizationXinyi Wan, Penghui Qi, Guangxing Huang, Min Lin 等ICML 2025
它引用的 Paper10
- Language Models are Few-Shot LearnersTom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah 等NeurIPS 2020 · 64,255 次引用
- FlashAttention: Fast and Memory-Efficient Exact Attention with IO-AwarenessTri Dao, Daniel Y. Fu, Stefano Ermon, Atri Rudra 等NeurIPS 2022 · 5,493 次引用
- FlashAttention-2: Faster Attention with Better Parallelism and Work PartitioningTri DaoICLR 2024 · 2,600 次引用
- Efficient large-scale language model training on GPU clusters using megatron-LMDeepak Narayanan, Mohammad Shoeybi, Jared Casper, Patrick LeGresley 等SC 2021 · 576 次引用
- DAPPLE: a pipelined data parallel approach for training large modelsShiqing Fan, Yi Rong, Chen Meng, Zongyan Cao 等PPoPP 2021 · 224 次引用
相关 Paper
- Zero Bubble (Almost) Pipeline ParallelismPenghui Qi, Xinyi Wan, Guangxing Huang, Min LinICLR 2024 · 31 次引用
- AdaptPipe: Mitigating Runtime Bubbles via Granularity-Adaptive Scheduling under Memory ConstraintsYumeng Cui, Jessie Hui Wang, Najila Liu, Ling Deng 等INFOCOM 2026
- BPipe: Memory-Balanced Pipeline Parallelism for Training Large Language ModelsTaebum Kim, Hyoungjoo Kim, Gyeong-In Yu, Byung-Gon ChunICML 2023 · 34 次引用
- WeiPipe: Weight Pipeline Parallelism for Communication-Effective Long-Context Large Model TrainingJunfeng Lin, Ziming Liu, Yang You, Jun Wang 等PPoPP 2025 · 5 次引用
- Mario: Near Zero-cost Activation Checkpointing in Pipeline ParallelismWeijian Liu, Mingzhen Li, Guangming Tan, Weile JiaPPoPP 2025 · 4 次引用
