dset
Changes or views CLI state variables
Format:
Creates or changes a CLI state variable
dset [ -new ] debugger-var value
Views current CLI state variables
dset [ debugger-var ]
Arguments:
-new
Creates a variable if it does not already exist. If you omit this option and the variable does not exist, the CLI returns an error message.
debugger-var
Name of a CLI state variable.
value
Value to be assigned to debugger-var.
Description:
The dset command sets the value of CLI debugger variables.
If you type dset with no arguments, the CLI displays the names and current values for all TotalView CLI state variables. If you use only one argument, the CLI returns and displays the variable's value.
The second argument defines the value that will replace a variable's previous value. It must be enclosed in quotes if it contains more than one word.
If you do not use an argument, the CLI only displays variables in the current namespace. To show all variables in a namespace, just enter the namespace name immediately followed by a double colon; for example, TV::. You can also use an asterisk (*) as a wildcard to indicate that the CLI should match more than one string; for example, TV::g* matches all variables beginning with g in the TV namespace.
For example, to view all variables in the TV:: namespace, you would enter:
dset TV::
Similarly, you can view variables in a specific namespace by using the following command:
dset TV::GUI::
The rightmost double colons are required when obtaining listings for a namespace. If you omit them, Tcl assumes that you are requesting information on a variable. For example, dset TV::GUI looks for a variable named GUI in the TV namespace.
The state variables are:
ARGS(dpid)
The argument strings that are passed to the process with TotalView ID dpid the next time it is launched.
ARGS_DEFAULT
Contains the argument string passed to a new process that does not have an ARGS(dpid) variable defined.
BARRIER_STOP_ALL
Contains the default value for the STOP_ALL variable on newly created barrier points.
group: New barrier points will have the stop_when_hit flag set to group. When one thread reaches the barrier, TotalView stops all processes in its control group.
process: New barrier points just stop the process that hit the barrier.
none: New thread barrier points just stop the thread that hit the barrier.
BARRIER_STOP_WHEN_DONE
Contains the default value for a -stop_when_done option of commands that set barriers.
group: When a barrier is satisfied, TotalView stops all processes in the control group.
process: When a barrier is satisfied, TotalView stops the processes in the satisfaction set.
none: TotalView only stops the threads in the satisfaction set; other threads are not affected. For process barriers, there is no difference between process and none. In all cases, TotalView releases the satisfaction set when the barrier is satisfied.
CGROUP(dpid)
Contains the control group for the process with the TotalView ID dpid. Setting this variable moves process dpid into a different control group. For example, the following command moves process 3 into the same group as process 1:
dset CGROUP(3) $CGROUP(1)
COMMAND_EDITING
Enables some Emacs-like commands that you can use while editing text in the CLI. These editing commands are always available in the CLI window of GUI TotalView. However, they are only available within the stand-alone CLI if the terminal it is being run from supports cursor positioning and clear-to-end-of-line. The commands that you can use are:
^A: Moves to the beginning of the line.
^B: Moves one character backward.
^D: Deletes the character to the right of cursor.
^E: Moves to the end of the line.
^F: Moves one character forward.
^K: Deletes all text to the end of line.
^N: Retrieves the next entered command (only works after ^P).
^P: Retrieves the previously entered command.
^R or ^L: Redraws the line.
^U: Deletes all text from the cursor to the beginning of the line.
Rubout or Backspace: Deletes the character to the left of the cursor.
EXECUTABLE_PATH
Contains a colon-separated list containing the directories that TotalView searches when it looks for source and executable files.
GROUP(gid)
Contains a list containing the TotalView IDs for all members in group gid. User-created groups can be modified by directly using the dgroups -add and dgroups -remove commands.
The first element in the list indicates what kind of group it is, as follows:
control: The group of all processes in a program
lockstep: A group of threads that share the same PC
process: A user-created process group
share: The group of processes in one program that share the same executable image
thread: A user-created thread group
workers: The group of worker threads in a program
Elements that follow are either pids (for process groups) or pid.tid pairs (for thread groups).
The gid is a simple number for most groups. In contrast, a lockstep group's ID number is of the form pid.tid. Thus, GROUP(2.3) contains the lockstep group for thread 3 in process 2. Note, however, that the CLI will not display lockstep groups when you use dset with no arguments--they are hidden variables.
The GROUP(id) variable is a read-write variable except when the group is not writable. Examples are lockstep, share, and control groups.
GROUPS
Contains a list that contains all TotalView groups IDs except for the lockstep groups.
LINES_PER_SCREEN
Defines the number of lines shown before the CLI stops printing information and displays its more prompt. The following values have special meaning:
0: No more processing occurs, and the printing does not stop when the screen fills with data.
NONE: This is a synonym for 0.
AUTO: The CLI uses the tty settings to determine the number of lines to display. This may not work in all cases. For example, Emacs sets the tty value to 0. If AUTO works improperly, you will need to explicitly set a value.
MAX_LIST
Defines the number of lines displayed in response to a dlist command.
PROMPT
Defines the CLI prompt. If you use brackets ([ ]) in the prompt, TotalView assumes the information within the brackets is a Tcl command and evaluates tit o obtain the prompt string.
PTSET
Defines the current focus.
SGROUP(pid)
Contains the group ID of the share group for process pid. TotalView decides which share group this is by looking at the control group for the process and the executable associated with it. You cannot directly modify this group.
SHARE_ACTION_POINT
Contains the default value for TotalView's internal share_in_group flag for newly created action points. If this value is true, an action point will be active across the group. If it is false, an action point is only active in the process upon which it is set.
When a dbarrier, dbreak, or dwatch command is invoked using the default focus, this variable determines if the new action is shared.
STOP_ALL
Indicates the default value for the "stop all" attribute of newly created breakpoints and watchpoints, as follows:
group: Stops the entire control group when the action point is hit.
process: Stops the entire process when the action point is hit.
thread: Only stops the thread that hit the action point. Note that none is a synonym for thread.
TAB_WIDTH
Indicates the number of spaces used to simulate a tab character when the CLI displays information.
THREADS(pid)
Contains a list of all threads in the process pid, in the form {pid.1 pid.2 ...}. This variable is read-only.
TOTALVIEW_ROOT_PATH
Names the directory in which the TotalView executable is located.
TOTALVIEW_TCLLIB_PATH
Contains a list containing the directories in which the CLI searches for TCL library components.
TOTALVIEW_VERSION
Contains the version number and the type of computer architecture upon which TotalView is executing.
VERBOSE
Controls the error message information displayed by the CLI. The values for this variable can be:
INFO: Prints error, warnings, and informational messages. Informational message include data on dynamic libraries and symbols.
WARNING: Only print errors and warnings.
ERROR: Only print error messages.
SILENT: Does not print error, warning, and informational messages. This also shuts off the printing of results from CLI commands. This should only be used when the CLI is run in batch mode.
WGROUP(pid)
The group ID of the thread-group of worker threads associated with the process pid.
WGROUP(pid.tid)
Either it contains the group ID of the worker sgroup in which thread pid.tid is a member or it contains 0 (zero), to indicate that thread pid.tid is not a worker thread. Storing a nonzero value in this variable marks a thread as a worker. In this case, the value that is read back will always be the ID of the workers group associated with the control group, regardless of the actual nonzero value assigned to it.
Storing a zero value marks it as a nonworker.
Debugger Variable |
Permitted Values |
Default |
ARGS |
A string |
-- |
ARGS_DEFAULT |
A string |
-- |
BARRIER_STOP_ALL |
group, process, or thread |
group |
CGROUP |
A number |
-- |
COMMAND_EDITING |
true/false |
false |
EXECUTABLE_PATH |
Any valid directory or directory path. To include the current setting, use $EXECUTABLE_PATH. |
./:$PATH |
GROUP |
A Tcl array of lists indexed by the group ID. Each entry contains the members of one group. |
-- |
GROUPS |
A Tcl list of IDs. This is a read-only value and cannot be set. |
-- |
LINES_PER_SCREEN |
A positive integer, or the AUTO or NONE values. |
AUTO |
MAX_LIST |
A positive integer |
20 |
PROMPT |
Any string. If you wish to access the value of PTSET, you must place the variable within brackets; that is, [dset PTSET]. |
{[dfocus]> } |
PTSET |
This is a read-only value and cannot be set. |
d1.< |
SGROUP |
A number |
-- |
SHARE_ACTION_POINT |
True or false |
true |
STOP_ALL |
group, process, or thread |
group |
TAB_WIDTH |
A positive number. -1 indicates no tab expansion. |
8 |
TOTALVIEW_ROOT_PATH |
The location of the TotalView installation directory. This is a read-only variable and cannot be set. |
|
TOTALVIEW_TCLLIB_PATH |
Any valid directory or directory path. To include the current setting, use $TOTALVIEW_- TCLLIB_PATH. |
The directory containing the CLI Tcl libraries |
TOTALVIEW_VERSION |
This is a read-only value and cannot be set. |
|
VERBOSE |
INFO, WARNING, ERROR, and SILENT |
INFO |
WGROUP |
A number |
-- |
Examples:
dset PROMPT "Fixme% "
Sets the prompt to be Fixme% followed by a space.
dset *
Displays all CLI state variables and their current settings.
dset VERBOSE
Displays the current setting for output verbosity.
dset EXECUTABLE_PATH ../test_dir;$EXECUTABLE_PATH
Places ../test_dir at the beginning of the previous value for the executable path.
dset TV::GUI::fixed_font_size 12
Sets the TotalView GUI so that it displays fixed fonts at 12 dpi. Commands such as this are often found in a startup file.
The following examples show the contents of a "typical" variable:
GROUP(1) |
{ control 1 2 3 } |
Control group. Members are processes 1, 2, and 3. |
GROUP(2) |
{ share 1 2 } |
Share group. Members are processes 1 and 2. |
GROUP(4) |
{ thread 2.1 2.3 2.7} |
General thread group. Members are threads 2.1, 2.3, and 2.7. |
GROUP(5) |
{ workers 17.3 17.4 17.12} |
Thread workers group. Members are threads 17.3, 17.4, and 17.12. |
GROUP(17) |
{ process 2 5 9 } |
A user-created group of processes. Members are processes 2, 5, and 9. |