Skip to content

Commit d58e677

Browse files
committed
disable MPI binding in NVHPC
1 parent 637d87c commit d58e677

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/build_tools/hooks_hydra.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -457,6 +457,12 @@ def pre_module_hook(self, *args, **kwargs): # pylint: disable=unused-argument
457457
slurm_mpi_type = 'pmix'
458458
self.log.info("[pre-module hook] Set Slurm MPI type to: %s", slurm_mpi_type)
459459
self.cfg['modextravars'].update({'SLURM_MPI_TYPE': slurm_mpi_type})
460+
# NVHPC ships with OpenMPI v4 which has an issue between its hwloc
461+
# and Slurm cgroups2 that results in mpirun trying to use unallocated
462+
# cores to the job (see https://github.com/open-mpi/ompi/issues/12470)
463+
# Only mpirun is affected, workaround is to set '--bind-to=none':
464+
self.log.info("[pre-module hook] Disable mpirun process binding in NVHPC")
465+
self.cfg['modextravars'].update({'OMPI_MCA_hwloc_base_binding_policy': 'none'})
460466

461467
##########################
462468
# ------ TUNING -------- #

0 commit comments

Comments
 (0)