30.01.2013 Views

TotalView Users Guide - CI Wiki

TotalView Users Guide - CI Wiki

TotalView Users Guide - CI Wiki

SHOW MORE
SHOW LESS

Create successful ePaper yourself

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

Debugging Parallel Applications Tips<br />

<strong>TotalView</strong> may display a dialog box with the following text:<br />

Process mprun is a parallel job. Do you want to stop<br />

the job now?<br />

2 If you compiled using the –g option, click Yes to tell <strong>TotalView</strong> to open a<br />

Process Window that shows your source. All processes are halted.<br />

Attaching to a Sun MPI Job<br />

To attach to an already running mprun job:<br />

1 Find the host name and process identifier (PID) of the mprun job by typing<br />

mpps –b. For more information, see the mpps(1M) manual page.<br />

The following is sample output from this command:<br />

JOBNAME MPRUN_PID MPRUN_HOST<br />

cre.99 12345 hpc-u2-9<br />

cre.100 12601 hpc-u2-8<br />

2 After selecting File > New Program, type mprun in the Executable field<br />

and type the PID in the Process ID field.<br />

CLI: dattach mprun mprun-pid<br />

For example:<br />

dattach mprun 12601<br />

3 If <strong>TotalView</strong> is running on a different node than the mprun job, enter the<br />

host name in the Remote Host field.<br />

CLI: dattach –r host-name mprun mprun-pid<br />

Debugging Parallel Applications Tips<br />

This section contains information about debugging parallel programs:<br />

� “Attaching to Processes” on page 124<br />

� “Parallel Debugging Tips” on page 127<br />

� “MPICH Debugging Tips” on page 129<br />

� “IBM PE Debugging Tips” on page 129<br />

Attaching to Processes<br />

In a typical multi-process job, you’re interested in what’s occurring in some<br />

of your processes and not as much interested in others. By default,<br />

<strong>TotalView</strong> tries to attach to all of the processes that your program starts. If<br />

there are a lot of processes, there can be considerable overhead involved<br />

in opening and communicating with the jobs.<br />

124 Chapter 6: Setting Up MPI Debugging Sessions

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

Saved successfully!

Ooh no, something went wrong!