About Diving into Objects
Diving is integral to the TotalView GUI and provides a quick and easy way to get more information about variables, processes, threads, functions, and other program elements.
To dive on an element, just click your middle mouse button on it to launch another window with more information.
*In some cases, single-clicking performs a dive. For example, single-clicking on a function name in the Stack Trace Pane dives into the function. In other cases, double-clicking does the same thing.
Diving on processes and threads in the Root Window is the quickest way to launch a Process Window with more information. Diving on variables in the Process Window launches a Variable Window.
In the Process Window’s Source Pane, if a global variable or function can be dived on, a red dotted box appears when your cursor hovers over it, Figure 68.
Figure 68: Diving on an object in the Source Pane
*If you prefer that the cursor remain an arrow when hovering over an element you can dive on, specify the option -nohand_cursor when starting TotalView, or set this permanently in .tvdrc as “TV::GUI::hand_cursor_enabled {false}”.
The following table describes typical diving operations:     
Items you dive on:
Information Displayed:
Process or thread
When you dive on a thread in the Root Window, TotalView finds or opens a Process Window for that process. If it doesn’t find a matching window, TotalView replaces the contents of an existing window and shows you the selected process.
Variable
The variable displays in a Variable Window.
Expression List Variable
Same as diving on a variable in the Source Pane: the variable displays in a Variable Window.
Routine in the Stack Trace Pane
The stack frame and source code for the routine appear in a Process Window.
Array element, structure element, or referenced memory area
The contents of the element or memory area replace the contents that were in the Variable Window. This is known as a nested dive.
Pointer
TotalView dereferences the pointer and shows the result in a separate Variable Window. Given the nature of pointers, you may need to cast the result into the logical data type.
Subroutine
The source code for the routine replaces the current contents of the Source Pane. When this occurs, TotalView places a right angle bracket (>) in the process’s title. Every time it dives, it adds another angle bracket, Figure 69.
 
A routine must be compiled with source-line information (usually, with the -g option) for you to dive into it and see source code. If the subroutine wasn’t compiled with this information, TotalView displays the routine’s assembler code.
Variable Window
TotalView replaces the contents of the Variable Window with information about the variable or element.
Expression List Window
TotalView displays information about the variable in a separate Variable Window.
Figure 69: Nested Dive
*Diving on a struct or class member that is out of scope does not work.
TotalView tries to reuse windows. For example, if you dive on a variable and that variable is already displayed in a window, TotalView pops the window to the top of the display. If you want the information to appear in a separate window, use the View > Dive in New Window command.
*Diving on a process or a thread might not create a new window if TotalView determines that it can reuse a Process Window. If you really want to see information in two windows, use the Process Window Window > Duplicate command.
When you dive into functions in the Process Window, or when you are chasing pointers or following structure elements in the Variable Window, you can move back and forth between your selections by using the forward and backward buttons. The boxed area of the following figure shows the location of these two controls.
Figure 70: Backward and Forward Buttons
For additional information about displaying variable contents, see Diving in Variable Windows”.
You can also use the following additional windowing commands:
*Window > Duplicate: (Variable and Expression List Windows) Creates a duplicate copy of the current Variable Window.
*File > Close: Closes an open window.
*File > Close Relatives: Closes windows that are related to the current window. The current window isn’t closed.
*File > Close Similar: Closes the current window and all windows similar to it.