GPU reset behavior on XGMI systems#

On AMD Instinct systems with XGMI-connected GPUs, a reset requested for one GPU can affect other devices depending on XGMI hive membership, PCIe topology, active peer-to-peer traffic, and platform firmware. Do not assume that amd-smi reset --gpureset provides per-GPU fault containment inside an XGMI hive.

For high availability, use OS-enforced access controls such as containers, cgroups, or VM passthrough to limit device access. Don’t rely on runtime visibility variables as a fault-isolation boundary.

What happens during GPU reset#

Single-GPU reset#

When recovery is performed for a GPU that is not part of an XGMI hive, the driver may be able to recover only the target device. The exact recovery sequence depends on the GPU generation, reset method, platform firmware, and driver version.

Hive-level effects#

If the GPU belongs to an XGMI hive, a reset can have effects beyond the selected device. Peer GPUs can be interrupted if the reset path requires XGMI link teardown, peer notification, or recovery of shared fabric state. Active peer-to-peer traffic can also cause peers to observe timeouts or link errors during recovery.

Don’t assume that amd-smi reset --gpureset provides per-GPU fault containment inside an XGMI hive. The actual blast radius depends on the GPU generation, reset method, driver path, firmware, PCIe topology, and workload traffic pattern.

KFD behavior during reset#

KFD manages compute queues and process GPU state via /dev/kfd. During recovery, KFD can evict queues and invalidate runtime state for affected devices. Applications should treat this as fatal for their ROCr/HIP contexts.

After recovery, applications must recreate all GPU state: queues, memory allocations, streams, and loaded kernels. The exact set of affected processes is driver- and platform-dependent.

Why ROCR_VISIBLE_DEVICES is not fault isolation#

Tip

ROCR_VISIBLE_DEVICES is a list of device indices or UUIDs that will be exposed to applications using user mode ROCm.

ROCR_VISIBLE_DEVICES and HIP_VISIBLE_DEVICES are userspace runtime filters. They do not create a kernel-enforced isolation boundary and do not change the underlying reset domain managed by the kernel driver.

A process restricted with ROCR_VISIBLE_DEVICES=0,1 can still be affected by reset recovery outside that visible set, depending on driver behavior and platform topology. Use OS-enforced access controls for workload isolation.

Handling reset events#

Affected processes should not rely on partial ROCr/HIP runtime recovery after a GPU reset. In general, they must:

  1. Close all GPU handles and ROCr/HIP contexts.

  2. Reopen /dev/kfd (by reinitializing the ROCr/HIP runtime).

  3. Reallocate device memory and reload kernel state.

Checkpointing GPU state to host memory before reset enables faster recovery but still requires full ROCr reinitialization.

Further reading#