English

A Doubly-pipelined, Dual-root Reduction-to-all Algorithm and Implementation

Distributed, Parallel, and Cluster Computing 2022-01-21 v3

Abstract

We discuss a simple, binary tree-based algorithm for the collective allreduce (reduction-to-all, MPI_Allreduce) operation for parallel systems consisting of pp suitably interconnected processors. The algorithm can be doubly pipelined to exploit bidirectional (telephone-like) communication capabilities of the communication system. In order to make the algorithm more symmetric, the processors are organized into two rooted trees with communication between the two roots. For each pipeline block, each non-leaf processor takes three communication steps, consisting in receiving and sending from and to the two children, and sending and receiving to and from the root. In a round-based, uniform, linear-cost communication model in which simultaneously sending and receiving nn data elements takes time α+βn\alpha+\beta n for system dependent constants α\alpha (communication start-up latency) and β\beta (time per element), the time for the allreduce operation on vectors of mm elements is O(logp+mlogp)+3βmO(\log p+\sqrt{m\log p})+3\beta m by suitable choice of the pipeline block size. We compare the performance of an implementation in MPI to similar reduce followed by broadcast algorithms, and the native MPI_Allreduce collective on a modern, small 36×3236\times 32 processor cluster. With proper choice of the number of pipeline blocks, it is possible to achieve better performance than pipelined algorithms that do not exploit bidirectional communication.

Keywords

Cite

@article{arxiv.2109.12626,
  title  = {A Doubly-pipelined, Dual-root Reduction-to-all Algorithm and Implementation},
  author = {Jesper Larsson Träff},
  journal= {arXiv preprint arXiv:2109.12626},
  year   = {2022}
}
R2 v1 2026-06-24T06:20:37.775Z