Network IO: DMA, RDMA, GPUDirect and Magnum IO
How data moves between GPUs, NICs and storage without the CPU in the way, and the libraries (NCCL, UCX, NVSHMEM) that use those paths.
- Determine networking requirements for AI workloads.
- Identify and describe data center networking protocols and key concepts.
- Explain the purpose and benefits of a DPU in a data center.
A GPU can only compute as fast as data reaches it. In the traditional path, data from the network lands in CPU memory, the CPU copies it, then it is copied again to GPU memory. Every copy costs time and CPU cycles. NVIDIA’s Magnum IO is the umbrella for technologies that remove those hops. The blog covers the network part.
01DMA → RDMA → GPUDirect
- DMA (direct memory access): inside one machine, a device such as a NIC or GPU reads and writes memory without the CPU copying every byte. The CPU only sets up the transfer.
- RDMA (remote DMA): the same idea across machines. A NIC writes directly into another host’s memory over an RDMA network (InfiniBand, RoCE or iWARP), bypassing the remote CPU and OS. Zero-copy, low latency.
- GPUDirect RDMA: the NIC reads and writes GPU memory directly, so GPU memory on host A reaches GPU memory on host B with no stop in CPU memory on either side. Needs an NVIDIA GPU, driver support and an RDMA-capable NIC (ConnectX).
- GPUDirect Storage: the same direct path between GPU memory and NVMe or networked storage (see Storage).
The blog’s measured effect is large: GPU-to-GPU MPI latency between two nodes fell from about 26.6 µs to 3.4 µs with GPUDirect RDMA and GDRCopy, and an 8-adapter DGX A100 reached about 192 GB/s versus 71 GB/s without it.
| GPUDirect RDMA | GPUDirect Storage | GPUDirect P2P | |
|---|---|---|---|
| Path | GPU ↔ NIC ↔ remote GPU | GPU ↔ NVMe / network storage | GPU ↔ GPU in one node (NVLink or PCIe) |
| Main use | Low-latency multi-node training | Fast data loading and checkpoints | Intra-node exchange |
| Bypasses | CPU and system memory | CPU bounce buffer | CPU |
02Offloading the packet work: ASAP²
ASAP² (Accelerated Switch and Packet Processing) offloads Ethernet packet processing, such as virtual switching, into hardware. On ConnectX adapters the data plane is offloaded (match/action rules run in silicon). On BlueField DPUs, both the data plane and the control plane can run on the card, freeing the host entirely.
03The communication libraries
| Library | What it does |
|---|---|
| NCCL | Topology-aware collectives (AllReduce, AllGather, Broadcast, ReduceScatter) across GPUs and nodes; picks NVLink, PCIe or RDMA automatically; ring and tree algorithms; supports SHARP |
| UCX | Open-source communication layer that hides transport differences (InfiniBand, RoCE, TCP, NVLink, GPUDirect) behind one API |
| HPC-X | NVIDIA’s packaged MPI + UCX toolkit for HPC, including SHARP support |
| NVSHMEM | Lets GPU kernels initiate one-sided communication themselves, hiding latency without returning to the CPU |
| MPI | The classic HPC message-passing standard, GPU-aware when built with UCX/CUDA |
04Benchmarks to sense the scale
The blog shows NCCL AllReduce bandwidth rising from 48 GB/s on DGX-1 to 85 GB/s on DGX-2 and 192 GB/s on DGX A100, and NCCL’s tree algorithm tested up to 24,000 GPUs. The lesson for the exam: interconnect plus communication software is what lets training scale across nodes.
✦Key terms: flip the cards
- DMA (one host) → RDMA (across hosts) → GPUDirect RDMA (GPU memory across hosts) → GPUDirect Storage (GPU ↔ storage).
- ConnectX offloads the data plane; BlueField can offload data and control planes.
- NCCL is software that rides on NVLink/RDMA hardware.
- RDMA needs an RDMA-capable network: InfiniBand, RoCE or iWARP, not plain TCP.
- GPUDirect RDMA and GPUDirect Storage are different paths (network vs storage).
?Quick quiz
1. Which technology lets a NIC write directly into a remote GPU’s memory?
Why: GPUDirect RDMA moves data between GPU memory and the NIC without CPU copies.
2. What does RDMA bypass on the remote host?
Why: RDMA writes memory without involving the remote CPU or kernel.
3. Which library coordinates AllReduce across 100+ GPUs?
Why: NCCL provides topology-aware collectives.
4. On which device can both the data plane and control plane be offloaded?
Why: BlueField runs control-plane software on its Arm cores plus hardware data-plane offload.
Score: 0 / 4
This lesson explains the reading in plain language and adds the exam context around it. Read the original too: it is short, and seeing the vendor wording helps on exam day.