 |
OpenVMS Debugger Manual
In this example, the SHOW MODULE/SHARE command identifies all of the
modules in the current image and all of the shareable images (the names
of the shareable images are prefixed with SHARE$. The SET MODULE
SHARE$SHARE2 command sets the shareable image module SHARE$SHARE2. The
SHOW SYMBOL command identifies any universal symbols defined in the
shareable image SHARE2.
SHOW OUTPUT
Identifies the current output options.
Format
SHOW OUTPUT
Description
The current output options are the options last established with the
SET OUTPUT command. By default, if you did not enter a SET OUTPUT
command, the output options are: NOLOG, NOSCREEN_LOG, TERMINAL,
NOVERIFY.
Related commands:
SET LOG
SET MODE SCREEN
SET OUTPUT
Example
|
DBG> SHOW OUTPUT
noverify, terminal, screen_log,
logging to USER$:[JONES.WORK]DEBUG.LOG;9
DBG>
|
This command shows the following current output options:
- Debugger commands read from debugger command procedures are not
echoed on the terminal.
- Debugger output is being displayed on the terminal.
- The debugging session is being logged to the log file
USER$:[JONES.WORK]DEBUG.LOG;9.
- The screen contents are logged as they are updated in screen mode.
SHOW PROCESS
Displays information about processes that are currently under debugger
control.
Format
SHOW PROCESS [process-spec[,...]]
Parameters
process-spec
Specifies a process currently under debugger control. Use any of the
following forms:
[%PROCESS_NAME]
process-name
|
The process name, if that name does not contain spaces or lowercase
characters. The process name can include the asterisk (*) wildcard
character.
|
[%PROCESS_NAME] "
process-name"
|
The process name, if that name contains spaces or lowercase characters.
You can also use apostrophes (') instead of quotation marks (").
|
%PROCESS_PID
process_id
|
The process identifier (PID, a hexadecimal number).
|
[%PROCESS_NUMBER]
process-number
(or %PROC
process-number)
|
The number assigned to a process when it comes under debugger control.
A new number is assigned sequentially, starting with 1, to each
process. If a process is terminated with the EXIT or QUIT command, the
number can be assigned again during the debugging session. Process
numbers appear in a SHOW PROCESS display. Processes are ordered in a
circular list so they can be indexed with the built-in symbols
%PREVIOUS_PROCESS and %NEXT_PROCESS.
|
process-set-name
|
A symbol defined with the DEFINE/PROCESS_SET command to represent a
group of processes.
|
%NEXT_PROCESS
|
The next process after the visible process in the debugger's circular
process list.
|
%PREVIOUS_PROCESS
|
The process previous to the visible process in the debugger's circular
process list.
|
%VISIBLE_PROCESS
|
The process whose stack, register set, and images are the current
context for looking up symbols, register values, routine calls,
breakpoints, and so on.
|
You can also use the asterisk (*) wildcard character or the /ALL
qualifier to specify all processes. Do not specify a process with /ALL
or /DYNAMIC. If you do not specify a process or /ALL with /BRIEF,
/FULL, or /[NO]HOLD, the visible process is selected.
Qualifiers
/ALL
Selects all processes known to the debugger for display.
/BRIEF
(Default) Displays only one line of information for each process
selected for display.
/DYNAMIC
Shows whether dynamic process setting is enabled or disabled. Dynamic
process setting is enabled by default and is controlled with the SET
PROCESS/[NO]DYNAMIC command.
/FULL
Displays maximum information for each process selected for display.
/VISIBLE
(Default). Selects the visible process for display.
Description
The SHOW PROCESS command displays information about specified processes
and any images running in those processes.
The SHOW PROCESS/FULL command also displays information about the
availability and use of the vector processor. This information is
useful if you are debugging a program that uses vector instructions.
A process can first appear in a SHOW PROCESS display as soon as it
comes under debugger control. A process can no longer appear in a SHOW
PROCESS display if it is terminated through an EXIT or QUIT command.
By default (/BRIEF), one line of information is displayed for each
process, including the following:
- The process number assigned by the debugger. A process number is
assigned sequentially, starting with process 1, to each process that
comes under debugger control. If a process is terminated by an EXIT or
QUIT command, its process number is not reused during that debugging
session. The visible process is marked with an asterisk (*) in the
leftmost column.
- The process name.
- The current debugging state for that process. (See Table DEBUG-2.)
- The location (symbolized, if possible) at which execution of the
image is suspended in that process.
Table DEBUG-2 Debugging States
State |
Description |
Activated
|
The image and its process have just been brought under debugger control.
|
Break
Break on branch
Break on call
Break on instruction
Break on lines
Break on modify of
Break on return
Exception break
Exception break preceding
|
A breakpoint was triggered.
|
Interrupted
|
Execution was interrupted in that process, either because execution was
suspended in another process, or because the user interrupted program
execution with the abort-key sequence (by default, Ctrl/C).
|
Step
Step on return
|
A STEP command has completed.
|
Terminated
|
The image indicated has terminated execution but the process is still
under debugger control. Therefore, you can obtain information about the
image and its process. You can use the EXIT or QUIT command to
terminate the process.
|
Trace
Trace on branch
Trace on call
Trace on instruction
Trace on lines
Trace on modify of
Trace on return
Exception trace
Exception trace preceding
|
A tracepoint was triggered.
|
Unhandled exception
|
An unhandled exception was encountered.
|
Watch of
|
A watchpoint was triggered.
|
The SHOW PROCESS/FULL command gives additional information about
processes (see the examples).
Related commands:
CONNECT
Ctrl/C
DEFINE/PROCESS_SET
EXIT
QUIT
SET PROCESS
Examples
#1 |
all> SHOW PROCESS
Number Name State Current PC
* 2 _WTA3: break SCREEN\%LINE 47
all>
|
By default, the SHOW PROCESS command displays one line of information
about the visible process (which is identified with an asterisk (*) in
the leftmost column). The process has the process name _WTA3:. It is
the second process brought under debugger control (process number 2).
It is on hold, and the image's execution is suspended at a breakpoint
at line 47 of module SCREEN.
#2 |
all> SHOW PROCESS/FULL %PREVIOUS_PROCESS
Process number: 1 Process name: JONES_1:
Visible process: NO
Current PC: TEST_VALVES\%LINE 153
State: interrupted
PID: 20400885 Owner PID: 00000000
Current/Base priority: 5/4 Terminal: VTA79:
Image name: USER$:[JONES.PROG1]TEST_VALVES.EXE;31
Elapsed CPU time: 0 00:03:17.17 CPU Limit: Infinite
Buffered I/O Count: 14894 Remaining buffered I/O quota: 80
Direct I/O Count: 6956 Remaining direct I/O quota: 40
Open file count: 7 Remaining open file quota: 43
Enqueue count: 200 Remaining enqueue quota: 198
Vector capable: Yes
Vector consumer: Yes Vector CPU time: 00:00:00.00
Fast Vector context switches: 0 Slow Vector context switches: 0
Current working set size: 1102 Working set size quota: 1304
Current working set extent: 12288 Maximum working set extent: 12288
Peak working set size: 4955 Maximum authorized working set: 1304
Current virtual size: 255 Peak virtual size: 16182
Page faults: 41358
Active ASTs: Remaining AST Quota: 27
Event flags: FF800000 60000003 Event flag wait mask: 7FFFFFFF
all>
|
The SHOW PROCESS/FULL %PREVIOUS_PROCESS command displays the maximum
level of information about the previous process in the circular list of
processes (process number 1, in this case).
#3 |
all> SHOW PROCESS TEST_3
Number Name State Current PC
7 TEST_3 watch of TEST_3\ROUT4\COUNT
TEST_3\%LINE 54
all>
|
This SHOW PROCESS command displays one line of information about
process TEST_3. The image is suspended at a watchpoint of variable
COUNT.
#4 |
all> SHOW PROCESS/DYNAMIC
Dynamic process setting is enabled
all>
|
This command indicates that dynamic process setting is enabled.
SHOW RADIX
Identifies the current radix for the entry and display of integer data
or, if you specify /OVERRIDE, the current override radix.
Format
SHOW RADIX
Qualifiers
/OVERRIDE
Identifies the current override radix.
Description
The debugger can interpret and display integer data in any one of four
radixes: binary, decimal, hexadecimal, and octal. The current radix for
the entry and display of integer data is the radix last established
with the SET RADIX command.
If you did not enter a SET RADIX command, the default radix for both
data entry and display is decimal for most languages. On
VAX processors, the exceptions are BLISS and MACRO--32, which have a
default radix of hexadecimal. On Alpha processors, the exceptions are
BLISS, MACRO--32, and MACRO--64, which have a default radix of
hexadecimal.
The current override radix for the display of all data is the override
radix last established with the SET RADIX/OVERRIDE command. If you did
not enter a SET RADIX/OVERRIDE command, the override radix is
"none".
Related commands:
DEPOSIT
EVALUATE
EXAMINE
(SET,CANCEL) RADIX
Examples
#1 |
DBG> SHOW RADIX
input radix: decimal
output radix: decimal
DBG>
|
This command identifies the input radix and output radix as decimal.
#2 |
DBG> SET RADIX/OVERRIDE HEX
DBG> SHOW RADIX/OVERRIDE
output override radix: hexadecimal
DBG>
|
In this example, the SET RADIX/OVERRIDE command sets the override radix
to hexadecimal and the SHOW RADIX/OVERRIDE command indicates the
override radix. This means that commands such as EXAMINE display all
data as hexadecimal integer data.
SHOW SCOPE
Identifies the current scope search list for symbol lookup.
Format
SHOW SCOPE
Description
The current scope search list designates one or more program locations
(specified by path names or other special characters) to be used in the
interpretation of symbols that are specified without pathname prefixes
in debugger commands.
The current scope search list is the scope search list last established
with the SET SCOPE command. By default, if you did not enter a SET
SCOPE command, the current scope search list is 0,1,2,...,n.
The default scope search list specifies that, for a symbol without a
pathname prefix, a symbol lookup such as EXAMINE X first looks for X in
the routine that is currently executing (scope 0); if no X is visible
there, the debugger looks in the caller of that routine (scope 1), and
so on down the call stack; if X is not found in scope n, the
debugger searches the rest of the run-time symbol table (RST)---that
is, all set modules and the global symbol table (GST), if necessary.
If you used a decimal integer in the SET SCOPE command to represent a
routine in the call stack, the SHOW SCOPE command displays the name of
the routine represented by the integer, if possible.
Related commands:
(SET,CANCEL) SCOPE
Examples
#1 |
DBG> CANCEL SCOPE
DBG> SHOW SCOPE
scope:
* 0 [ = EIGHTQUEENS\TRYCOL\REMOVEQUEEN ],
1 [ = EIGHTQUEENS\TRYCOL ],
2 [ = EIGHTQUEENS\TRYCOL 1 ],
3 [ = EIGHTQUEENS\TRYCOL 2 ],
4 [ = EIGHTQUEENS\TRYCOL 3 ],
5 [ = EIGHTQUEENS\TRYCOL 4 ],
6 [ = EIGHTQUEENS ]
DBG> SET SCOPE/CURRENT 2
DBG> SHOW SCOPE
scope:
0 [ = EIGHTQUEENS\TRYCOL\REMOVEQUEEN ],
1 [ = EIGHTQUEENS\TRYCOL ],
* 2 [ = EIGHTQUEENS\TRYCOL 1 ],
3 [ = EIGHTQUEENS\TRYCOL 2 ],
4 [ = EIGHTQUEENS\TRYCOL 3 ],
5 [ = EIGHTQUEENS\TRYCOL 4 ],
6 [ = EIGHTQUEENS ]
DBG>
|
The CANCEL SCOPE command restores the default scope search list, which
is displayed by the (first) SHOW SCOPE command. In this example,
execution is suspended at routine REMOVEQUEEN, after several recursive
calls to routine TRYCOL. The asterisk (*) indicates that the scope
search list starts with scope 0, the scope of the routine in which
execution is suspended.
The SET SCOPE/CURRENT command resets the start of the scope search list
to scope 2. Scope 2 is the scope of the caller of the routine in which
execution is suspended. The asterisk in the output of the (second) SHOW
SCOPE command indicates that the scope search list now starts with
scope 2.
#2 |
DBG> SET SCOPE 0,STACKS\R2,SCREEN_IO,\
DBG> SHOW SCOPE
scope:
0, [= TEST ],
STACKS\R2,
SCREEN_IO,
\
DBG>
|
In this example, the SET SCOPE command directs the debugger to look for
symbols without pathname prefixes according to the following scope
search list. First the debugger looks in the PC scope (denoted by 0,
which is in module TEST). If the debugger cannot find a specified
symbol in the PC scope, it then looks in routine R2 of module STACKS;
if necessary, it then looks in module SCREEN_IO, and then finally in
the global symbol table (denoted by the global scope (\)). The SHOW
SCOPE command identifies the current scope search list for symbol
lookup. No asterisk is shown in the SHOW SCOPE display unless the
default scope search list is in effect or you have entered a SET
SCOPE/CURRENT command.
SHOW SEARCH
Identifies the default qualifiers (/ALL or /NEXT, /IDENTIFIER or
/STRING) currently in effect for the SEARCH command.
Format
SHOW SEARCH
Description
The default qualifiers for the SEARCH command are the default
qualifiers last established with the SET SEARCH command. If you did not
enter a SET SEARCH command, the default qualifiers are /NEXT and
/STRING.
Related commands:
SEARCH
(SET,SHOW) LANGUAGE
SET SEARCH
Example
|
DBG> SHOW SEARCH
search settings: search for next occurrence, as a string
DBG> SET SEARCH IDENT
DBG> SHOW SEARCH
search settings: search for next occurrence, as an identifier
DBG> SET SEARCH ALL
DBG> SHOW SEARCH
search settings: search for all occurrences, as an identifier
DBG>
|
In this example, the first SHOW SEARCH command displays the default
settings for the SET SEARCH command. By default, the debugger searches
for and displays the next occurrence of the string.
The second SHOW SEARCH command indicates that the debugger searches for
the next occurrence of the string, but displays the string only if it
is not bounded on either side by a character that can be part of an
identifier in the current language.
The third SHOW SEARCH command indicates that the debugger searches for
all occurrences of the string, but displays the strings only if they
are not bounded on either side by a character that can be part of an
identifier in the current language.
SHOW SELECT
Identifies the displays currently selected for each of the display
attributes: error, input, instruction, output, program, prompt, scroll,
and source.
Note
This command is not available in the Compaq DECwindows Motif for OpenVMS user interface to
the debugger.
|
Format
SHOW SELECT
Description
The display attributes have the following properties:
- A display that has the error attribute displays
debugger diagnostic messages.
- A display that has the input attribute echoes your
debugger input.
- A display that has the instruction attribute
displays the decoded instruction stream of the routine being debugged.
The display is updated when you enter an EXAMINE/INSTRUCTION command.
- A display that has the output attribute displays
any debugger output that is not directed to another display.
- A display that has the program attribute displays
program input and output. Currently only the PROMPT display can have
the program attribute.
- A display that has the prompt attribute is where
the debugger prompts for input. Currently, only the PROMPT display can
have the PROMPT attribute.
- A display that has the scroll attribute is the
default display for the SCROLL, MOVE, and EXPAND commands.
- A display that has the source attribute displays
the source code of the module being debugged, if available. The display
is updated when you enter a TYPE or EXAMINE/SOURCE command.
Related commands:
SELECT
SHOW DISPLAY
Example
|
DBG> SHOW SELECT
display selections:
scroll = SRC
input = none
output = OUT
error = PROMPT
source = SRC
instruction = none
program = PROMPT
prompt = PROMPT
DBG>
|
The SHOW SELECT command identifies the displays currently selected for
each of the display attributes. These selections are the defaults for
languages.
SHOW SOURCE
Identifies the source directory search lists and search methods
currently in effect.
Format
SHOW SOURCE
Qualifiers
/DISPLAY
Identifies the search list used when the debugger displays source code.
/EDIT
Identifies the search list to be used during execution of the
debugger's EDIT command.
Description
The SET SOURCE/MODULE=module-name command establishes a source
directory search list for a particular module. The SET SOURCE command
establishes a source directory search list for all modules not
explicitly mentioned in a SET SOURCE/MODULE=module-name
command. When you have used those commands, SHOW SOURCE identifies the
source directory search list associated with each search category.
If a source directory search list has not been established by using the
SET SOURCE or SET SOURCE/MODULE=module-name command, the SHOW
SOURCE command indicates that no directory search list is currently in
effect. In this case, the debugger expects each source file to be in
the same directory that it was in at compile time (the debugger also
checks that the version number and the creation date and time of a
source file match the information in the debugger's symbol table).
The /EDIT qualifier is needed when the files used for the display of
source code are different from the files to be edited by using the EDIT
command. This is the case with Ada programs. For Ada programs, the SHOW
SOURCE command identifies the search list of files used for source
display (the copied source files in Ada program libraries); the SHOW
SOURCE/EDIT command identifies the search list for the source files you
edit when using the EDIT command.
For information specific to Ada programs, type Help Language_Support
Ada.
Related commands:
(SET,CANCEL) SOURCE
Examples
#1 |
DBG> SHOW SOURCE
no directory search list in effect,
match the latest source file version
DBG> SET SOURCE [PROJA],[PROJB],DISK:[PETER.PROJC]
DBG> SHOW SOURCE
source directory search list for all modules,
match the latest source file version:
[PROJA]
[PROJB]
DISK:[PETER.PROJC]
DBG>
|
In this example, the SET SOURCE command directs the debugger to search
the directories [PROJA],[PROJB], and DISK:[PETER.PROJC]. By default,
the debugger searches for the latest version of source files.
#2 |
DBG> SET SOURCE/MODULE=CTEST/EXACT [], DISK$2:[PROJD]
DBG> SHOW SOURCE
source directory search list for CTEST,
match the exact source file version:
[]
DISK$2:[PROJD]
source directory search list for all other modules,
match the latest source file version:
[PROJA]
[PROJB]
DISK:[PETER.PROJC]
DBG>
|
In this example, the SET SOURCE command directs the debugger to search
the current default directory ([]) and directory DISK$2:[PROJD] for
source files to use with the module CTEST. The /EXACT qualifier
specifies that the search will locate the exact version of the CTEST
source files found in the debug symbol table.
|