-
Notifications
You must be signed in to change notification settings - Fork 217
Debugging
You are here: Home > Developer Documentation > Debugging
This page collects some useful hints about how to debug a hybrid (CUDA + device) parallel (MPI) application.
Use the OpenMPI supressions list
mpiexec <mpi flags> valgrind --suppressions=$MPI_ROOT/share/openmpi/openmpi-valgrind.supp picongpu ...
Multi-Node Host-Side
Login into an interactive shell/batch session with X-forwarding ssh -X
.
Launch PIConGPU with gdb
and trigger start and back trace automatically:
mpiexec <mpi flags> xterm -e gdb -ex r -ex tb --args picongpu ...
mpiexec <mpi flags> cuda-memcheck --tool <memcheck|racecheck> picongpu ...
Single-Node device-side
(!) Compile with nvcc -g -G <...>
if you want to set device-side breakpoints.
cd <path>/simOutput
cuda-gdb --args <path2picongpu> -d 1 1 1 -g <...> -s 100 <...>
in cuda-gdb
:
b <FileName>:<LineNumber>
r
Another nice method to set the debug flags for PIConGPU can be used after configuring an example. Just use ccmake .
in your build
directory and a GUI with a list of flags pops up. Press t
for this toggles the advanced mode. Useful flags to set on are SHOW_CODELINES
, CUDA_BLOCKING_KERNELS
and most importantly the value of CUDA_NVCC_DEBUG_FLAGS
should be set to -g;-G
. After manipulating the flags press c
to configure the make files and generate them by pressing g
.
All wiki entries describe the dev branch. Features may be different in the current master branch.
Before you start please read our README!
PIConGPU is a scientific project. If you present and/or publish scientific results that used PIConGPU, you should set a reference to show your support. Our according up-to-date publication at the time of your publication should be inquired from:
The documentation in this wiki is still not complete and we need your help keeping it up to date. Feel free to help improving this wiki!