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.

Figure 179: Diving on Local<br />

Variables and Registers<br />

Displaying Variables<br />

The window at the top of the figure shows the result of diving on a register,<br />

while the bottom window shows the results of diving on an array variable.<br />

CLI: dprint variable<br />

This command lets you view variables and expressions without having<br />

to select or find them.<br />

You can also display local variables by using the View > Lookup Variable<br />

command. After <strong>TotalView</strong> displays a dialog box, enter the name of the variable<br />

you want to see.<br />

Dereferencing Variables Automatically<br />

In most cases, you want to see what a pointer points to, rather than what<br />

the value of its variable is. Using the controls on the File > Preferences<br />

Pointer Dive Page (which is shown on the next page), you can tell <strong>TotalView</strong><br />

to automatically dereference pointers. (See Figure 180 on page 294.)<br />

Dereferencing pointers is especially useful when you want to visualize the<br />

data linked together with pointers, since it can present the data as a unified<br />

array. Because the data appears as a unified array, you can use <strong>TotalView</strong>’s<br />

array manipulation commands and the Visualizer to view the data.<br />

Each pulldown list on the Pointer Dive Page has three settings: No, Yes, and<br />

Yes (don’t push). The meaning for No is that automatic dereferencing does<br />

not occur. The remaining two values tell <strong>TotalView</strong> to automatically dereference<br />

pointers. The difference between the two is based on whether you<br />

can use the Back command to see the undereferenced pointer’s value. If<br />

<strong>TotalView</strong> <strong>Users</strong> <strong>Guide</strong>: version 8.7 293

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

Saved successfully!

Ooh no, something went wrong!