Parallel Programming Guide for HP-UX Systems

MPI
Debugging
Chapter 2 57
To improve performance, HP MPI supports a process-to-process, one-copy messaging
approach. This means that one process can directly copy a message into the address space
of another process. Because of this process-to-process bcopy (p2p_bcopy) implementation,
a kernel thread is created for each process that has p2p_bcopy enabled. This thread deals
with page and protection faults associated with the one-copy operation.
TotalView multihost example The following example demonstrates how to debug a typical
HP MPI multihost application using TotalView, including requirements for directory
structure and file locations.
The MPI application is represented by an appfile, named my_appfile, which contains the
following two lines:
-h local_host -np 2 /path/to/program1
-h remote_host -np 2 /path/to/program2
my_appfile resides on the local machine (local_host) in the
/work/mpiapps/total directory.
To debug this application using TotalView (in this example, TotalView is invoked from the
local machine):
1. Place your binary files in accessible locations.
/path/to/program1 exists on local_host
/path/to/program2 exists on remote_host
To run the application under TotalView, the directory layout on your local machine,
with regard to the MPI executable files, must mirror the directory layout on each
remote machine. Therefore, in this case, your setup must meet the following
additional requirement:
/path/to/program2 exists on local_host
2. In the /work/mpiapps/total directory on local_host, invoke TotalView by passing the -tv
option to mpirun:
% $MPI_ROOT/bin/mpirun -tv -f my_appfile
Using the diagnostics library
HP MPI provides a diagnostics library (DLIB) for advanced run time error checking and
analysis. DLIB provides the following checks: