Skip to content

Commit 4e5afdc

Browse files
authored
Add HWLOC_KEEP_NVIDIA_GPU_NUMA_NODES=0 to MPS wrapper script to avoid GPU NUMA nodes (#179)
1 parent 4ac8b3d commit 4e5afdc

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

docs/running/slurm.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -300,8 +300,10 @@ if [[ $SLURM_LOCALID -eq 0 ]]; then
300300
CUDA_VISIBLE_DEVICES=0,1,2,3 nvidia-cuda-mps-control -d
301301
fi
302302

303-
# Set CUDA device
304-
numa_nodes=$(hwloc-calc --physical --intersect NUMAnode $(hwloc-bind --get --taskset))
303+
# Set CUDA device. Disable HWLOC_KEEP_NVIDIA_GPU_NUMA_NODES to avoid GPU NUMA
304+
# nodes appearing in the list of CUDA devices. They start appearing in hwloc
305+
# version 2.11.
306+
numa_nodes=$(HWLOC_KEEP_NVIDIA_GPU_NUMA_NODES=0 hwloc-calc --physical --intersect NUMAnode $(hwloc-bind --get --taskset))
305307
export CUDA_VISIBLE_DEVICES=$numa_nodes
306308

307309
# Wait for MPS to start

0 commit comments

Comments
 (0)