TL/UCP: enable host-side SRA allreduce pipelining - #1354
Conversation
Overlap the reduce-scatter and allgather phases across fragments on the host path so fragment i's allgather (pure network) runs concurrently with fragment i+1's reduce-scatter (network + CPU reduction). Previously the host branch of the SRA-knomial pipeline heuristic disabled pipelining (n_frags=1), leaving the NIC idle during every reduce step and the CPU idle during the entire allgather. The host else-branch of get_pipeline_params() now sets conservative defaults: threshold 256KB, 512KB fragments, nfrags floor 2, pdepth 2, parallel order. Env override UCC_TL_UCP_ALLREDUCE_SRA_KN_PIPELINE still takes precedence. Correctness is unchanged: the CUDA in-place path already runs the identical fragmented schedule, and per-frag scratch is sized from max_frag_count (smaller frags -> smaller scratch). Fragment size was tuned on thor (8 nodes, host, float32 sum, forced sra_knomial, mlx5_0:1) against stock HPC-X 2.25.1 UCC: new vs hpcx (avg bus BW ratio) size 2 ranks 4 ranks 6 ranks 256 ranks 512KB 1.34x 1.37x 1.25x 1.06x 1MB 1.45x 1.30x 1.22x 1.45x 2MB 1.45x 1.29x 1.17x 1.53x 4MB 1.43x 1.25x 1.31x >1.4x 512KB frags beat the initial 256KB choice by 6-17% at >=1MB across 2-256 ranks and remove a 1-2MB regression the finer default showed at 256 ranks; below 256KB the path is byte-identical (no regression). pdepth=4 gave no benefit and hurt at 4MB, so pdepth stays 2.
|
🤖 CI Triage Agent — TL;DR: The gtest Full analysisSummary: ASAN gtest run failed 1 test — Root cause: Implicated commit: d56c68d — "TL/UCP: enable host-side SRA allreduce pipelining" (Ferrol Aderholdt) on branch File: Suggested fix: Change Related: PR #1354; prior schedule-pipeline fixes c8314d3 (#1262), 4f67436 (#1051). |
|
🤖 CI Triage Agent — TL;DR: Two new Full analysisSummary: The gtest job (shard 0) failed: 2 of 7759 tests failed — Root cause: These tests use a fault-injection harness that registers process-global hooks and counters — Implicated commit: File: test/gtest/core/test_schedule.cc:1013-1027 ( Suggested fix: Make the fault harness self-contained per test. Add a ucc_event_manager_set_subscribe_fault_cb(NULL);
ucc_schedule_pipelined_set_lock_observer(NULL);
g_fault_subscribe_fail_at = -1;
g_fault_subscribe_attempt = 0;so no fault callback survives into other tests and each test starts from a clean, deterministic global state. Alternatively, gate Related: PR #1354 ( |
Overlap the reduce-scatter and allgather phases across fragments on the host path so fragment i's allgather (pure network) runs concurrently with fragment i+1's reduce-scatter (network + CPU reduction). Previously the host branch of the SRA-knomial pipeline heuristic disabled pipelining (n_frags=1), leaving the NIC idle during every reduce step and the CPU idle during the entire allgather.
The host else-branch of get_pipeline_params() now sets conservative defaults: threshold 256KB, 512KB fragments, nfrags floor 2, pdepth 2, parallel order. Env override UCC_TL_UCP_ALLREDUCE_SRA_KN_PIPELINE still takes precedence. Correctness is unchanged: the CUDA in-place path already runs the identical fragmented schedule, and per-frag scratch is sized from max_frag_count (smaller frags -> smaller scratch).