When TotalView begins executing, it reads initialization and startup information from a number of files. The two most common are
initialization files that you create and preference files that TotalView creates.
An initialization file stores CLI functions, set variables, and execute actions that TotalView interprets when it begins executing. This file, which you must name
tvdrc, resides in the
.totalview subdirectory contained in your home directory. TotalView creates this directory for you the first time it executes.
TotalView can read more than one initialization file. You can place these files in your installation directory, the
.totalview subdirectory, the directory in which you invoke TotalView, or the directory in which the program resides. If an initialization file is present in one or all of these places, TotalView reads and executes each. Only the initialization file in your
.totalview directory has the name
tvdrc. The other initialization files have the name
.tvdrc. That is, a dot precedes the file name.
TotalView automatically writes your preferences file to your
.totalview subdirectory. Its name is
preferences6.tvd. Do not modify this file as TotalView overwrites it when it saves your preferences.
If you add the –s filename option to either the
totalview or
totalviewcli shell command, TotalView executes the CLI commands contained in
filename. This startup file executes after a
tvdrc file executes. The
–s option lets you, for example, initialize the debugging state of your program, run the program you’re debugging until it reaches some point where you’re ready to begin debugging, and even create a shell command that starts the CLI.
Figure 52 shows the order in which TotalView executes initialization and startup files.
The .Xdefaults file, which is actually read by the server when you start X Windows, is only used by the GUI. The CLI ignores it.
The tvdinit.tvd file resides in the TotalView
lib directory. It contains startup macros that TotalView requires. Do not edit this file. Instead, if you want to globally set a variable or define or run a CLI macro, create a file named
.tvdrc and place it in the TotalView
lib directory.
If you have saved an action point file to the same subdirectory as your program, TotalView automatically reads the information in this file when it loads your program.
You can also invoke scripts by naming them in the TV::process_load_callbacks list. For information on using this variable, see the “
Variables” chapter of the
TotalView Reference Guide.
If you are debugging multi-process programs that run on more than one computer, TotalView caches library information in the
.totalview subdirectory. If you want to move this cache to another location, set
TV::library_cache_directory to this location. TotalView can share the files in this cache directory among users.