Debug Manual

Table Of Contents
Sample Debug Sessions
Debug Manual421921-003
F-33
Native Program Example
The length is the number of 32-bit words to display. The :H 2 part of the first command
below breaks the output into two-byte hexadecimal groups. The :D part of the second
command breaks the output into two-byte decimal groups.
We again check for open files. This time file number 1 is opened with the name shown
with the A command and the DN :A command.
FC Command
The default output for the DN command is hexadecimal. We can change the output
using the base option. (Use HELP DN for syntax information.) Below, we use the FC
command to change the command. We can look at the contents of the program’s
global variable PROCESS_HANDLE array in the default form and in decimal form. The
PROCESS_HANDLE array starts at program _GLOBAL address 2 and is five 32-bit
words long.
At this point in the procedure, the local extended integer pointer, HANDLE_PTR,
located at $SP + %HB0, is set to the program’s global array, PROCESS_HANDLE,
starting at _GLOBAL + 2. Thus, we know the address for _GLOBAL is 0x08000002.
050,03,00266-DN 0x08000000, 1 :H 2
08000000: 0x0001 0x0100
050,03,00266-DN $SP + %H7E, 1:D
4FFFFEAE: #00019 #23629
050,03,00266-DN $sp + %h80, #20/4 :A
4FFFFEB0: .\M5.. .$ZTN. .00.#. .PTUG.
4FFFFEC0: .RB0..
050,03,00266-F
# -1 ??? # 00000
#001 \M5.$ZTN00.#PTUGRB0 # 00000
050,03,00266-DN 0x08000000 + %H2, #5
08000002: 0x01000000 0x0003010A 0x00000000 0x000BDB4C
08000012: 0x00000032
050,03,00266-FC
DN 0x08000000 + %H2, #5
............. :D
DN 0x08000000 + %H2, #5 :D
.............
08000002: #00256 #00000 #00003 #00266 #00000 #00000 #00011 #56140
08000012: #00000 #00050