27.12.2014 Views

QLogic OFED+ Host Software User Guide, Rev. B

QLogic OFED+ Host Software User Guide, Rev. B

QLogic OFED+ Host Software User Guide, Rev. B

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

4–Running <strong>QLogic</strong> MPI on <strong>QLogic</strong> Adapters<br />

Debugging MPI Programs<br />

NOTE:<br />

MPI does not guarantee that an MPI program can continue past an error.<br />

Using Debuggers<br />

See the standard MPI documentation referenced in Appendix J for details on the<br />

MPI error codes.<br />

The InfiniPath software supports the use of multiple debuggers, including<br />

pathdb, gdb, and the system call tracing utility strace. These debuggers let you<br />

set breakpoints in a running program, and examine and set its variables.<br />

Symbolic debugging is easier than machine language debugging. To enable<br />

symbolic debugging, you must have compiled with the -g option to mpicc so that<br />

the compiler will have included symbol tables in the compiled object code.<br />

To run your MPI program with a debugger, use the -debug or<br />

-debug-no-pause and -debugger options for mpirun. See the man pages to<br />

pathdb, gdb, and strace for details. When running under a debugger, you get<br />

an xterm window on the front end machine for each node process. Therefore, you<br />

can control the different node processes as desired.<br />

To use strace with your MPI program, the syntax is:<br />

$ mpirun -np n -m mpihosts strace program-name<br />

The following features of <strong>QLogic</strong> MPI facilitate debugging:<br />

• Stack backtraces are provided for programs that crash.<br />

• The -debug and -debug-no-pause options are provided for mpirun.<br />

These options make each node program start with debugging enabled. The<br />

-debug option allows you to set breakpoints, and start running programs<br />

individually. The -debug-no-pause option allows postmortem inspection.<br />

Be sure to set -q 0 when using -debug.<br />

• Communication between mpirun and node programs can be printed by<br />

specifying the mpirun -verbose option.<br />

• MPI implementation debug messages can be printed by specifying the<br />

mpirun -psc-debug-level option. This option can substantially impact<br />

the performance of the node program.<br />

• Support is provided for progress timeout specifications, deadlock detection,<br />

and generating information about where a program is stuck.<br />

D000046-005 B 4-27

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!