Numactl (DDT)

Linaro DDT supports launching programs via numactl for MPI programs, but has limited support for non-MPI programs.

MPI and SLURM

DDT can attach to MPI programs launched via numactl with or without SLURM. The recommended way to launch via numactl is to use Express Launch (DDT).

$ ddt mpiexec -n 4 numactl -m 1 ./myMpiProgram.exe
$ ddt srun -n 4 numactl -m 1 ./myMpiProgram.exe

It is also possible to launch via numactl using compatibility mode. When using compatibility mode, you must specify the full path to numactl in the Application field of the Run window. You can find the full path by running:

which numactl

Enter the name of the required application in Arguments, after all arguments to be passed to numactl. It is not possible to pass any more arguments to the parallel job runner when using this mode for launching.

Note

When using memory debugging with a program launched via numactl, the Memory Statistics view will report all memory as ‘Default’ memory type unless allocated with memkind. See Memory Statistics.

Non-MPI Programs

There is a minor caveat to launching non-MPI programs via numactl. If you are using SLURM, set FORGE_STOP_AT_MAIN=1, otherwise Linaro DDT will not be able to attach to the program. For example, these two commands are examples of launching non-MPI programs via numactl:

$ ddt numactl -m 1 ./myNonMpiProgram.exe
$ FORGE_STOP_AT_MAIN=1 ddt srun \
  numactl -m 1 ./myNonMpiProgram.exe

When launched, the program stops in numactl main. To resume debugging as normal, set a breakpoint in your code (optional), then use the play and pause buttons to progress and pause the debugging respectively.