[rccl] DDA AlltoAll (IPC and fabric pull): stage input inside the kernel #16033
<!-- therock-pr-bot-policy-check -->
❌ PR Check — Action Required
| Check | Status | Details |
|---|:---:|---|
| 📝 PR Description | ❌ Fail | Error: PR description must reference a JIRA ID, ISSUE ID, or a GitHub closing keyword.<br>Expected: include a JIRA ID / ISSUE ID line (separator : or -, or omitted; value may be a JIRA key, a number with/without #, or a link), OR a closing keyword + issue reference. Accepted examples:<br>• JIRA ID : TESTAUTO-6039<br>• JIRA ID - #330<br>• JIRA ID #330<br>• JIRA ID (on separate line)<br>ROCM-25757<br>• ISSUE ID : TESTUTO-3334<br>• ISSUE ID #3334<br>• ISSUE ID - TESTAUTO-3433<br>• ISSUE ID (on separate line)<br>AIRUNTIME-2352<br>• ISSUE ID : https://github.com/<org_name>/<repo_name>/issues/1234<br>• Closes #10<br>• Fixes octo-org/octo-repo#100<br>• Resolves: #123<br>• #123<br>• https://github.com/<org_name>/<repo_name>/issues/123<br>Current: no valid JIRA/ISSUE/closing-keyword reference found |
| ⛔ Forbidden Files | ✅ Pass | — |
| 🧪 Unit Test | ⚠️ Warning | Error: Source/code files changed without an accompanying unit test.<br>Expected: add at least one test file named like test_<name>.py / test_<name>.cpp (or <name>_test.*).<br>Current: code file(s) changed: projects/rccl/src/algorithms/dda/alltoall/alltoall_dda.h, projects/rccl/src/algorithms/dda/alltoall/alltoall_dda_fabric.h, projects/rccl/src/algorithms/dda/device/CollCommon.h, projects/rccl/test/DdaAlltoAllThresholdTests.cpp, projects/rccl/test/common/DdaAlltoAllTestHelpers.hpp (+2 more); no test file found |
| 🔎 pre-commit | ✅ Pass | Not applicable — this repo has no pre-commit workflow. |
| 🚫 Draft PR | 🔜 To Be Enabled | — |
| 🚩 Feature Flag | 🔜 To Be Enabled | — |
| 📊 Code Coverage | 🔜 To Be Enabled | — |
⚠️ 1 policy check(s) failed. Please address the issues above before this PR can be Reviewed.
> 🚫 Please fix the failed policies
- ❌ PR Description
> The Not ready to Review label was added to this PR. Once all policies pass, the label is removed automatically.📖 Need help? See the Policy FAQ for details on every check and how to fix failures.
<!-- therock-pr-bot-fix-policies -->
🚫 Please fix the failed policies before requesting reviews.
The following policy checks failed:
The Not ready to Review label has been added to this PR.
Once all policies pass, the label will be removed automatically.
The first iteration uses 2048 FP32 elements, or exactly 8192 bytes per peer. getGridAndBlockDims() still produces one 512-thread block at that size, so the EXPECT_GT(grid.x, 1u) below always fails (the existing grid test also explicitly expects one block for count 2048). Start with kSingleBlockFloats + 4 to exercise a genuinely multi-block payload while preserving 16-byte alignment.
<!-- ccr-overview-v2 -->
🟡 Changes recommended
The all-to-all IPC test starts with 2048 FP32 elements, which produces only one block and guarantees failure of its assertion that grid.x exceeds 1.
<details open>
<summary><strong>1 open issue</strong></summary>
</details>
<details>
<summary><strong>What changed in this PR</strong></summary>
This PR moves input staging into the kernel for all grid sizes in RCCL’s single-node, eight-rank DDA IPC AlltoAll path, removing the pre-kernel copy overhead. The fabric and multi-node paths remain unchanged.
Changes:
| File | Description |
| ---- | ----------- |
| projects/rccl/test/host/algorithms/dda/alltoall/dda-alltoall-ipc-test.cc | Updates single- and multi-block launcher checks for in-kernel staging. |
| projects/rccl/test/DdaAlltoAllThresholdTests.cpp | Removes tests for the old staging split. |
| projects/rccl/test/common/DdaAlltoAllTestHelpers.hpp | Removes obsolete staging-selection helpers and constants. |
| projects/rccl/src/algorithms/dda/device/CollCommon.h | Updates the grid-sizing helper’s comment. |
| projects/rccl/src/algorithms/dda/alltoall/dda_alltoall_ipc.cu | Removes the pre-kernel copy and conditional kernel selection. |
| projects/rccl/src/algorithms/dda/alltoall/alltoall_dda.h | Partitions in-kernel staging to match each block’s read ownership. |
</details>
<sub>Review effort: Balanced</sub>
looks good. the same can be done for fabric pull kernel also, although no one is using it now.
What is the performance impact of doing this? using hipMemcpy() is faster for larger messages.
@cppccppccppc @sunguobao PTAL
<!-- markdownlint-disable MD013 -->
pr-rocm-systems-16033-oci-rccl-pr-smoke
Builds
All 20 components built.
Failures
No failing tests in this run.
15 tests skipped.
Performance regressions
pr-16033_rccl-perf_rocm-10.1-ga vs rocm-10.1-ga_rccl-develop-perf
Readings: regressed 12, improved 60, flat 1998.
| Verdict | Metric | Cell | Why | Baseline | Variant | Change |
| :-------- | :----- | :--------------------------------------------------------------------------------------------------- | :------------- | ---------: | ---------: | -----: |
| regressed | busbw | reduce_scatter_perf nodes=2 datatype=float size_bytes=2097152 reduce_op=sum root=-1 placement=ip | readings-agree | 22.96 GB/s | 21.04 GB/s | -8.4% |
| regressed | time | reduce_scatter_perf nodes=2 datatype=float size_bytes=2097152 reduce_op=sum root=-1 placement=ip | readings-agree | 85.63 us | 93.43 us | -8.3% |
| regressed | algbw | reduce_scatter_perf nodes=2 datatype=float size_bytes=2097152 reduce_op=sum root=-1 placement=ip | readings-agree | 24.49 GB/s | 22.45 GB/s | -8.3% |
| regressed | busbw | reduce_scatter_perf nodes=2 datatype=bfloat16 size_bytes=2097152 reduce_op=sum root=-1 placement=ip | readings-agree | 22.46 GB/s | 20.62 GB/s | -8.2% |
| regressed | algbw | reduce_scatter_perf nodes=2 datatype=bfloat16 size_bytes=2097152 reduce_op=sum root=-1 placement=ip | readings-agree | 23.95 GB/s | 21.99 GB/s | -8.2% |
| regressed | time | reduce_scatter_perf nodes=2 datatype=bfloat16 size_bytes=2097152 reduce_op=sum root=-1 placement=ip | readings-agree | 87.55 us | 95.35 us | -8.2% |
| regressed | algbw | reduce_scatter_perf nodes=2 datatype=bfloat16 size_bytes=2097152 reduce_op=sum root=-1 placement=oop | readings-agree | 23.76 GB/s | 21.99 GB/s | -7.4% |
| regressed | time | reduce_scatter_perf nodes=2 datatype=bfloat16 size_bytes=2097152 reduce_op=sum root=-1 placement=oop | readings-agree | 88.28 us | 95.35 us | -7.4% |
| regressed | busbw | reduce_scatter_perf nodes=2 datatype=bfloat16 size_bytes=2097152 reduce_op=sum root=-1 placement=oop | readings-agree | 22.27 GB/s | 20.62 GB/s | -7.4% |
| regressed | algbw | reduce_scatter_perf nodes=2 datatype=float size_bytes=2097152 reduce_op=sum root=-1 placement=oop | readings-agree | 23.9 GB/s | 22.47 GB/s | -6.0% |
| regressed | time | reduce_scatter_perf nodes=2 datatype=float size_bytes=2097152 reduce_op=sum root=-1 placement=oop | readings-agree | 87.76 us | 93.33 us | -6.0% |
| regressed | busbw | reduce_scatter_perf nodes=2 datatype=float size_bytes=2097152 reduce_op=sum root=-1 placement=oop | readings-agree | 22.4 GB/s | 21.07 GB/s | -5.9% |
| improved | algbw | alltoall_perf nodes=1 datatype=float size_bytes=262144 vector_count_pattern=alltoall placement=ip | readings-agree | 16.43 GB/s | 22.82 GB/s | +38.9% |
| improved | time | alltoall_perf nodes=1 datatype=float size_bytes=262144 vector_count_pattern=alltoall placement=ip | readings-agree | 15.95 us | 11.49 us | +38.8% |
| improved | busbw | alltoall_perf nodes=1 datatype=float size_bytes=262144 vector_count_pattern=alltoall placement=ip | readings-agree | 14.38 GB/s | 19.96 GB/s | +38.8% |
| improved | algbw | alltoall_perf nodes=1 datatype=float size_bytes=262144 vector_count_pattern=alltoall placement=oop | readings-agree | 16.43 GB/s | 22.8 GB/s | +38.8% |
| improved | busbw | alltoall_perf nodes=1 datatype=float size_bytes=262144 vector_count_pattern=alltoall placement=oop | readings-agree | 14.38 GB/s | 19.95 GB/s | +38.7% |
| improved | time | alltoall_perf nodes=1 datatype=float size_bytes=262144 vector_count_pattern=alltoall placement=oop | readings-agree | 15.95 us | 11.5 us | +38.7% |
| improved | algbw | alltoall_perf nodes=1 datatype=float size_bytes=524288 vector_count_pattern=alltoall placement=ip | readings-agree | 31.73 GB/s | 43.4 GB/s | +36.8% |
| improved | time | alltoall_perf nodes=1 datatype=float size_bytes=524288 vector_count_pattern=alltoall placement=ip | readings-agree | 16.52 us | 12.08 us | +36.8% |
52 more not shown.
<!-- markdownlint-disable MD013 -->
pr-rocm-systems-16033-ruby64-rccl-pr-smoke
Builds
All 20 components built.
Failures
No failing tests in this run.
15 tests skipped.
Performance regressions
pr-16033_rccl-perf_rocm-10.1-ga vs rocm-10.1-ga_rccl-develop-perf
Readings: improved 66, flat 2004.
Fails the run: 0 regressed point(s) past 8%, each confirmed by an adjacent size.
| Verdict | Metric | Cell | Why | Baseline | Variant | Change |
| :------- | :----- | :-------------------------------------------------------------------------------------------------- | :------------- | ---------: | ---------: | -----: |
| improved | time | alltoall_perf nodes=1 datatype=float size_bytes=524288 vector_count_pattern=alltoall placement=ip | readings-agree | 16.69 us | 11.48 us | +45.4% |
| improved | busbw | alltoall_perf nodes=1 datatype=float size_bytes=524288 vector_count_pattern=alltoall placement=ip | readings-agree | 27.48 GB/s | 39.95 GB/s | +45.4% |
| improved | algbw | alltoall_perf nodes=1 datatype=float size_bytes=524288 vector_count_pattern=alltoall placement=ip | readings-agree | 31.41 GB/s | 45.66 GB/s | +45.4% |
| improved | time | alltoall_perf nodes=1 datatype=float size_bytes=524288 vector_count_pattern=alltoall placement=oop | readings-agree | 16.87 us | 11.82 us | +42.7% |
| improved | algbw | alltoall_perf nodes=1 datatype=float size_bytes=524288 vector_count_pattern=alltoall placement=oop | readings-agree | 31.08 GB/s | 44.35 GB/s | +42.7% |
| improved | busbw | alltoall_perf nodes=1 datatype=float size_bytes=524288 vector_count_pattern=alltoall placement=oop | readings-agree | 27.2 GB/s | 38.81 GB/s | +42.7% |
| improved | busbw | alltoall_perf nodes=1 datatype=float size_bytes=262144 vector_count_pattern=alltoall placement=ip | readings-agree | 14.34 GB/s | 20.16 GB/s | +40.6% |
| improved | algbw | alltoall_perf nodes=1 datatype=float size_bytes=262144 vector_count_pattern=alltoall placement=ip | readings-agree | 16.39 GB/s | 23.04 GB/s | +40.6% |
| improved | time | alltoall_perf nodes=1 datatype=float size_bytes=262144 vector_count_pattern=alltoall placement=ip | readings-agree | 15.99 us | 11.38 us | +40.5% |
| improved | time | alltoall_perf nodes=1 datatype=float size_bytes=8192 vector_count_pattern=alltoall placement=oop | readings-agree | 9.13 us | 6.59 us | +38.5% |
| improved | busbw | alltoall_perf nodes=1 datatype=float size_bytes=262144 vector_count_pattern=alltoall placement=oop | readings-agree | 14.21 GB/s | 19.65 GB/s | +38.3% |
| improved | algbw | alltoall_perf nodes=1 datatype=float size_bytes=262144 vector_count_pattern=alltoall placement=oop | readings-agree | 16.24 GB/s | 22.45 GB/s | +38.2% |
| improved | time | alltoall_perf nodes=1 datatype=float size_bytes=262144 vector_count_pattern=alltoall placement=oop | readings-agree | 16.14 us | 11.68 us | +38.2% |
| improved | busbw | alltoall_perf nodes=1 datatype=float size_bytes=8192 vector_count_pattern=alltoall placement=oop | readings-agree | 0.79 GB/s | 1.09 GB/s | +38.0% |
| improved | algbw | alltoall_perf nodes=1 datatype=float size_bytes=8192 vector_count_pattern=alltoall placement=oop | readings-agree | 0.9 GB/s | 1.24 GB/s | +37.8% |
| improved | busbw | alltoall_perf nodes=1 datatype=float size_bytes=1048576 vector_count_pattern=alltoall placement=ip | readings-agree | 53.71 GB/s | 73.19 GB/s | +36.3% |
| improved | algbw | alltoall_perf nodes=1 datatype=float size_bytes=1048576 vector_count_pattern=alltoall placement=ip | readings-agree | 61.38 GB/s | 83.64 GB/s | +36.3% |
| improved | time | alltoall_perf nodes=1 datatype=float size_bytes=1048576 vector_count_pattern=alltoall placement=ip | readings-agree | 17.08 us | 12.54 us | +36.2% |
| improved | time | alltoall_perf nodes=1 datatype=float size_bytes=1048576 vector_count_pattern=alltoall placement=oop | readings-agree | 17.12 us | 12.72 us | +34.6% |
| improved | busbw | alltoall_perf nodes=1 datatype=float size_bytes=1048576 vector_count_pattern=alltoall placement=oop | readings-agree | 53.6 GB/s | 72.11 GB/s | +34.5% |
46 more not shown.
Medium
This test checks the launch but not the data. No MPI test drives ddaAllToAllIpc past one block: AllToAllTests.cpp:24 uses 1024 per peer (one block) and 1048576 (above the 4 MiB cap), and DdaAlltoAllInPlaceMPI is fabric only. That leaves the new block-partitioned staging without a test. Could we add a gfx942/gfx950 MPI check at, for example, 64 KiB and 512 KiB per peer, in place and out of place, like DdaFabricSimple.AllToAllPull?
Low
This comment narrates the removed memcpy, and alltoall_dda_fabric.h:44-47 repeats it. dda_alltoall_fabric.cu:330 and dda_alltoall_ipc.cu:65 add similar history notes. Could we keep one line here and in the fabric kernel?
// Block b stages the idx set block b on every peer reads, so the per-block-index barrier publishes it.
<!-- argus:v1 pr=16033 sha=73ba4b7b78d8 mode=review -->
ARGUS
Findings
<details>
<summary>3 more finding(s), not posted inline</summary>
projects/rccl/src/algorithms/dda/alltoall/alltoall_dda.h:47 (Low) Hand-written per-rank staging loop duplicates copyFromSrcToDest; reuse it per rank as reduce_scatter_dda.h:34-38 doesprojects/rccl/src/algorithms/dda/alltoall/alltoall_dda_fabric.h:55 (Low) Fabric pull staging loop duplicates copyFromSrcToDest; reuse it per rankprojects/rccl/src/algorithms/dda/alltoall/alltoall_dda_fabric.h:49 (Low) In-place fabric pull (RCCL_DDA_A2A_PUSH=0) has no data test; AllToAllInPlace takes the push kernel</details>
Bottom line: Worth settling before approval: no end-to-end test checks ddaAllToAllIpc output at a multi-block grid, which is exactly where the new block-partitioned staging matters.
<sub>Comment <code>@argus review</code> to re-run, or <code>@argus re-review</code> after pushing.</sub>
As I see in the Test Result table, why do we see a perf drop from 8K - 4M?
This is likely going to produce a flat load instruction to be emitted for the load on sendbuff. Consider using the types that allow casting to the global address space (address_space(1)) found in rccl_ptr.h.
Worth a check anyway.
See comment below on global versus flat instructions
With a single-block grid at 1K-2K, only count/16 lanes stage (8 or 16 of the 64), each doing 8 stores, which matches
the 1K-2K cost noted in the description. Since one block both stages and reads every slot there, could we keep the
flat copy for small single-block grids? We tried this on gfx942 and gfx950 and it brought 1K-2K back to develop's
time while keeping the gains from 4K up.
T* const myScratch = ipcbuffs[selfRank];
if (gridDim.x == 1 && 2 * idxEnd < idxStride) {
// One block stages and reads every slot, so the flat copy keeps all its threads busy.
copyFromSrcToDest<T>(sendbuff, myScratch, idxStart, idxEnd * NRANKS, idxStride);
} else {
for (size_t idx = idxStart; idx < idxEnd; idx += idxStride) {
#pragma unroll NRANKS
for (int r = 0; r < NRANKS; ++r) {
const size_t i = idx + r * idxEnd;
*reinterpret_cast<uint4*>(&myScratch[i]) = reinterpret_cast<const uint4*>(&sendbuff[i])[0];
}
}
}
With RCCL_DDA_A2A_PUSH=0 the pull kernel now does 16-byte loads from sendbuff, but ncclAllToAllDdaFabricEligible
only checks bytes % 16, not pointer alignment. Before, the host memcpy handled any alignment. Gating the tier on
alignment would break the rank-uniform tier choice the in-place MPI test relies on, so a branch inside the kernel
on (sendbuff | recvbuff) & 15 might be safer. Please check.
The staging loop and the read loop are now the same in ddaAllToAllIpc and ddaAllToAllFabric. Could we pull them into
a shared helper in CollCommon.h so the two kernels don't drift?
Up to the default 4 MiB AlltoAll cap we saw the in-kernel copy at least as fast as the memcpy on gfx942 and gfx950,
since it saves the extra launch. Above that, with at most 24 blocks, it falls behind, so it only matters if
RCCL_DDA_THRESHOLD is raised. ReduceScatter keeps a host copy above 1 MiB per shard for the same reason
(kDdaRsIpcKernelCopyMaxBytes); a similar cutoff here would cover the raised-threshold case.
A pre-existing issue, not from this PR: IPC eligibility checks each rank's own pointer alignment (ddaUserBuffers16ByteAligned at dda_alltoall_ipc.cu:109, and the same check in the AllReduce, AllGather and ReduceScatter IPC paths). If one rank passes a 16-byte-aligned buffer and another does not, the ranks pick different kernels and the DDA barrier never pairs. DdaAlltoAllInPlaceMPITests.cpp:11-14 documents this hazard for the gfx1250 tiers; happy to file it separately.
Medium
Medium
DdaFabricSimple.AllToAllPull (DdaFabricSimpleMPITests.cpp:607) is the only data check of this staging and barrier. It runs only with RCCL_DDA_A2A_PUSH=0 on gfx1250. runAllToAll (DdaFabricSimpleMPITests.cpp:417) sends one fixed payload 10 times and checks recvbuff once, after the last call. By then scratch already holds that payload from the earlier calls, so a late publish at this barrier still reads matching data. Could we vary the fill per iteration and check each one, as runBarrierStressAllToAll (DdaFabricSimpleMPITests.cpp:821-850) does?
Medium
Medium
With RCCL_DDA_A2A_PUSH=0 on gfx1250, ddaAllToAllFabric is selected only in the VMM tier. That tier starts above the 16 MiB AlltoAll LL128 ceiling and runs up to 256 MiB total (rccl_arch_thresholds.cc:53/66, DPX :336/:350; rccl_wrap.cc:3029). The in-kernel staging now covers that whole band on at most ddaFabricMaxBlocks blocks, and the 1K-4M gfx942 numbers do not reach it. Could we measure 16-256 MiB with PUSH=0, or keep the host copy above a cutoff like kDdaRsIpcKernelCopyMaxBytes (CollCommon.h:243)? Please check.
<!-- argus:v1 pr=16033 sha=406317b0ea52 mode=re-review -->
ARGUS
Impact
<details>
<summary>Reaches gfx942, gfx950, gfx1250; the PR targets gfx942, gfx950, gfx1250; 5 test(s) to run, 4 heatmap cell(s) to measure</summary>
Every DDA IPC AlltoAll on gfx942 and gfx950 (single node, 8 ranks, fp32/fp16/bf16, in-place and out-of-place, up to the 4 MiB AlltoAll cap, or higher with RCCL_DDA_THRESHOLD) now stages sendbuff inside the kernel. Before, a host cudaMemcpyAsync did this above 8 KiB per peer. On gfx1250 the fabric VMM pull kernel changes the same way, but only with RCCL_DDA_A2A_PUSH=0, at 16-256 MiB. Measured on gfx942 only, at 1K-8M. gfx950 and gfx1250 are not measured. Reaches gfx942, gfx950, gfx1250; the PR targets gfx942, gfx950, gfx1250.
Tests that exercise this change
rccl-UnitTestsMPI standard_env_dda_a2a_pull, DdaFabricSimple.AllToAllPull: forces RCCL_DDA_A2A_PUSH=0, the only route to the changed fabric pull kernel (projects/rccl/test/test_categories_mpi.yaml)rccl-UnitTestsMPI standard, DdaAlltoAllInPlaceMPI.: in-place DDA AlltoAll, where the staging now reads sendbuff and writes the aliased recvbuff in one kernel (projects/rccl/test/test_categories_mpi.yaml)rccl-UnitTests quick, AlltoAll.OutOfPlace: 8-GPU out-of-place AlltoAll goes through the IPC kernel on gfx942/gfx950 (projects/rccl/test/test_categories.yaml)rccl-UnitTestsFixturesDebug quick, DdaAlltoAllThresholdTest.: the suite this PR trims; checks the DDA entry decision is unchanged (projects/rccl/test/test_categories_fixtures_debug.yaml)rccl-UnitTestsHostAll quick, *: runs the updated IPC and fabric launcher microtests (projects/rccl/test/test_categories_host_all.yaml)Heatmap cells to measure, baseline against this PR, interleaved A/B
gfx942 alltoall any, 1 node(s), 1 KiB to 4 MiB: IPC path stages in the kernel at every grid size. The author measured this band; 1K-2K is slowergfx950 alltoall any, 1 node(s), 1 KiB to 4 MiB (not measured in the heatmap): same IPC kernel change under the gfx950 4 MiB cap, not measuredgfx942 alltoall any, 1 node(s), 8 MiB to 64 MiB: in-kernel staging with no cutoff, reached only with RCCL_DDA_THRESHOLD raisedgfx1250 alltoall any, 1 node(s), 16 MiB to 256 MiB (not measured in the heatmap): fabric VMM pull kernel (RCCL_DDA_A2A_PUSH=0) now stages in the kernel, not measured</details>
Bottom line: Worth settling before approval: Launch_MultiBlockPayloadAlsoStagesInsideTheKernel starts at 8 KiB per peer, which still launches one block, so its grid.x > 1 check fails. The multi-block IPC staging also still has no data test.
<sub>Comment <code>@argus review</code> to re-run, or <code>@argus re-review</code> after pushing.</sub>
<!-- markdownlint-disable MD013 -->
pr-rocm-systems-16033-oci-rccl-pr-smoke
Builds
All 15 components built.
Failures
No failing tests in this run.
12 tests skipped.
Performance regressions
Thresholds. A reading is marked regressed when its performance drops more than 5% and the change is significant. The run fails when a point drops more than 10% and an adjacent size does too. Performance is bandwidth, or the inverse of latency.
pr-16033_rccl-perf_rocm-10.2-latest vs rocm-10.2-latest_rccl-develop-perf
Readings: improved 60, flat 2010.
Fails the run: 0 regressed point(s) past 10%, each confirmed by an adjacent size.
One row per point, showing the reading that moved most.
| Verdict | Cell | Reading | Why | Baseline | Variant | Change |
| :------- | :------------------------------------------------------------------------------------ | :---------- | :------------- | ---------: | ---------: | -----: |
| improved | alltoall_perf nodes=1 datatype=float size_bytes=262144 vector_count_pattern=alltoall | busbw (ip) | readings-agree | 17.43 GB/s | 28.79 GB/s | +65.2% |
| improved | alltoall_perf nodes=1 datatype=float size_bytes=524288 vector_count_pattern=alltoall | busbw (ip) | readings-agree | 34.7 GB/s | 53 GB/s | +52.7% |
| improved | alltoall_perf nodes=1 datatype=float size_bytes=131072 vector_count_pattern=alltoall | busbw (ip) | readings-agree | 9.56 GB/s | 14.49 GB/s | +51.6% |
| improved | alltoall_perf nodes=1 datatype=float size_bytes=65536 vector_count_pattern=alltoall | busbw (oop) | readings-agree | 5.07 GB/s | 7.36 GB/s | +45.2% |
| improved | alltoall_perf nodes=1 datatype=float size_bytes=8192 vector_count_pattern=alltoall | algbw (oop) | readings-agree | 1.04 GB/s | 1.49 GB/s | +43.3% |
| improved | alltoall_perf nodes=1 datatype=float size_bytes=1048576 vector_count_pattern=alltoall | algbw (ip) | readings-agree | 68.35 GB/s | 93.23 GB/s | +36.4% |
| improved | alltoall_perf nodes=1 datatype=float size_bytes=16384 vector_count_pattern=alltoall | busbw (oop) | readings-agree | 1.87 GB/s | 2.49 GB/s | +33.2% |
| improved | alltoall_perf nodes=1 datatype=float size_bytes=32768 vector_count_pattern=alltoall | time (oop) | readings-agree | 8.22 us | 6.29 us | +30.7% |
| improved | alltoall_perf nodes=1 datatype=float size_bytes=2097152 vector_count_pattern=alltoall | time (oop) | readings-agree | 19.93 us | 15.46 us | +28.9% |
| improved | alltoall_perf nodes=1 datatype=float size_bytes=4096 vector_count_pattern=alltoall | time (oop) | readings-agree | 6.07 us | 5.4 us | +12.4% |
<!-- markdownlint-disable MD013 -->
pr-rocm-systems-16033-ruby64-rccl-pr-smoke
Builds
All 15 components built.
Failures
No failing tests in this run.
12 tests skipped.
Performance regressions
Thresholds. A reading is marked regressed when its performance drops more than 5% and the change is significant. The run fails when a point drops more than 8% and an adjacent size does too. Performance is bandwidth, or the inverse of latency.
pr-16033_rccl-perf_rocm-10.2-latest vs rocm-10.2-latest_rccl-develop-perf
Readings: improved 60, flat 2010.
Fails the run: 0 regressed point(s) past 8%, each confirmed by an adjacent size.
One row per point, showing the reading that moved most.
| Verdict | Cell | Reading | Why | Baseline | Variant | Change |
| :------- | :------------------------------------------------------------------------------------ | :---------- | :------------- | ---------: | ---------: | -----: |
| improved | alltoall_perf nodes=1 datatype=float size_bytes=524288 vector_count_pattern=alltoall | busbw (ip) | readings-agree | 31.01 GB/s | 46.82 GB/s | +51.0% |
| improved | alltoall_perf nodes=1 datatype=float size_bytes=262144 vector_count_pattern=alltoall | time (ip) | readings-agree | 14.45 us | 9.61 us | +50.4% |
| improved | alltoall_perf nodes=1 datatype=float size_bytes=131072 vector_count_pattern=alltoall | time (ip) | readings-agree | 13.75 us | 9.5 us | +44.7% |
| improved | alltoall_perf nodes=1 datatype=float size_bytes=8192 vector_count_pattern=alltoall | algbw (oop) | readings-agree | 0.86 GB/s | 1.23 GB/s | +43.0% |
| improved | alltoall_perf nodes=1 datatype=float size_bytes=1048576 vector_count_pattern=alltoall | time (ip) | readings-agree | 15.39 us | 10.79 us | +42.6% |
| improved | alltoall_perf nodes=1 datatype=float size_bytes=65536 vector_count_pattern=alltoall | time (ip) | readings-agree | 13.21 us | 9.57 us | +38.0% |
| improved | alltoall_perf nodes=1 datatype=float size_bytes=16384 vector_count_pattern=alltoall | busbw (oop) | readings-agree | 1.51 GB/s | 2.04 GB/s | +35.1% |
| improved | alltoall_perf nodes=1 datatype=float size_bytes=32768 vector_count_pattern=alltoall | busbw (oop) | readings-agree | 2.81 GB/s | 3.69 GB/s | +31.3% |
| improved | alltoall_perf nodes=1 datatype=float size_bytes=2097152 vector_count_pattern=alltoall | algbw (oop) | readings-agree | 109.4 GB/s | 132.3 GB/s | +21.0% |
| improved | alltoall_perf nodes=1 datatype=float size_bytes=4096 vector_count_pattern=alltoall | busbw (oop) | readings-agree | 0.46 GB/s | 0.54 GB/s | +17.4% |
srirajpaul
thananon
Motivation
The DDA IPC AlltoAll (gfx942/gfx950, 1 node, 8 ranks, up to 4 MiB) stages
sendbuffinto the IPC scratch with a hostcudaMemcpyAsyncwhenever the grid has more than one block, i.e. above 8 KiB per peer. The in-kernel copy was only used for single-block grids. It is a flat strided copy over all8 countelements, so with more than one block the same-block-index barrier does not cover what other blocks copied. The extra memcpy before the kernel costs ~3-4 us per call from 64K up.Technical Details
alltoall_dda.h: the staging copy is partitioned the same way as the read loop. Block b copiesidx + r countfor everyidxin its own stride set, which is exactly what block b on each peer reads after the barrier. The same-block-index barrier then publishes the staged data for any grid size. ThekStagingCopyInKerneltemplate parameter is removed.dda_alltoall_ipc.cu: always launches the in-kernel staging variant; the pre-kernelcudaMemcpyAsyncis gone.recvbuffelements it read fromsendbuffbefore the barrier.ddaAllToAllFabric, used only withRCCL_DDA_A2A_PUSH=0): same block-partitioned in-kernel staging before its existing release-acquire same-block-index barrier; the pre-kernelcudaMemcpyAsyncis gone and the kernel takessendbuff(same argument position as the push kernel). The default push kernels already readsendbuffin the kernel and are unchanged.sendbuffargument). The IPC launcher microtest checks that multi-block grids launch the same kernel with no pre-kernel copy. The two gfx950 tests and helper that mirrored the removed single-block/memcpy split are deleted.Issue Tracking
None.
Test Plan
MI300X (gfx942), 1 node, 8 ranks (1 process per GPU), bf16, develop 9e9bdcd with and without the change:
alltoall_perf -g 1 -d bfloat16 -b 1K -e 8M -f 2 -w 10 -n 50 -c 1, 3 interleaved runs per library; the TUNING log shows the DDA path (algo=18) for both.Test Result
rccl-tests out-of-place time (us), median of 3:
| size | before | after | change |
|---|---|---|---|
| 1K | 7.27 | 7.60 | +4.5% |
| 2K | 7.20 | 7.39 | +2.6% |
| 8K | 9.05 | 7.43 | -18% |
| 32K | 10.53 | 9.36 | -11% |
| 64K | 14.48 | 12.07 | -17% |
| 256K | 15.87 | 12.23 | -23% |
| 1M | 18.58 | 15.55 | -16% |
| 2M | 23.63 | 20.24 | -14% |
| 4M | 31.94 | 30.44 | -5% |
| 8M | 39.20 | 39.15 | above the DDA cap |
#wrong= 0 in every row. rccl-tests does not validate in-place AlltoAll (N/A).Caveats:
RCCL_DDA_A2A_PUSH=0only) is not measured on hardware.RCCL_DDA_THRESHOLDraised above the 4 MiB default cap, the in-kernel copy runs at sizes not measured here.Submission Checklist