Rational Developer for System z, Version 7.6

Appendix A. Reference card: Frequently used Debug Tool commands

The following reference card provides a list of frequently used Debug Tool commands. For best results, print the card from the PDF file.

Setting breakpoints (stopping points) at statements
in a program

A
A is the abbreviation for AT. Enter through the prefix area of the Source window. Sets a breakpoint on line where A is entered.
PF6
Sets a breakpoint on line where cursor is located.
AT 509
Sets a breakpoint on line 509.
AT LABEL label_name
Sets a breakpoint on a label, paragraph, or section name.

Clearing (removing) breakpoints set at statements
in a program

C
C is the abbreviation for CLEAR AT. Type a C in the prefix area of the Source window. When you press Enter, Debug Tool removes the breakpoint on the line where C is in the prefix area.
PF6
Removes a breakpoint on line where cursor is located.
CLEAR AT 509
Removes the breakpoint on line 509.
CLEAR AT LABEL label_name
Clears a breakpoint from a label, paragraph, or section name.

Setting breakpoints (stopping points) triggered by
a change in the value of a variable

AT CHANGE ITEMNO
Sets a breakpoint that stops the program when the value of ITEMNO changes.

Clearing (removing) breakpoints triggered by
a change in the value of a variable

CLEAR AT CHANGE ITEMNO
Removes the breakpoint that stops the program when the value of ITEMNO changes.
Setting breakpoints (stopping points) at the entrance or exit of a program
AT ENTRY cu_name
Sets a breakpoint that stops the program when it enters cu_name.
AT ENTRY *
Sets breakpoints that stop a program whenever Debug Tool enters a known program.
AT EXIT cu_name
Sets a breakpoint that stops the program when it exits cu_name.
AT EXIT *
Sets breakpoints that stop a program whenever Debug Tool exits a known program.

Clearing (removing) breakpoints set at the entrance or exit of
a program

CLEAR AT ENTRY cu_name
Clears the breakpoint that stops the program when it enters cu_name.
CLEAR AT ENTRY *
Clears all breakpoints that stop a program whenever Debug Tool enters a known program.
CLEAR AT EXIT cu_name
Clears a breakpoint that stops the program when it exits cu_name.
CLEAR AT EXIT *
Removes the breakpoints at every exit point in every program.

Making breakpoints conditional

Add a WHEN clause to make breakpoints conditional.

AT CHANGE ITEMNO WHEN ITEMNO = ’0805’
Stop after the value of ITEMNO changes, but only if ITEMNO is equal to the specified value.
AT CHANGE CUSTID WHEN ACCT-BAL > 100
Stop after the value of CUSTID changes, but only if ACCT-BAL is greater than the specified value.
AT 509 WHEN ITEMNO = ‘0805'
Stop at statement 509, but only if ITEMNO is equal to the specified value.
Commands that work on all breakpoints
LIST AT
Displays all breakpoints in the Log window.
CLEAR AT
Clears all breakpoints.
DISABLE AT
Temporarily disables (deactivates) all breakpoints.
ENABLE AT
Enables (activates) all disabled breakpoints.

Identifying and loading a program’s source and
debug information

SET DEFAULT LISTINGS source.info.library
Identifies a source library (PDS or PDSE) where Debug Tool searches for source files and debug information files. For example, SYSDEBUG files, LANGX files, and compiler listings. Debug Tool displays this information in the Source window.
SET DEFAULT LISTINGS (source.info.lib1, source.info.lib2, ... )
Identifies a concatenation of source libraries (PDS or PDSE) where Debug Tool searches for source files and debug information files.
LISTING or LIST
Displays a list of programs known to Debug Tool. Then, you can specify the name of the source file or debug information file for each program.
LDD assember_CSECT or LDD nonLECOBOL_program
Load debug information about assember_CSECT or nonLECOBOL_program from the EQALANGX file into the Source window.
Displaying variables in the Monitor window
SET AUTOMONITOR ON
Automatically displays the values of variables referenced by the current statement in the Monitor window.
SET AUTOMONITOR ON BOTH
Automatically displays the values of variables referenced by both the current statement and the previously run statement in the Monitor window.
MONITOR LIST ITEMNO
Adds the ITEMNO variable and its value to the Monitor window.
SET MONITOR DATATYPE ON
Display the data types of variables.
SET MON WRAP OFF
Displays values on a single line. If the value is longer than the visible area, Debug Tool displays a scale to indicate that there is more to see.
CLEAR MONITOR
Clears all items from the Monitor window.
C
C is the abbreviation for the CLEAR MONITOR command. Type in the letter C in the prefix area of the monitor window. When you press Enter, Debug Tool removes the variable on the line where C is in the prefix area.

Changing values of variables
Type over value displayed in the Monitor window
Move cursor to value displayed in Monitor window, type in new value, then press Enter.
MOVE 24 to ACCUM-X
For COBOL programs, replace the value of ACCUM-X with 24.
ACCUMX = 24
For some languages, replaces the value of ACCUMX with 24.
Displaying variables in Log window and controlling Log window options
LIST CUST-ID or LIST TITLED CUST-ID
Displays the value of a variable. Only some programming languages require TITLED.
PF4 or LIST
Displays the value of a variable identified by the location of the cursor.
LIST TITLED WSS or LS or FS or LOS
Display contents of specific SECTIONS for COBOL programs. WSS means Working-Storage Section, LS means Linkage Section, FS means File Section, and LOS means Local-Storage Section.
LIST TITLED *
Displays the values of all variables.
SET ECHO OFF
Debug Tool does not display STEP and GO commands in the Log window. However, if a log file is open, Debug Tool writes them to the log file.
SET LOG ON FILE file_name OLD
Opens a log file. When Debug Tool opens the log file, all items it writes to the Log window are also written to the log file.

Refresh the Source window to display the current statement
QUALIFY RESET
Repositions source in the Source window so that Debug Tool displays the current program and current statement.

Working with called programs
STEP or STEP INTO
When the current statement is a CALL, steps into the called program.
STEP OVER
When the current statement is a CALL, Debug Tool runs the called program but does not display it. Debug Tool stops at the statement after the call.
LOAD program_name
Make program_name known to Debug Tool.
QUALIFY program_name
Displays the program program_name in the Source window. When the program is displayed in the Source window, you can set a breakpoint or work with variables in that program.
QUALIFY RESET
Reposition to the current program and the current line.
Controlling program execution
STEP or PF2
Run one statement or line.
GO or PF9
Run the program until Debug Tool encounters a breakpoint, the program finishes, or an abend occurs.
RUNTO 27
Runs the program and then stops before it runs line 27.
R
R is the abbreviation of RUNTO. Type in the command in the prefix area of the Source window. When you press Enter, Debug Tool runs the program until it reaches the line with the R in the prefix area.
GO BYPASS
Resume running a program after encountering an abend. Enter this command immediately after an abend occurs. Debug Tool skips the statement that caused the abend and continues running the program from the next logical statement.

Skipping (do not run) over program statements
JUMPTO 27
Moves the point at which the program resumes execution to line 27, does not run any statements between the current point and line 27, and then pauses at line 27. When you enter a GO or STEP command, the program resumes running at line 27.
GOTO 27
Moves the point at which the program resumes execution to line 27, does not run any statements between the current point and line 27, and then resumes running the program at line 27.
Commands that work in the prefix area of the Source window
A
A is the abbreviation for AT. Sets a breakpoint on the line.
C
C is the abbreviation for CLEAR AT. Clears the breakpoint from the line.
D
D is the abbreviation for DISABLE AT. Disables the breakpoint on the line.
E
E is the abbreviation for ENABLE AT. Enables the breakpoint on the line.
L
L is the abbreviation for LIST. Displays all variables referenced by the statement in the log. This prefix command works only for programs compiled with specific compilers.
L1, L2, L3,...
L is the abbreviation for LIST. Displays the first, second, third, and so on variable referenced by the statement in the log. This prefix command works only for programs compiled with specific compilers.
M
M is the abbreviation for MONITOR LIST. Displays all variables reference by the statement in the Monitor window. This prefix command works only for programs compiled with specific compilers.
M1, M2, M3, ...
M is the abbreviation for MONITOR LIST. Displays first, second, third, and so on variable referenced by the statement in the Monitor window. This prefix command works only for programs compiled with specific compilers.

Commands that work in the prefix area
of the Monitor window

C
C is the abbreviation for CLEAR MONITOR. Removes the variable from the Monitor window.
D
D is the abbreviation for default. Displays the value of the variable in a format based on its declared data type.
H
H is the abbreviation for hexadecimal. Displays the value of the variable in hexadecimal format.
Working with PF keys
QUERY PFKEYS
Displays the PF key settings in the log.
SET KEYS ON
Debug Tool displays the PF key settings for PF keys 1-12 at the bottom of the screen.
SET KEYS ON 24
Debug Tool displays the PF key settings for PF keys 13-24 at the bottom of the screen.
SET KEYS OFF
Debug Tool removes the PF key settings from the bottom of the screen.
SET PF16 "MON" = MONITOR LIST
Example of assigning a command to a PF key. In this example, you assign the MONITOR LIST command to the PF16 key. When Debug Tool displays PF keys 13-24 at the bottom of the screen, it shows "PF16=MON".

Default PF key settings
PF1 or PF13
? (HELP)
PF2 or PF14
STEP
PF3 or PF15
END
PF4 or PF16
LIST
PF5 or PF17
FIND
PF6 or PF18
AT/CLEAR
PF7 or PF19
UP
PF8 or PF20
DOWN
PF9 or PF21
GO
PF10 or PF22
ZOOM
PF11 or PF23
ZOOM LOG
PF12 or PF24
RETRIEVE
Displaying help for commands
?
Displays a list of commands
AT ?
Example of displaying help for the AT command. Enter all or part of a command, followed by a question mark ("?") to display keywords that are valid at the location of the question mark.

Continuing a long command
- (dash at the end of a line)
To continue a long command (for example, a command that exceeds the size of the command line), type a dash at the end of a partial command and then press Enter. Debug Tool prompts you to enter the rest of the command.

Abbreviating commands
(use partial keywords)
You can abbreviate keywords in Debug Tool commands to the least number of letters that make the keyword unambiguous. For example, you can abbreviate the command MONITOR LIST VARX to MON LIST VARX or MO LIS VARX.

Ending a debugging session
QUIT
Ends the debugging session and prompts you to verify that you want to end the debugging session.
QQUIT
Ends the debugging session without prompting you.
QUIT DEBUG
Ends the debugging session but program continues to run. Debug Tool will not be restarted.
QUIT DEBUG TASK
This command works only for CICS. Ends debugging session but the program continues to run. Debug Tool will not be restarted. To start Debug Tool, start another iteration of a pseudo-conversational task.
QUIT ABEND
Ends the debugging session and terminates the program with an abend at the current location.

Terms of use | Feedback

This information center is powered by Eclipse technology. (http://www.eclipse.org)