30.01.2013 Views

TotalView Users Guide - CI Wiki

TotalView Users Guide - CI Wiki

TotalView Users Guide - CI Wiki

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Debugging Global Arrays Applications<br />

it was stored in shared memory. All details of the data distribution, addressing,<br />

and data access are encapsulated in the global array objects. Information<br />

about the actual data distribution and locality can be easily obtained<br />

and taken advantage of whenever data locality is important. The primary<br />

target architectures for which GA was developed are massively-parallel distributed-memory<br />

and scalable shared-memory systems.<br />

GA divides logically shared data structures into “local” and “remote” portions.<br />

It recognizes variable data transfer costs required to access the<br />

data depending on the proximity attributes. A local portion of the shared<br />

memory is assumed to be faster to access and the remainder (remote portion)<br />

is considered slower to access. These differences do not hinder the<br />

ease-of-use since the library provides uniform access mechanisms for all<br />

the shared data regardless where the referenced data is located. In addition,<br />

any processes can access a local portion of the shared data directly/<br />

in-place like any other data in process local memory. Access to other portions<br />

of the shared data must be done through the GA library calls.<br />

GA was designed to complement rather than substitute for the messagepassing<br />

model, and it allows the user to combine shared-memory and<br />

message-passing styles of programming in the same program. GA inherits<br />

an execution environment from a message-passing library (w.r.t. processes,<br />

file descriptors etc.) that started the parallel program.<br />

<strong>TotalView</strong> supports Global Arrays on the Intel IA-64 platform. You debug a<br />

Global Arrays program in basically the same way that you debug any other<br />

multi-process program. The one difference is that you will use the Tools ><br />

Global Arrays command to display information about your global data.<br />

The global arrays environment has a few unique attributes. Using <strong>TotalView</strong>,<br />

you can:<br />

� Display a list of a program's global arrays.<br />

� Dive from this list of global variables to see the contents of a global array<br />

in C or Fortran format.<br />

� Cast the data so that <strong>TotalView</strong> interprets data as a global array handle.<br />

This means that <strong>TotalView</strong> displays the information as a global array.<br />

Specifically, casting to $GA forces the Fortran interpretation; casting to<br />

$ga forces the C interpretation; and casting to $Ga tells <strong>TotalView</strong> to use<br />

the language in the current context.<br />

Within a Variable Window, the commands that operate on a local array, such<br />

as slicing, filtering, obtaining statistics, and visualization, also operate on<br />

global arrays.<br />

The command you use to start <strong>TotalView</strong> depends on your operating system.<br />

For example, the following command starts <strong>TotalView</strong> on a program<br />

that is invoked using prun and which uses three processes:<br />

totalview prun -a -N 3 boltz.x<br />

Before your program starts parallel execution, <strong>TotalView</strong> asks if you want to<br />

stop the job. (See Figure 104 on page 150.)<br />

Choose Yes if you want to set breakpoints or inspect the program before it<br />

begins execution.<br />

<strong>TotalView</strong> Reference <strong>Guide</strong>: version 8.7 149

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

Saved successfully!

Ooh no, something went wrong!