Manuscript Offprint
arXiv:2611.05751Scheduling Data to Compute: Hierarchical Data Pipelining for LLM Training on AMD GPUs
Gengyu Rao, Ghadeer Ahmed H Alabandi, Su Ann Chong, Thomas Huber, Kailash Gogineni, Subhajit Dutta Chowdhury, Saleel Kudchadker, Suchita Pati, Zirui Zhang, Zhen Huang, Yanyuan Qin, Xiaoming Peng, Lihuan Zhang, Botao Hu, Wei Huang, Yang Bo, Wen Xie, Xiangyu Zhao, Ruibin Zhang, Xiaobo Chen, Vidushi Goyal, Anshu Raina, Claire Songhyun Lee, Jiakun Yan, Yao Fu, Nusrat Islam, Ravi Dwivedula, Jie Zhang, Maria Garzaran, Zhenyu Gu, Emad Barsoum
Advanced Micro Devices, Inc.
Abstract
Large language models (LLM) have been the key focus of recent machine learning breakthroughs. As the model size grows exponentially, the computation needed for training is astronomical. A GPU can do a huge amount of arithmetic. However, the data its compute units need is not always available when they are ready. This data may still be in slow memory or on another GPU. While the chip waits, expensive compute sits idle, and at scale even a small drop in utilization translates into substantial cost. In this paper, we treat this waiting time as the primary bottleneck. We focus on hardware features designed for explicit data movement. These features load data from off-chip memory onto the chip, rearrange it into the layout the computation requires as it is loaded, and transfer it between GPUs. By orchestrating them, we keep a steady pipeline of data flowing to the compute units so that they remain busy.
We present kernel and framework implementations that address this bottleneck using three key data-movement instructions and hardware features. The Tensor Data Mover (TDM) moves tensor data from high-bandwidth memory (HBM) into on-chip memory. Transpose-load instructions transpose tensor data into the layout that LLM computations require as it is loaded on-chip. Finally, System DMA (SDMA) and Remote DMA (RDMA) move data between GPUs over the scale-up and scale-out networks, respectively. Our results show that TDM and transpose-load provide on average 1.88× and 1.19× speedup at the kernel level, respectively. The SDMA and RDMA lead to on average 1.16× and 1.33× speedup for computation overlapped with communication. This is the first AMD LLM training system to utilize all the GPU data pipelining features. Our implementation has been integrated into open source framework and library for AMD GPUs. https://github.com/AMD-AGI/Primus-Turbo https://github.com/AMD-AGI/Primus
1 Introduction
Recent years have witnessed an exponential surge in LLMs. People are training larger and larger models with an unprecedented amount of data. As the training grows exponentially, the amount of computation needed is unprecedented in human history. People are building larger and larger GPU clusters to train LLM models, due to both the model size and the amount of computation. There have been many reports on GPU under-utilization in the industry [13, 18, 19]. For hyper-scale users, even one percent of efficiency can mean millions of dollars. From a hardware perspective,
Rao et al.
under-utilization can arise from several sources, including hardware failures [15], power constraints [30], and data-movement overheads [14, 27], which become increasingly significant as models and distributed training systems scale.
In this paper, we focus on data-movement overhead as a source of GPU under-utilization. Within a GPU, compute units may stall while waiting for data or spend execution resources moving and transforming it. Across GPUs, communication may consume compute resources or delay dependent computation. We consider these two cases separately as intra-GPU and inter-GPU data movement.
Intra-GPU data movement. Traditional GPU programming emphasizes that GPUs hide long memory-access latency through inexpensive thread switching, i.e., scheduling more threads than the hardware can execute at once [26]. In recent years, however, software-managed data pipelines have become an increasingly important complementary approach to latency hiding.
A key driving force behind this shift is the co-evolution of GPU hardware architectures and kernel algorithm design. Consider attention kernels, underpinning the Transformer architectures central to recent breakthroughs in large language models (LLMs) [25]. Modern high-performance attention kernels largely follow the approach introduced by FlashAttention [11]: keeping the softmax state and output accumulators on-chip while streaming key and value tiles from memory. Although this approach avoids materializing the full attention matrix and significantly reduces global memory traffic, it introduces a new performance challenge of efficiently orchestrating data movement between global and on-chip memory. In particular, attention computation requires fine-grained scheduling of KV tile loading, data transformation, and computation to prevent memory latency from stalling the execution units.
On older GPU architectures, transferring data into on-chip memory requires explicit load instructions executed by threads on the compute units. As a result, data movement competes with computation for execution resources. While one group of threads waits for memory operations to complete, another group performs useful computation. However, this approach becomes increasingly challenging for attention kernels, where limited on-chip memory capacity and frequent data transfers demand tighter coordination between memory operations and computation.
Recent GPU architectures are beginning to address this challenge. For example, AMD's MI455 introduces the Tensor Data Mover (TDM), which moves data between HBM and on-chip memory. This not only allows software-managed data pipelines to be offloaded to hardware DMA engine, but also introduces new fine grain instruction set architecture (ISA) to coordinate between memory transfer and computation, fundamentally changing the optimization target from "launch enough threads to hide a high-latency load" to "build a steady stream that keeps the compute units fed."
A similar trend can be observed in data transformation. During LLM training, tensors frequently require different layouts for forward and backward computations, making matrix transposition an important source of overhead. On MI355, specialized matrix-transpose instructions allow data to be transposed during loading, eliminating the need for explicit register-level transposition by the compute units [1].
We will detail our implementation and the performance impact of these ISA changes in Section 3.1. Our implementation shows that matrix transpose leads to on average and up to . TDM leads to on average and up to .
Inter-GPU data movement. As large-scale LLM training expands to thousands of GPUs, inter-GPU data movement has become an increasingly important performance bottleneck. At first glance, overlapping communication with computation appears straightforward: ideally, network transfers proceed concurrently with GPU computation, achieving both high network bandwidth and high compute utilization. In practice, however, communication and computation often compete for the same GPU execution resources, making effective overlap much more challenging.
For example, traditional RCCL-based communication from AMD can occupy up to 64 compute
Rao et al.
units (CUs), corresponding to 25% of the compute resources on MI355. Consequently, even when communication is fully overlapped with computation, we can observe significant slowdown in compute throughput. This reveals a fundamental limitation of conventional GPU-driven communication: hiding communication latency does not necessarily eliminate its computational overhead.
One possible workaround is to increase the local batch size, thereby performing more computation per communication operation and amortizing communication overhead. However, this approach conflicts with the growing demand for faster distributed training. For customers renting GPU clusters in the cloud, time-to-train is often as important as overall hardware efficiency. For example, assuming near-linear scaling, training a model on more than 2,000 GPUs in two months may be preferable to training it on 1,000 GPUs over four months. Achieving such scaling requires maintaining high efficiency at smaller per-GPU batch sizes, where communication accounts for a larger fraction of execution time. Therefore, simply increasing the amount of local computation is not always a viable solution.
To address this challenge, AMD GPUs and Network Interface Cards (NICs) provide dedicated DMA engines for inter-GPU data movement, including System DMA (SDMA) and Remote DMA (RDMA). Unlike traditional communication kernels that consume GPU compute resources, these engines enable data transfers to proceed independently of the compute units, creating opportunities for more effective communication-computation overlap. To make these capabilities accessible, we have been introducing lightweight, DMA-based communication APIs across multiple layers of the ROCm software stack. These APIs expose dedicated data-movement engines through programmer-friendly interfaces, supporting both high-level collective operations in PyTorch and low-level, customized communication implementations.
We will provide detailed evaluation of overlapping overhead in Section 4.4 and detail our hardware support and software API in Section 3. Our results show that System and Remote DMA based optimization leads to on average 1.16× and 1.33× of overlapped computation with communication.
2.1 Attention Kernel
Attention is a core operation in modern large language models [25]. For a sequence of tokens, each attention head projects the input activations into the query, key, and value matrices and , where and denote the key/query and value dimensions, respectively. Scaled dot-product attention computes:
Most current implementations follow FlashAttention[11], as illustrated in Algorithm 0: It streams blocks of and through on-chip memory, updates the online softmax state, and output accumulator. This algorithm makes the timing of the streamed tiles critical and turns attention optimization into a tiled dataflow problem: we need to fetch each tile of and in time, so that the computing units are always busy.
To make this issue more complex, as the industry is starting to use longer and longer sequence lengths, more attention variants have been proposed to address the HBM memory bandwidth issue:
- Sparse Attention: It restricts each query to a selected subset of keys and values, and can also reduce memory traffic and computation.
Rao et al.
Algorithm 0: FlashAttention-style attention [11].
Require: , in HBM; query and key/value block sizes
1: Partition , and into blocks.
2: Initialize , , and .
3: for each key/value block do
4: Load from HBM into on-chip memory.
5: for each query block do
6: Load into on-chip memory.
7: On chip, use to update , and with online softmax normalization and .
8: Write the updated , and to HBM.
9: end for
10: end for
11: return
- Compressed Attention: It compresses token information, thereby reducing both memory traffic and computation.
The recent DeepSeek V4 model proposed Compressed Sparse Attention (CSA), which uses the two optimizations mentioned above [28]. This creates additional challenges to kernel implementation, as the dataflow is more irregular: Each query token receives a top- list containing a sliding-window component and, depending on the compression ratio, additional compressed latent vectors. The forward pass must gather those vectors, compute scores, and stream the corresponding values into the output accumulator. The backward pass is more demanding: it must gather the same sparse vectors to form , produce a per-token/per-slot intermediate for , and then reduce that intermediate by the inverse of the top- map [17, 28].
The kernel case study in this paper focuses on this new sparse attention algorithm, as it represents one of the most challenging data movement patterns in LLM training and represents a possible direction for the future evolution of attention algorithms.
2.2 Communication for LLM training
In recent years, as LLM sizes and architectures evolve, parallelism and communication pattern have also changed. The traditional parallelism strategy includes data parallelism and data sharding, including ZeRO sharding, FSDP [23, 31]. Correspondingly, the communication patterns are AllReduce, AllGather and ReduceScatter. Other forms of parallelism include tensor parallelism (TP) [24], context parallelism (CP) [20], etc. As the MoE architecture has become more popular, targeting parallelism and communication patterns have also emerged (e.g., DeepEP [29] and the All2All communication), also more recently MegaMoe kernel [12], which fused communication with computation. In this paper, we focus on the traditional FSDP pattern. MoE patterns have been studied by previous AMD work [2, 3].
3 AMD GPU architecture features and workload implementations
In this section, we will outline AMD GPU architecture features, and how we utilized them in our kernel and framework implementation. Since this paper is focused on case studying GPU architecture from a workload perspective, we will focus on the ISA and API exposed to the user, instead of in-depth discussion of the hardware design itself.
Rao et al.

Figure 1: Simplified memory hierarchy of AMD CDNA5 GPU [4].
Table 1: ROCm and CUDA GPU programming terminology [4, 21].
| ROCm term | Similar term | CUDA Meaning |
|---|---|---|
| Work-item | Thread | One logical execution flow of a kernel. |
| Wave | Warp | A collection of 32 work-items/threads that execute in parallel. MI455 (CDNA5) supports 32 threads; the earlier MI355 (CDNA4) supports 64 threads |
| Workgroup | Thread block | A collection of waves/warp that can synchronize with each other using barriers; |
| Local Data Share (LDS) | Shared memory | A multi-bank on-chip scratch memory allocated to waves or work-groups. |
| Vector General Purpose Registers (VGPR) | Register | Per-work-item register storage, allocated from hardware register resources. |
| Tensor Data Mover (TDM) | Tensor Memory Accelerator (TMA) | DMA transfers of matrix/tensor data. |
| SIMD/Compute Unit (CU)/Work-group Processor (WGP) | Streaming Multi-processor (SM) | A hardware unit that executes workgroups. In MI455, each WGP consists of two CU and four SIMD. Every SIMD can execute a wave of 32 threads. |
3.1 Intra-GPU data movement
The AMD GPU architecture is illustrated in Figure 1. Table 1 compares the ROCm terms used in this paper with the closest CUDA terminology. The correspondences explain programming roles, rather than claiming that the underlying hardware implementations are identical. Since CUDA programming is more popular in GPU research literature, we will use these terms interchangeably in this paper.
For our memory hierarchy, the Local Data Share (LDS) is a low-latency on-chip memory shared by the threads (Work-item) in a workgroup. A kernel uses LDS to stage and reuse a tile that would otherwise be read repeatedly from HBM; threads (Work-items) coordinate accesses with workgroup barriers. LDS is allocated per workgroup, so its contents are not visible to other workgroups.
Specialized ISA and hardware have been introduced on AMD GPU to handle data-movement
Rao et al.
Table 2: TDM ISA/intrinsic [4].
| ISA/intrinsic | Purpose |
|---|---|
| TENSOR_LOAD_TO_LDS | Load data from HBM to on-chip memory |
| TENSOR_STORE_FROM_LDS | Store data from on-chip memory to HBM |
| TENSORCNT | Counts the number of matrix (tensor) transfers outstanding but not yet completed |
| S_WAIT_TENSORCNT | Waits until number of unfinished transfers is less-than or equal-to specified value |
operations. These include matrix transposing ISA and Tensor Data Mover (TDM), both would free the useful compute cycle from data-movement operations.
3.1.1 Tensor Data Mover
Table 2 shows the ISA/intrinsic provided by MI455 for moving data between HBM and on-chip memory. TENSOR_LOAD_TO_LDS and TENSOR_STORE_FROM_LDS are used to load and store data from HBM to on-chip memory (LDS) and from LDS to HBM, respectively. These DMA engines are aware of the tensor data structure: they are able to fetch data based on tensor dimensions and can also pad the data to resolve LDS bank conflicts.
TENSORCNT counts the number of matrix (tensor) transfers outstanding but not yet completed. S_WAIT_TENSORCNT waits until the number of outstanding TDM transfers is not greater than the specified threshold. For a pipeline of depth N, we can start the pipeline with N+1 tensor loads and simply check S_WAIT_TENSORCNT with N. Because tensor-movement instructions complete in-order with other Tensor instructions from the same wave (both loads and stores stay in-order), we can ensure the data is ready without worrying about memory transfer ordering [4].
The important programming property is that the gather is not expressed as a loop of vector global loads into LDS. And the programming mindset changes from “launch enough workgroups to hide a high-latency load” to “build a steady stream that keeps the compute pipeline fed.” This also lowers the occupancy and frees more registers for the kernels, so more data can be reused in registers.
In addition, TENSOR_LOAD_TO_LDS also supports sparse gather. One load instruction takes up to eight 32-bit or sixteen 16-bit indices. The TDM engine fetches each indexed memory range from the HBM and writes them to LDS. Padding can also be added via this instruction to resolve bank conflicts.
This matches the sparse attention algorithm directly, because the top- list of a token is exactly a list of KV row indices. Our kernels read eight indices with one scalar load and pass them to TENSOR_LOAD_TO_LDS. Without gather mode, the same load would require a loop of per-lane address computation and explicit load instruction from HBM to LDS. This would waste both registers and execution resources that the computation needs.
We used these ISA to construct our Compressed Sparse Attention (CSA) kernels. The CSA attention has three variants: cr0, cr4, and cr128 stand for compression ratios of 0, 4 and 128. Please refer to Table 7 for further explanation.
The forward kernel uses TDM to stream tiles from the top- key-value entries: it uses TENSOR_LOAD_TO_LDS with a vector of addresses to KV tiles and an LDS destination, then syncs via S_WAIT_TENSORCNT before consuming the completed tile. For each token, the kernel first issues TDM load for the KV tiles, then computes the and on the earlier tile, meanwhile issues TDM load for a later tile.
Rao et al.
Table 3: Attention kernel computes and layout in training
| Pass | Operation | Tile shapes | Transposed operand |
|---|---|---|---|
| Forward | Scores | ||
| Backward | Query gradient | none | |
| Backward | Key gradient |
For the cr0 / cr128 sliding-window kernels, the tiles are reused across tokens: consecutive tokens attend to almost the same window rows, so a workgroup owns a block of consecutive tokens, gathers their shared window (and, for cr128, the compressed pool) into LDS once with TDM, and each token reads its 128 window rows at its own offset instead of gathering them again.
For cr0 / cr128 with short top-, our kernel implementation makes the workgroup persistent across tokens: the global tile index continues across token boundaries. This removes part of the per-token prologue from the critical path. For cr4 with a longer top-, the prologue is already amortized, so our kernel implementation with a straight-forward token-fixed kernel already achieves good hardware utilization. The persistent kernel leads to additional overhead.
The backward kernel uses TDM in the same way, with some backward-specific changes. We will evaluate TDM's impact on kernel performance in Section 4.3.1.
3.1.2 Matrix Transposing
For transposing, Table 4 shows the ISA interface used by our kernels. For MI455, all the 32 threads in a wave/warp will execute the ds_load_tr16_b128. In total, they will load and transpose a matrix of 16-bit data. We directly use the transpose-load ISA when feeding tensor fragments from on-chip memory to registers.
Without this transpose-load ISA, we have to use XOR-based register shuffle to match the Matrix Multiply Accumulate operand layout, which wastes both register resources and compute cycles. Or we will have to use strided-load from on-chip memory into register, which will waste bandwidth from on-chip memory to registers. Table 5 shows the kernel implementation with and without transpose load support.
This data transposing is a challenge for data movement in LLM training and is less a problem in LLM inference. As in inference, we can pre-transpose weight tensors offline for direct computation at runtime. However, training performs both forward and backward passes and uses different layouts. To explain the training process, we list part of the attention tensor layout in Table 3. For example, even if we may transpose the data in forward pass for direct computation, in the backward pass, we will still have to transpose it back.
We will also evaluate its performance impact in Section 4.3.2. Even though we only discussed the attention kernel, the same ISA also applies to kernels like GEMM.
3.2 Inter-GPU communication
In a typical GPU cluster, there are two types of GPU networks: scale-up and scale-out networks. They differ in terms of physical distance and communication bandwidth/latency.
Scale-up networks are often used to connect GPUs within a server rack/blade, which are physically close and enjoy better network bandwidth (per GPU) and latency.
Scale-out networks are used to connect GPUs across server racks or blades. Due to the signal integrity and power issues caused by physical distance, the scale-up network technology usually does
Rao et al.
Table 4: Transpose-load ISA / intrinsic [1, 4].
| GPU | ISA / intrinsic | Transpose load size | Description | |
|---|---|---|---|---|
| MI355X | ds_read_b64_tr_b16 | 64-bits thread | per | Used for either column major matrix A or row major matrix B data load to 2 VGPRs. Element size is 16b. Two instruction load a complete matrix |
| MI455X | ds_load_tr16_b128 | 128-bits thread | per | Load a 16 × 16 matrix of 16-bit data into VGPRs and transpose between row-major and column-major order. This instruction loads data into 4 consecutive VGPRs. A wave/warp of 32 threads moves 32 × 128 bits. |
Table 5: matrix transpose with / without LDS transpose load.
| Manual transpose in registers | Transpose-load ISA |
|---|---|
| rows = lds_load(tile_ptr)tmp0 = xor_permute(rows, 1)tmp1 = xor_permute(tmp0, 2)tmp2 = xor_permute(tmp1, 4)b_frag = pack_wmma_operand(tmp2)acc = wmma(a_frag, b_frag, acc) | b_frag = lds_load_tr16(tile_ptr)acc = wmma(a_frag, b_frag, acc) |
not apply [16]. In a typical GPU cluster, the scale-out bandwidth per GPU is much smaller than the scale-up bandwidth, and the latency is also typically higher.
In this section, we will first discuss inter-GPU communication within a scale-up domain, then we will extend to scale-out communication.
3.3 Scale-up domain: System DMA (SDMA)
In traditional communication implementation within a scale-up domain, as shown in Figure 2, a communication would begin with GPU threads reading from local HBM (as shown in Step 1), and writing through the scale-up fabric (as in Step 2). The remote GPU's Coherence Station (CS) will write into a staging buffer in the HBM (as in Step 3). Then the remote GPU threads will be used to read the data from staging buffer and write into the destination buffer (as in Step 4 and 5). This design would waste a significant amount of GPU threads / compute units, preventing them from doing useful computation. In MI355, by default, the wasted Compute Units will be 25% of the total Compute Units (64 out of 256).
From a power perspective, this implementation triggers unnecessary data movement across chiplets, which leads to increased power usage. AMD GPUs provide dedicated on-chip units called SDMA engines to handle those data movement. Previous AMD research [22] showed that this data movement offloading can reduce GPU power usage. This is very important because, during LLM training, we found that the compute and communication may compete for power: When the DMA transfer began, we observed drops in the compute-die frequency and power.
These DMA engines can be initiated by either GPU or CPU: For CPU programming, those SDMA engines are exposed to user through the HIP APIs hipMemcpyBatchAsync and hipMemcpyAsync. For GPU programming, they are ready to use via ROCm libraries: RCCL (GIN mode), MORI and rocSHMEM [5–7].
Rao et al.
Listing 1: Pseudo PyTorch code for customized communication using SDMA.
import torch.distributed as dist
import torch.distributed._symmetric_memory as symm_mem
options = dist.ProcessGroupNCCL.Options()
cta_policy = 2 # zero-CTA
_SDMA_GROUP = dist.new_group(
ranks=list(range(dist.get_world_size()))),
backend="nccl",
pg_options=options,
group_desc=f"SDMA_demo",
)
symm_mem.set_backend("NCCL")
symm_mem.enable_symm_mem_for_group(_SDMA_GROUP)
dist.barrier(group=group)
pool = symm_mem.get_mem_pool(device)
with torch.cuda.use_mem_pool(pool):
storage = torch.empty(size_bytes, dtype=torch.uint8, device=device)
torch.distributed.all_gather_into_tensor(
output,
local_input,
group=group,
async_op=True,
)
To use this DMA feature in LLM training, before initiating those DMA transfers, we will first need to let the DMA engine know where the remote memory physically locates. To do this, we will first need to allocate a local memory and obtain its handle, then we will need to transfer the handle to remote GPU and let the remote GPU maps the address to its virtual address.
For user simplicity, all those processes are hidden under different ROCm and PyTorch stacks. For PyTorch users, people will only need to register the memory buffer via the symmetric memory API, which would handle the underlying memory mapping. Then the DMA based communication can be triggered for data write/read on those mapped remote memory.
For users who want to define their own parallelism and communication pattern, the whole process can be easily implemented via tens of lines of PyTorch code, as illustrated in Code 1. For users who want to directly use the FSDP parallelism, this process has been fully integrated into the PyTorch framework and can be easily enabled by a few lines, as illustrated in Pseudo Code 2. All the latest PyTorch release builds for AMD GPU should have this function ready to use.
Listing 2: PyTorch FSDP using SDMA.
from torch.distributed.fsdp._fully_shard._fsdp_collectives import SymmMemAllGather
fsdp_module.set_custom_all_gather(SymmMemAllGather(pg, backend))
We've integrated these new DMA based communication into our LLM training framework. Users can enable the DMA based communication for LLM training via simple ENV flags. We will evaluate them in section 4.
3.4 Scale-out domain: Remote DMA (RDMA)
Different from the scale-up domain, in the scale-out domain, the GPU cannot directly access each other's memory and must rely on the Network Interface Card (NIC) to perform the data transfer operation. The DMA transfer in the scale-out domain is called RDMA. To enable GPU initiated
Rao et al.

Figure 2: RCCL communication collective memory access illustration.
communication, AMD has implemented GPU Initiated Networking (GIN) via CPU proxy threads, which will work as a delegate for the GPU to initiate the RDMA transfer.
Recent AMD works have enabled chaining SDMA and RDMA to perform communication across scale-up and scale-out domains. Figure 3 shows a typical GPU cluster networking topology. In GPU networking, GPUs on the same index across different nodes are called as on the same "rail". The hierarchical DMA transfer can be explained as below: All the GPUs on the same "rail" will first perform RDMA transfer (as dotted lines in the figure). And then, each GPU will use local SDMA to broadcast the data it received (as the solid line in the figure). For large data transfer, this RDMA and SDMA will be overlapped, as each GPU sends chunked data as pipeline via RDMA and SDMA at the same time. Thus, all the scale-up and scale-out network bandwidth can be utilized.
The complexity has been hidden from users within the ROCm stack, and users can directly utilize the feature via the same PyTorch interface mentioned in the Scale-up section.
4 Evaluation
4.1 Hardware platform
We implement our performance optimizations in Primus [9] and Primus-Turbo [8] to maximize GPU utilization, enhance computational efficiency, and accelerate large-scale AI model training on AMD GPUs. We evaluate these optimizations on two AMD GPU architectures, MI455 and MI355, whose hardware specifications are compared in Table 6.
For Intra-GPU ISA, we evaluate on MI455, as it supports all the data moving ISA we mentioned above. All the MI455 results below are collected from bring-up platform. As the MI455 platform continues to undergo performance optimizations, the reported results reflect the best implementations available at the time of evaluation and should be interpreted as a point-in-time snapshot rather than definitive performance limits. For Inter-GPU communication, we will evaluate on MI355, which is currently widely used in industry.
Rao et al.

Figure 3: Example GPU cluster networking topology.
Table 6: MI455 vs MI355 architecture feature comparison [1, 4].
| GPU | TDM | Transpose load | SDMA |
|---|---|---|---|
| MI455 | Yes | Yes | Yes |
| MI355 | No | Yes | Yes |
Table 7: Compressed Sparse Attention (CSA) config in DeepSeek V4 architecture. Every query attends to a 128-token sliding window plus the listed compressed-pool rows; T represents sequence length.
| Family | Ratio | Heads | Top-k | Pool rows per query |
|---|---|---|---|---|
| Flash | cr0 | 64 | 128 | none |
| Flash | cr4 | 64 | 640 | top-512 of T/4 |
| Flash | cr128 | 64 | 128 + T/128 | all visible of T/128 |
| Pro | cr0 | 128 | 128 | none |
| Pro | cr4 | 128 | 1152 | top-1024 of T/4 |
| Pro | cr128 | 128 | 128 + T/128 | all visible of T/128 |
4.2 Workload selection
For Intra-GPU data movement ISA evaluation, we focus on Compressed Sparse Attention (CSA) attention, as used in DeepSeek V4 architecture. We choose it due to 1) it is demonstrates a trend for modern LLM architecture. 2) it provides more engineering complexity, as the sparse attention mechanism requires more irregular data movement. The kernel configurations are shown in table 7.
Per company policy, we will only show the relative speedup. The relative speedup should be able to demonstrate the benefit of those ISA and hardware features.
Rao et al.
Table 8: TDM-enabled Compressed Sparse Attention (CSA) kernel speedup over the best non-TDM implementation (higher is better).
| Family | Ratio | Forward | Backward | Step | |
|---|---|---|---|---|---|
| Flash | cr0 | 4K | |||
| 8K | |||||
| 16K | |||||
| cr4 | 4K | ||||
| 8K | |||||
| 16K | |||||
| cr128 | 4K | ||||
| 8K | |||||
| 16K | |||||
| Pro | cr0 | 4K | |||
| 8K | |||||
| 16K | |||||
| cr4 | 4K | ||||
| 8K | |||||
| 16K | |||||
| cr128 | 4K | ||||
| 8K | |||||
| 16K | |||||
| Geometric mean | |||||
4.3 Intra-GPU data pipelining evaluation
4.3.1 Tensor Data Mover (TDM) feature impact analysis
We evaluated our best Compressed Sparse Attention (CSA) kernel implementations with and without TDM. The non-TDM baseline loads the selected KV rows with explicit load instruction from HBM to LDS, and run two waves per SIMD to hide the load latency. (Please refer to Table 1 for the SIMD definition on AMD GPU architecture). Both versions are measured on the same MI455X with the same set of kernel configurations (flash and pro, cr0 / cr4 / cr128, ). The results are shown in Table 8. The TDM-enabled design leads to an average (geometric mean) speedup of the training step (forward + backward) and up to speedup; the forward alone gains on average () and the backward ().
To explain this speedup, we further analyze the kernel difference in Table 9. The source of speedup is the register resource TDM frees. Without TDM, the memory load exposes latency. And this latency is hidden by occupancy: two waves per SIMD, so each wave is capped at 512 VGPRs and owns 16 heads. With TDM, the gather writes the selected rows directly into a multi-stage LDS ring buffer and the wave only waits on S_WAIT_TENSORCNT, so the kernels drop to one wave per SIMD and give each wave up to 1024 VGPRs. This change enables a deeper pipeline and higher data reuse in the register.
MI455 architecture also introduces an asynchronous load instruction from HBM to LDS, GLOBAL_LOAD_ASYNC_TO_LDS. We also tested this implementation. We were unable to achieve results better than our non-TDM baseline.
4.3.2 Transpose load ISA feature impact analysis
To evaluate the transpose-load ISA, we first study the effective bandwidth of the transpose load operation. The original kernels read every transposed operand with ds_load_tr16_b128. We implemented two replacements that produce the same transpose without the transpose-load ISA:
Rao et al.
Table 9: VGPRs per wave of the non-TDM and TDM CSA kernels.†spills VGPRs; ‡spills on cr128 only.
| Design (waves/SIMD) | Kernel | Forward | Backward | ||
|---|---|---|---|---|---|
| Flash | Pro | Flash | Pro | ||
| Non-TDM (2) | 511 | 431 | 462 | ||
| TDM (1) | cr4 | 910 | 954 | 730 | 1004 |
| cr0/cr128 | 1024 | 1024 | |||
Table 10: LDS-to-register bandwidth comparison, normalized to a plain ds_load_b128 (no transpose); higher is better.
| Load | Normalized bandwidth |
|---|---|
| ds_load_b128 (no transpose) | 1.00 |
| ds_load_tr16_b128 | 0.99 |
| 8× strided ds_load_u16 | 0.63 |
| ds_load_b128 + XOR shuffle | 0.41 |
One with XOR register-shuffle as shown in Table 5. The other uses strided LDS loads. We measured the kernel bandwidth and show the results in Table 10. We can see that the strided LDS loads reach 0.63× of the roof-line bandwidth achieves by direct loading, and the XOR register-shuffle version achieves 0.41×. The bandwidth difference is due to the micro-architecture throughput limits.
To evaluate the transpose-load ISA impact on the kernel level, we take the TDM-enabled kernels above and change only how transposed operands are read from LDS. Since the above analysis showed strided-load provides best bandwidth, we used it to replace the original transpose-load instructions ds_load_tr16_b128 in the kernels.
Table 11 shows the kernel-level result. Excluding the register spilled kernels, the transpose load ISA speeds up the training step by 1.19× on average (geometric mean) and by up to 1.21×; The speedup is due to the transposed-load bandwidth discussed above: the transpose load provides higher bandwidth than strided-load.
The additional spills are due to the strided-load implementation: Temporary registers will be used to store the strided-load data. Those data will then be packed back. Between the loads and the packing, there will be additional registers compared to a transpose-load implementation. This implementation is enforced by the compiler, and is the best viable implementation we can reasonably achieve. Implementing the kernel directly in assembly code might reduce the overhead, but the LDS-to-register bandwidth overhead we demonstrated in Table 10 is a micro-architecture limitation. Regardless, the non-spill kernel results in Table 11 should demonstrate the impact of transpose-load ISA on this attention algorithm.
4.4 Inter-GPU data pipelining evaluation
For Inter-GPU data pipelining, we will use MLperf dataset, in particular the LLama 3.1 8B, GPTOSS 20B, and FLUX.1-Schnell models as listed in Table 12.
4.4.1 Communication collective micro benchmark
We first evaluate the GEMM performance when overlapped with SDMA-based or traditional Compute Unit (CU) based RCCL communication collectives. GEMM shapes used are from Llama3 8B training. Table 13 shows the relative slow down. On average, when overlapped with CU-based
Rao et al.
Table 11: Transpose-load-ISA-enabled kernel speedup vs strided-load version (higher is better). †The strided-load casued spills VGPRs.
| Family | Ratio | Forward | Backward | Step | |
|---|---|---|---|---|---|
| Flash | cr0 | 4K | |||
| 8K | |||||
| 16K | |||||
| cr4 | 4K | ||||
| 8K | |||||
| 16K | |||||
| cr128 | 4K | ||||
| 8K | |||||
| 16K | |||||
| Pro | cr0 | 4K | |||
| 8K | |||||
| 16K | |||||
| cr4 | 4K | ||||
| 8K | |||||
| 16K | |||||
| cr128 | 4K | ||||
| 8K | |||||
| 16K |
Table 12: Selected MLperf dataset.
| Workload | Model | #GPU | Scale-up/-out |
|---|---|---|---|
| LLama 3.1 8B | LLM | 8 | Scale-up |
| GPTOSS 20B | LLM | 8 | Scale-up |
| FLUX.1-Schnell | Diffusion | 8 | Scale-up |
Table 13: GEMM runtime increase while overlapped with collectives, relative to the same GEMM runs alone.
| GEMM(MNK) | AllGather | ReduceScatter | ||
|---|---|---|---|---|
| CU | SDMA | CU | SDMA | |
| 46% | 16% | 64% | 15% | |
| 29% | 3.3% | 44% | 13% | |
| 15% | 3.6% | 15% | 7.3% | |
| 23% | 9.6% | 23% | 20% | |
| Geometric mean | 28% | 8.0% | 35% | 14% |
implementation, GEMM performance degraded by 28% and 35% for AllGather and ReduceScatter. But for SDMA-based implementation, the regression is only 8% and 14%. This is aligned with our overhead analysis. The RCCL uses 25% of the total Compute Units for communication. The higher regression for ReduceScatter is expected, as the collective relies on Compute Unit to perform the reduction. For SDMA-based ReduceScatter, the SDMA engine will move the data from remote to local, and a local persistent kernel will be used to perform the reduce operation.
4.4.2 Scale-up domain evaluation
We compare the training throughput for LLama 3.1 8B, GPTOSS 20B and FLUX.1 models with and without SDMA based communication. The throughput speedup is shown in column in Table
Rao et al.
Table 14: Training speedup with SDMA vs. non-SDMA. AG stands for AllGather, RS for ReduceScatter, for Speedup. † Flux workload only enabled AllGather SDMA.
| Model | AG(%) | RS(%) | (%) | Regional |
|---|---|---|---|---|
| Llama3.1 8B | 6.2 | 9.1 | +2.1 | 1.16× |
| GPT-OSS 20B | 13.5 | 14.6 | +4.5 | 1.18× |
| FLUX.1 | 22.0† | +3.1 | 1.16× |
Table 15: GEMM runtime increase while overlapped with AllGather on 8, 16, and 32 GPUs, relative to the same GEMM run alone.
| GEMM(MNK) | 8 GPUs | 16 GPUs | 32 GPUs | |||
|---|---|---|---|---|---|---|
| CU | DMA | CU | DMA | CU | DMA | |
| 32k×16k×16k | 11% | 4.8% | 31% | 4.0% | 34% | 3.7% |
| 32k×18k×16k | 9.3% | 3.5% | 30% | 3.1% | 32% | 3.4% |
| 32k×16k×52k | 12% | 5.0% | 54% | 4.0% | 58% | 3.9% |
| 32k×104k×16k | 12% | 4.0% | 36% | 4.0% | 36% | 4.2% |
| Geometric mean | 11% | 4.3% | 37% | 3.8% | 39% | 3.9% |
- In the same table, we also list the communication breakdown. AG and RS columns represent the AllGather and ReduceScatter percentage of the stabilized training iteration. The sum of AG and RS represents the total percentage of overlapped communication with computation. Based on Amdahl's Law [10], this translates into an average 1.16× speedup of the overlapped regions.
4.4.3 Scale-out domain evaluation
We are still integrating the hierarchical System and Remote DMA based communication collectives into our training workload. To show our early results, we repeat the GEMM overlap microbenchmark on 8, 16, and 32 MI355 GPUs (i.e., one, two, and four nodes of 8 GPUs each). The GEMM shapes are from Llama 3.1 405B training. Table 15 shows the relative GEMM slowdown.
With DMA-based collectives, the regression stays between 3.8% and 4.3%, since neither the scale-up nor the scale-out use Compute Units for data movement.
With CU-based collectives, the regression grows from 11% on a single node to 37% and 39% on 16 and 32 GPUs. On 16 and 32 GPUs, this makes the overlapped GEMM on average 1.33× faster with hierarchical SDMA and RDMA than with CU-based collectives.
5 Related works
AMD GPU also provides other data-pipelining ISA and features, such as prefetching from HBM to different cache layers. This feature has already been utilized in our kernel implementation. TDM can move data from HBM of other GPUs in the scale-up network to the on-chip memory of the local GPU, and vise versa. Recent AMD work has enabled using TDM for tightly-coupled communication and computation, such as DeepEP and MegaMoE kernels.
6 Future works
Recent AMD work has been exploring reverse offloading for GPU communication, which utilizes proxy threads on the host CPU to initiate network operations. This gives us a new low overhead programming method for implementing GPU communications that are coupled with computation.
Rao et al.
We will explore this method to implement DeepEP and MegaMoE kernels. We will also continue to explore hierarchical System and Remote DMA based communication collectives and integrate it to our LLM training framework.
7 Conclusion
This paper presents data pipelining features of AMD GPU. The Tensor Data Mover (TDM) moves tensor data from HBM to on-chip memory. Transpose-load instructions transpose tensor data into the layout that LLM computations require as it is loaded on-chip. System DMA and Remote DMA move data between GPUs over the scale-up and scale-out networks.
We show that these data pipelining features enables a rethinking about GPU efficiency. We need to schedule the data movement across the GPU system (e.g., from HBM to on-chip memory and between local and remote HBM) in time, so the compute units are always busy and not wasted for waiting or moving the data. It is also infeasible to prefetch everything needed to the closest memory hierarchy. The on-chip memory and HBM capacity are too small compared to the huge memory capacity needed for LLM training.
We utilize these features in our library and framework implementations for LLM training. Our evaluations show speedup on average 1.88× for TDM, 1.19× for Transpose-load. For overlapped compute with communication, 1.16× for System DMA and 1.33× for Remote DMA.
References
[1] AMD. CDNA4 Instruction Set Architecture Reference Guide, July 2025.
[2] AMD. Primus-Turbo: Mega MoE. https://github.com/AMD-AGI/Primus-Turbo/blob/main/docs/README_Mega_MoE.md, 2025.
[3] AMD. ROCm/DeepEP. https://github.com/ROCm/DeepEP, 2025.
[4] AMD. CDNA5 Instruction Set Architecture Reference Guide, July 2026.
[5] AMD. MORI (Modular RDMA Interface). https://github.com/rocm/mori, 2026.
[6] AMD. ROCm Communication Collectives Library (RCCL). https://rocm.docs.amd.com/projects/rcc1/en/latest/, 2026.
[7] AMD. The ROCm OpenSHMEM (rocSHMEM). https://rocm.docs.amd.com/projects/rocSHMEM/en/develop/, 2026.
[8] AMD-AGI. Primus-Turbo: A high-performance acceleration library for large-scale model training on amd gpus, 2025. URL https://github.com/AMD-AGI/Primus-Turbo. GitHub repository.
[9] AMD Brain-TIO (Training and Inference Optimization) Team. Primus: A unified training framework for large models on amd gpus, 2025. URL https://github.com/AMD-AGI/Primus.
[10] Amdahl, G. M. Validity of the single processor approach to achieving large scale computing capabilities. In Proceedings of the April 18-20, 1967, spring joint computer conference, pp. 483–485, 1967.
Rao et al.
[11] Dao, T., Fu, D., Ermon, S., Rudra, A., and Ré, C. Flashattention: Fast and memory-efficient exact attention with io-awareness. Advances in neural information processing systems, 35: 16344–16359, 2022.
[12] DeepSeek. DeepGEMM. https://github.com/deepseek-ai/DeepGEMM, 2026.
[13] Gangidi, A., Kishore, K., and Lee, J. How Meta trains large language models at scale. https://engineering.fb.com/2024/06/12/data-infrastructure/training-large-language-models-at-scale-meta/, 2024.
[14] Ivanov, A., Dryden, N., Ben-Nun, T., Li, S., and Hoefler, T. Data movement is all you need: A case study on optimizing transformers. In Proceedings of Machine Learning and Systems, volume 3, 2021.
[15] Kokolis, A., Kuchnik, M., Hoffman, J., Kumar, A., Malani, P., Ma, F., DeVito, Z., Sengupta, S., Saladi, K., and Wu, C.-J. Revisiting reliability in large-scale machine learning research clusters. In 2025 IEEE International Symposium on High Performance Computer Architecture (HPCA), pp. 1259–1274, 2025. doi: 10.1109/HPCA61900.2025.00096.
[16] Lee, K., Bayani, Y., Sharif, A., and Song, Y. J. Inside Prometheus: Meta’s Journey to a Gigawatt-Scale Supercluster. https://engineering.fb.com/2026/10/19/data-center-engineering/inside-prometheus-meta-gigawatt-scale-supercluster/, 2026.
[17] Liu, A., Mei, A., Lin, B., Xue, B., Wang, B., Xu, B., Wu, B., Zhang, B., Lin, C., Dong, C., et al. Deepseek-v3. 2: Pushing the frontier of open large language models. arXiv preprint arXiv:2512.02556, 2025.
[18] Lu, Y., He, D., Ma, T., Liu, Z., Ruan, L., Jiang, J., and Wu, Y. Bridging the gpu utilization gap: Predictive multi-dimensional resource scheduling for ai workloads. In Proceedings of the 21st European Conference on Computer Systems, pp. 383–399, 2026.
[19] Makin, Y. and Maliakkal, R. Sustainable ai training via hardware-software co-design on nvidia, amd, and emerging gpu architectures. In 2025 IEEE International Conference on Service-Oriented System Engineering (SOSE), pp. 204–215. IEEE, 2025.
[20] Niu, Y., Xiao, H., Liu, D., Zhou, W., and Li, J. Efficient scaling of llm training with flexible context parallelism, 2026. URL https://arxiv.org/abs/2602.21788.
[21] NVIDIA Corporation. CUDA Programming Guide, July 2026.
[22] Pal, S., Aga, S., Pati, S., Islam, M., and John, L. K. Design space exploration of dma based finer-grain compute communication overlap. arXiv preprint arXiv:2512.10236, 2025.
[23] Rajbhandari, S., Rasley, J., Ruwase, O., and He, Y. Zero: Memory optimizations toward training trillion parameter models. In SC20: international conference for high performance computing, networking, storage and analysis, pp. 1–16. IEEE, 2020.
[24] Shoeybi, M., Patwary, M., Puri, R., LeGresley, P., Casper, J., and Catanzaro, B. Megatron-lm: Training multi-billion parameter language models using model parallelism. arXiv preprint arXiv:1909.08053, 2019.
[25] Vaswani, A., Shazeer, N., Parmar, N., Uszkoreit, J., Jones, L., Gomez, A. N., Kaiser, L., and Polosukhin, I. Attention is all you need. Advances in neural information processing systems, 30, 2017.
Rao et al.
[26] Volkov, V. Understanding latency hiding on GPUs. University of California, Berkeley, 2016.
[27] Wang, G., Qin, H., Jacobs, S. A., Wu, X., Holmes, C., Yao, Z., Rajbhandari, S., Ruwase, O., Yan, F., Yang, L., and He, Y. ZeRO++: Extremely efficient collective communication for large model training. In International Conference on Learning Representations, 2024.
[28] Xu, A., Lin, B., Xue, B., Wang, B., Xu, B., Wu, B., Zhang, B., Lin, C., Dong, C., Ling, C., et al. Deepseek-v4: Towards highly efficient million-token context intelligence. arXiv preprint arXiv:2606.19348, 2026.
[29] Zhao, C., Zhou, S., Zhang, L., Deng, C., Xu, Z., Liu, Y., Yu, K., Li, J., and Zhao, L. Deepep: an efficient expert-parallel communication library. https://github.com/deepseek-ai/DeepEP, 2025.
[30] Zhao, D., Samsi, S., McDonald, J., Li, B., Bestor, D., Jones, M., Tiwari, D., and Gadepally, V. Sustainable supercomputing for ai: Gpu power capping at hpc scale. In Proceedings of the 2023 ACM Symposium on Cloud Computing, 2023. doi: 10.1145/3620678.3624793.
[31] Zhao, Y., Gu, A., Varma, R., Luo, L., Huang, C.-C., Xu, M., Wright, L., Shojanazeri, H., Ott, M., Shleifer, S., et al. Pytorch fsdp: experiences on scaling fully sharded data parallel. arXiv preprint arXiv:2304.11277, 2023.
A AI tool usage
The ROCm software, including our work, has been integrating AI tools throughout the development cycle. This includes internal and external AI models and tools. For example, Cursor, TraceLens, GEAK, Hyperloom, Claude Code. Those tools have been used to generate codes, perform testing and debugging.
For this paper, We also used AI tools to generate benchmarking scripts and schedule GPU jobs on our cluster.
For paper writing, we used the AI tool to check for grammar errors, polish language and content, and brainstorm better ways to present our ideas.