Debug Manual

Table Of Contents
Debug Command Overview
Debug Manual421921-003
3-15
Address Syntax
To display the contents of the direct variable DB^COUNTREAD, this display
command is entered:
106,01,00012-D 11 ! Display user global location %11
Debug displays the following:
000011: %000310
To display the contents of the pointer variable DB^BUF, this display command is
entered:
106,01,00012-D 10 ! Display global location %10
Debug displays the following:
000010: %000116 ! A word address
To display the FNUM value parameter of a procedure, the procedure’s map of
identifiers is referred to:
ERRCNT VARIABLE INT L-004 INDIRECT
ERRORNUM VARIABLE INT L-003 INDIRECT
FNUM VARIABLE INT L-005 DIRECT
Then this display command is entered:
215,00,00035-D L-5 ! Display L-relative location -5
Debug displays the following:
000370: %000002
Using the Indirect Form
To display the contents of an indirect array, the indirect form of the display
command is used.
For example, to display the first element of DB^BUF, the relative-address I form of
the display command is entered:
215,00,00035-D 10I ! Display indirect, using user global location %10
Debug uses location G[%10] as the indirect address of the location to be
displayed. The following is displayed:
000116: %063162
As another example, suppose the programmer wants to display in character form
20 words of the indirect array DB^BUF, starting with word [20]. This requires use of
the indirect, indexed form of the display command. This command is entered:
215,00,00035-A 10I #20,#20
Debug calculates the address of the first word to be displayed by adding 20 to the
address value of G[%10]. Twenty words are displayed, in character form, starting
at the calculated location:
000142: .12. .34. .5 . .gr. .ap. .e . .la. .ne.
000152: . . . . . . . . . . . . . . . .
000162: . . . . . . . .
Displaying the contents of an indirect byte array requires that the indirect byte
address be converted to its word equivalent. This is accomplished by using the
indirection type S in the address for the display command.