DistFlow: A Fully Distributed RL Framework for Scalable and Efficient LLM Post-Training

Zhixin Wang, Jiaming Xu, Tianyi Zhou, Mingjun Zhang, Liming Liu, Jiarui Hu, Dian Yang, TongYu Wang, Ping Zhang, Jinlong Hou, Siyuan Feng, Yuan Qi, Yuan Cheng

Reinforcement Learning (RL) post-training has emerged as the "secret sauce" behind the advanced reasoning capabilities of modern Large Language Models (LLMs) like DeepSeek-R1. However, effectively scaling RL to accommodate massive datasets and complex execution flows remains a formidable challenge. Mainstream frameworks often rely on centralized architectures that inadvertently create severe communication bottlenecks, limiting both system scalability and overall efficiency.

To address this, researchers have introduced DistFlow, a fully distributed RL framework designed to scale LLM post-training to hundreds of GPUs. By decoupling control logic from data transmission, DistFlow achieves near-linear scalability and up to a 2.63x throughput improvement over state-of-the-art frameworks like verl.

The Centralization Bottleneck

In most current RL frameworks, a single "manager" node is responsible for dispatching both control commands and massive data tensors across worker nodes. As training scales from 8 to 512 GPUs, this centralized hub becomes overwhelmed. It spends the majority of its time shuffling gigabytes of data, leaving worker GPUs idle and creating "communication bubbles."

This serialization bottleneck—often referred to as the "centralized tax"—can consume over 40% of the total iteration time in traditional systems. Furthermore, it leads to system instability and Out-of-Memory (OOM) errors, particularly when handling long-context data or exceptionally large models. The core insight behind DistFlow is that control signals are tiny (kilobytes) while data tensors are massive (gigabytes). By decoupling the two, the system can avoid this debilitating bottleneck entirely.

DistFlow Architecture: A Multi-Controller Paradigm

DistFlow shifts away from the single-controller model in favor of a multi-controller paradigm built on two foundational pillars:

1. DAG-Defined Control Flow

Instead of a central node micro-managing every step of the training process, DistFlow utilizes a DAG Planner. This planner translates complex RL algorithms (such as PPO or GRPO) into a Directed Acyclic Graph (DAG) of tasks. Each GPU runs a dedicated DAG Worker that understands its specific place in the sequence. This allows for fine-grained, independent execution of control logic without constant synchronization with a master node.

2. Decentralized Data Coordinator

Acting as the framework's "traffic department," the Data Coordinator manages the data lifecycle across GPUs without funneling information through a central hub. It relies on three key mechanisms:

  • Local Caching: Because the Data Coordinator is parallelism-aware (understanding the Tensor Parallel and Data Parallel ranks of every worker), it only moves data when a topology transformation is strictly necessary. If the parallel strategy remains unchanged between steps, data stays on the GPU, bypassing the network entirely.
  • Constrained LPT Load Balancing: DistFlow employs a specialized heuristic to balance computational load. It assigns the longest sequences to the least-loaded workers while ensuring every worker processes an equal number of items, mitigating straggler effects.
  • Asynchronous Double Buffering: The framework instantly swaps memory pointers between training steps, offloading memory cleanup to the background. This ensures GPUs never have to wait for garbage collection.

Experimental Setup and Key Results

DistFlow was rigorously evaluated using several benchmarks, including the DeepScaleR-Preview-Dataset (math reasoning), the MM-Eureka-Dataset (multimodal VLM reasoning), and GSM8K (for detailed procedure-level timeline breakdowns).

The experimental results demonstrate significant improvements across multiple dimensions:

  • Unprecedented Throughput: DistFlow achieved up to 2.63x higher throughput compared to verl in data-intensive GRPO scenarios.
  • Near-Linear Scaling: The framework exhibited exceptional scaling efficiency, maintaining 90.1% to 93.9% efficiency when scaling from 32 to 512 GPUs.
  • Long-Context Superiority: In evaluations utilizing 64k context lengths, DistFlow's throughput speedup exceeded 2x. Notably, while baseline systems crashed with OOM errors on 72B models at this context length, DistFlow maintained stable execution.
  • Zero Accuracy Loss: Convergence tests confirmed that DistFlow reaches the same reward and entropy levels as standard frameworks, but completes training 21% faster.

Limitations and Future Directions

While DistFlow excels in "colocated" settings—where the same GPUs handle both inference and training—the current research primarily focuses on standard RLHF/GRPO workflows.

Future work will need to address heterogeneous hardware environments, as the current implementation relies heavily on Ray and NCCL, making it less adaptable to lower-bandwidth or diverse hardware setups. Additionally, while the DAG Planner handles standard RL efficiently, highly complex, non-linear research algorithms may require manual tuning of the linearization process to prevent resource contention. Finally, while the paper includes promising VLM results, further exploration into the specific data-loading dynamics of massive image and video tensors in a distributed setup will be highly beneficial.

Summary updated

BibTeX
@inproceedings{wang2026distflow,
  author = {Zhixin Wang and Jiaming Xu and Tianyi Zhou and Mingjun Zhang and Liming Liu and Jiarui Hu and Dian Yang and TongYu Wang and Ping Zhang and Jinlong Hou and Siyuan Feng and Yuan Qi and Yuan Cheng},
  title = {{DistFlow: A Fully Distributed RL Framework for Scalable and Efficient LLM Post-Training}},
  booktitle = {International Conference on Machine Learning},
  year = {2026},
  url = {https://openreview.net/forum?id=aPPEyZpKkp},
}
Figure