Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
43 commits
Select commit Hold shift + click to select a range
51f2e7e
Remove trailing WS when timestamp option not used
AddyLaddy Nov 3, 2025
4bc314a
Add README.md text for -J option
AddyLaddy Nov 21, 2025
760c467
Add memory usage report option
AddyLaddy Nov 3, 2025
7106245
Add include of <limits> due to compilation error
AddyLaddy Nov 17, 2025
24874bd
Compatibility with 2.29 device API: use NCCL_DEV_COMM_REQUIREMENTS_IN…
kgioioso Nov 13, 2025
332e618
device api 2.28 is not compatible with 2.29. Check versions and print…
kgioioso Nov 25, 2025
070d175
refactor comm init
kgioioso Nov 21, 2025
2656c58
NCCL_TESTS_VERSION 2.17.7
kgioioso Dec 30, 2025
7278698
Clarified use of Mebibytes and Gibibytes for sizes
AddyLaddy Jan 6, 2026
81463c5
NCCL_TESTS_VERSION 2.17.8
AddyLaddy Jan 6, 2026
88d7e33
Add -M memory report option to README.md
AddyLaddy Jan 15, 2026
85ca91d
Fix: corrected typos in the JSON output
MykeDuong Feb 3, 2026
2535da8
NCCL_TESTS_VERSION 2.17.9
AddyLaddy Feb 3, 2026
9938d5a
Fix compilation issues with latest NCCL release headers
AddyLaddy Feb 5, 2026
ae98985
Fix Clang compilation errors with VLA initialization
malagows-nvd Feb 9, 2026
db221de
Request GIN to be explicitly enabled in all to all test
Mar 3, 2026
c379e19
NCCL_TESTS_VERSION 2.17.10
AddyLaddy Mar 5, 2026
e986a61
Add -u <index> to force unaligned buffer addresses
AddyLaddy Mar 7, 2026
115fb09
Add new unalign flag to README.md and update help text
AddyLaddy Mar 7, 2026
dd0bafd
NCCL_TESTS_VERSION 2.18.0
AddyLaddy Mar 7, 2026
8d26b23
Allocate buffers during thread initialization
teojgo Mar 10, 2026
ba52a70
Allow blocking collectives without MPI_Barrier in timing loop
AddyLaddy Mar 11, 2026
c1af7df
Update -z option description in README.md
AddyLaddy Mar 11, 2026
e02c20b
NCCL_TESTS_VERSION 2.18.1
AddyLaddy Mar 11, 2026
eb0d3d2
Display unalign setting in output
AddyLaddy Mar 11, 2026
af1dcac
NCCL_TESTS_VERSION 2.18.2
AddyLaddy Mar 11, 2026
5dc0670
Add maxP2pPeers comm config for sendrecv
AddyLaddy Mar 30, 2026
f727aa2
NCCL_TESTS_VERSION 2.18.3
AddyLaddy Apr 13, 2026
0f70559
feat: improveed JSON output
antgun42 Nov 20, 2025
e4b8711
fix: env-iteration buffer overflow in jsonOutputInit
slucascore May 20, 2026
78b5633
gitignore: ignore alternate build-*/ directories
slucascore May 20, 2026
fb9d0bd
Update src/util.cu
slucascore Jun 5, 2026
d9d9d53
Update src/util.cu
slucascore Jun 5, 2026
fb9b7b2
Address review: simplify env loop, guard getGPUSerial failure
slucascore Jun 5, 2026
eb546bb
Fix inf handling in jsonDouble/getFloatStr (NCCL-inherited)
slucascore Jun 5, 2026
45b5419
Add static_assert guarding gpuSerial field width (Eta)
slucascore Jun 5, 2026
cb20ef1
Hoist NVML init/shutdown out of the per-GPU serial loop (Eta)
slucascore Jun 5, 2026
3b6578f
Shut NVML down on the cudaGetDeviceProperties error path
slucascore Jun 6, 2026
c582b4d
style: Clean up comments about old code
Eta0 Jun 16, 2026
f9a1f77
Manage NVML lifetime with an RAII guard (cleanup of Eta review)
slucascore Jun 29, 2026
bcb596d
fix: emit a JSON serial for every GPU, not just the first per process
slucascore Jul 7, 2026
0cb22f2
fix: correct GPU-serial attribution, blocking-mode JSON, and build deps
slucascore Jul 7, 2026
1d6bff5
Merge pull request #1 from coreweave/pr1-review-fixes
slucascore Jul 7, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@
#
# See LICENCE.txt for license information
/build
/build-*
22 changes: 13 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,13 +32,14 @@ NCCL tests can run on multiple processes, multiple threads, and multiple CUDA de

### Quick examples

Run on single node with 8 GPUs (`-g 8`), scanning from 8 Bytes to 128MBytes :
Run on single node with 8 GPUs (`-g 8`), scanning from 8 Bytes to 128MiB (Mebibytes), doubling between each test (`-f 2`) :

```shell
$ ./build/all_reduce_perf -b 8 -e 128M -f 2 -g 8
```

Run 64 MPI processes on nodes with 8 GPUs each, for a total of 64 GPUs spread across 8 nodes :
Run 64 MPI processes on nodes with 8 GPUs each, for a total of 64 GPUs spread across 8 nodes.
Scanning from 8 Bytes to 32GiB (Gibibytes), doubling between each test (`-f 2`).
(NB: The nccl-tests binaries must be compiled with `MPI=1` for this case)

```shell
Expand All @@ -57,10 +58,10 @@ All tests support the same set of arguments :
* `-t,--nthreads <num threads>` number of threads per process. Default : 1.
* `-g,--ngpus <GPUs per thread>` number of gpus per thread. Default : 1.
* Sizes to scan
* `-b,--minbytes <min size in bytes>` minimum size to start with. Default : 32M.
* `-e,--maxbytes <max size in bytes>` maximum size to end at. Default : 32M.
* Increments can be either fixed or a multiplication factor. Only one of those should be used
* `-i,--stepbytes <increment size>` fixed increment between sizes. Default : 1M.
* `-b,--minbytes <min size in bytes>` minimum size to start with. Default : 32M (Mebibytes).
* `-e,--maxbytes <max size in bytes>` maximum size to end at. Default : 32M (Mebibytes).
* Increments can be either fixed or a multiplication factor. Only one of those should be used.
* `-i,--stepbytes <increment size>` fixed increment between sizes. Default : 1M (Mebibytes).
* `-f,--stepfactor <increment factor>` multiplication factor between sizes. Default : disabled.
* NCCL operations arguments
* `-o,--op <sum/prod/min/max/avg/all>` Specify which reduction operation to perform. Only relevant for reduction operations like Allreduce, Reduce or ReduceScatter. Default : Sum.
Expand All @@ -75,12 +76,15 @@ All tests support the same set of arguments :
* Test operation
* `-p,--parallel_init <0/1>` use threads to initialize NCCL in parallel. Default : 0.
* `-c,--check <check iteration count>` perform count iterations, checking correctness of results on each iteration. This can be quite slow on large numbers of GPUs. Default : 1.
* `-z,--blocking <0/1>` Make NCCL collective blocking, i.e. have CPUs wait and sync after each collective. Default : 0.
* `-z,--blocking <0/1/2>` collective blocking: 1=wait for completion and barrier, 2=wait without barrier. Default : 0.
* `-G,--cudagraph <num graph launches>` Capture iterations as a CUDA graph and then replay specified number of times. Default : 0.
* `-C,--report_cputime <0/1>` Report CPU time instead of latency. Default : 0.
* `-R,--local_register <0/1/2>` enable local (1) or symmetric (2) buffer registration on send/recv buffers. Default : 0.
* `-S,--report_timestamps <0/1>` Add timestamp ("%Y-%m-%d %H:%M:%S") to each performance report line. Default : 0.
* `-S,--report_timestamps <0/1>` Add timestamp (`"%Y-%m-%d %H:%M:%S"`) to each performance report line. Default : 0.
* `-J,--output_file <file>` Write [JSON] output to filepath. Infer type from suffix (only `json` supported presently).
* `-T,--timeout <time in seconds>` timeout each test after specified number of seconds. Default : disabled.
* `-M,--memory_report <0/1>` enable memory usage report. Default : 0.
* `-u,--unalign <index of first element>` Misalign source and destination buffers. Default : 0.

### Running multiple operations in parallel

Expand All @@ -104,4 +108,4 @@ Note that the reported bandwidth is per group, hence to get the total bandwidth

## Copyright

NCCL tests are provided under the BSD license. All source code and accompanying documentation is copyright (c) 2016-2025, NVIDIA CORPORATION. All rights reserved.
NCCL tests are provided under the BSD license. All source code and accompanying documentation is copyright (c) 2016-2026, NVIDIA CORPORATION. All rights reserved.
7 changes: 6 additions & 1 deletion src/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,12 @@ ifeq ($(MPI_IBM),1)
NVCUFLAGS += -DMPI_SUPPORT
NVLDFLAGS += -lmpi_ibm
endif
LIBRARIES += nccl
# GPU serials use NVML (libnvidia-ml). Link against the CUDA toolkit's NVML stub so
# the build succeeds on hosts without the driver's -dev symlink; the real
# libnvidia-ml is loaded at runtime. libuuid was dropped — the JSON UUID is now
# generated in-tree (genUuidV4 in util.cu), so no uuid-dev is needed to build.
NVLDFLAGS += -L$(CUDA_HOME)/lib64/stubs
LIBRARIES += nccl nvidia-ml
NVLDFLAGS += $(LIBRARIES:%=-l%)

DST_DIR := $(BUILDDIR)
Expand Down
37 changes: 30 additions & 7 deletions src/all_reduce.cu
Original file line number Diff line number Diff line change
Expand Up @@ -64,27 +64,50 @@ void AllReduceGetBw(size_t count, int typesize, double sec, double* algBw, doubl
*busBw = baseBw * factor;
}

#if NCCL_VERSION_CODE >= NCCL_VERSION(2,28,0)
// set devComm reqs for allreduce device kernels
bool AllReduceGetDevCommRequirements(int deviceImpl, ncclDevCommRequirements* reqs) {
if (!reqs) return false;
memset(reqs, 0, sizeof(*reqs));
#if NCCL_VERSION_CODE >= NCCL_VERSION(2,29,0)
// set devComm reqs for allreduce device kernels
testResult_t AllReduceGetDevCommRequirements(int deviceImpl, ncclDevCommRequirements* reqs, ncclCommProperties_t* commProperties) {
if (!reqs || !commProperties) return testInternalError;

switch(deviceImpl) {
case 1: // allReduceLsaKernel
case 2: // allReduceLsaVectorizedKernel
reqs->lsaBarrierCount = deviceCtaCount;
return true;
return testSuccess;
case 3: // allReduceMultimemKernel
case 4: // allReduceMultimemVectorizedKernel
if (!commProperties->multimemSupport) {
fprintf(stderr, "This test requires multimem support, but multimem support is not enabled for this communicator.\n");
return testInternalError;
}
reqs->lsaMultimem = true;
reqs->lsaBarrierCount = deviceCtaCount;
return testSuccess;
default:
return testNotImplemented;
}
}
#elif NCCL_VERSION_CODE >= NCCL_VERSION(2,28,0)
bool AllReduceGetDevCommRequirements(int deviceImpl, ncclDevCommRequirements* reqs) {
if (!reqs) return false;
memset(reqs, 0, sizeof(*reqs));
switch(deviceImpl) {
case 1: // allReduceLsaKernel
case 2: // allReduceLsaVectorizedKernel
reqs->lsaBarrierCount = deviceCtaCount;
return true;
case 3: // allReduceMultimemKernel
case 4: // allReduceMultimemVectorizedKernelMultimem = true;
reqs->lsaMultimem = true;
reqs->lsaBarrierCount = deviceCtaCount;
return true;
default:
return false;
}
}
}
#endif

#if NCCL_VERSION_CODE >= NCCL_VERSION(2,28,0)
/*
* Kernel 1: allReduceLsaKernel - Basic LSA-based AllReduce
*
Expand Down
32 changes: 31 additions & 1 deletion src/alltoall.cu
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,35 @@ void AlltoAllGetBw(size_t count, int typesize, double sec, double* algBw, double
*busBw = baseBw * factor;
}

#if NCCL_VERSION_CODE >= NCCL_VERSION(2,28,0)
#if NCCL_VERSION_CODE >= NCCL_VERSION(2,29,0)
// set devComm reqs for alltoall device kernels
testResult_t AlltoAllGetDevCommRequirements(int deviceImpl, ncclDevCommRequirements* reqs, ncclCommProperties_t* commProperties) {
if (!reqs || !commProperties) return testInternalError;

switch(deviceImpl) {
case 1: // NvlAlltoAllKernel
case 2: // NvlAlltoAllKernelOptimized
reqs->lsaBarrierCount = deviceCtaCount;
return testSuccess;
case 3: // GinAlltoAllKernel
case 4: // HybridAlltoAllKernel (LSA+GIN)
if (commProperties->ginType == NCCL_GIN_TYPE_NONE) {
fprintf(stderr, "This test requires GIN support, but GIN support is not enabled for this communicator.\n");
return testInternalError;
}
reqs->barrierCount = deviceCtaCount;
reqs->ginSignalCount = deviceCtaCount;
#if NCCL_VERSION_CODE >= NCCL_VERSION(2, 29, 7)
reqs->ginConnectionType = NCCL_GIN_CONNECTION_FULL;
#else
reqs->ginForceEnable = true;
#endif
return testSuccess;
default:
return testNotImplemented;
}
}
#elif NCCL_VERSION_CODE >= NCCL_VERSION(2,28,0)
// set devComm reqs for alltoall device kernels
bool AlltoAllGetDevCommRequirements(int deviceImpl, ncclDevCommRequirements* reqs) {
if (!reqs) return false;
Expand All @@ -73,7 +101,9 @@ bool AlltoAllGetDevCommRequirements(int deviceImpl, ncclDevCommRequirements* req
return false;
}
}
#endif

#if NCCL_VERSION_CODE >= NCCL_VERSION(2,28,0)
// shared scalar AlltoAll implementation used by both kernels
template <typename T>
__device__ void AlltoAllScalarImpl(ncclWindow_t sendwin, size_t sendoffset, ncclWindow_t recvwin, size_t recvoffset, size_t count, int rank, int nRanks, int tid, int nthreads) {
Expand Down
Loading