Debug Manual
Table Of Contents
- What’s New in This Manual
- About This Manual
- 1 Introduction
- Execution Modes on TNS/R Systems
- What User Access Is Required for Debugging
- How to Make a Process Enter Debug
- How to Select Debug as the Debugger
- Why a Process Enters Debug
- How to Determine Process State on a Trap or Signal
- Ending a Debug Session
- What Appears in the Debug Header Message
- How to Use Debug
- How Debug Breakpoints Work
- 2 Using Debug on TNS/R Processors
- 3 Debug Command Overview
- 4 Debug Commands
- Command Summary
- A Command
- AMAP Command
- B Command
- BASE Command
- BM Command
- C Command
- CM Command
- D Command
- DJ Command
- DN Command
- EX[IT] Command
- F[ILES] Command
- FC Command
- FN Command
- FNL Command
- FREEZE Command
- HALT Command
- H[ELP] Command
- I Command
- IH Command (TNS/R Native and OSS Processes)
- INSPECT Command
- LMAP Command
- M Command
- MH Command (TNS/R Native and OSS Processes)
- P[AUSE] Command
- PMAP Command (Accelerated Programs)
- PRV Command
- R Command
- S[TOP] Command
- T Command
- V Command
- VQ Command
- VQA Command
- = Command
- ? Command
- A Error Messages
- B ASCII Character Set
- C Command Syntax Summary
- Register Syntax
- Expression Syntax
- Address Syntax
- A Command
- AMAP Command
- B Command
- BASE Command
- BM Command
- C Command
- CM Command
- D Command
- DJ Command
- DN Command
- EX[IT] Command
- F[ILES] Command
- FC Command
- FN Command
- FNL Command
- FREEZE Command
- HALT Command
- H[ELP] Command
- I Command
- IH Command
- INSPECT Command
- LMAP Command
- M Command
- MH Command
- Output-Device Syntax
- P[AUSE] Command
- PMAP Command
- PRV Command
- R Command
- S[TOP] Command
- T Command
- V Command
- VQ Command
- VQA Command
- = Command
- ? Command
- D Session Boundaries
- E Correspondence Between Debug and Inspect Commands
- F Sample Debug Sessions
- Glossary
- Index

Sample Debug Sessions
Debug Manual—421921-003
F-9
TNS Program Example
D example. The following specifies the output value to be a decimal for the D
command.
? Command
We use the ? command to see the current setting of the base:
We change the base for the output from decimal to standard and use the ? command
to check the result:
B Command (Continued)
In the above examples, we used the EXAMPLE_INIT procedure to demonstrate some
of the Debug commands. We will now set breakpoints in the EXAMPLE_MAIN
procedure in order to demonstrate other Debug commands.
We stop the program after segments 1 and 2 are allocated at offsets 21 and 44 (octal),
respectively, in the main procedure EXAMPLE_MAIN.
Under the ENTRY POINT MAP in Example F-2
on page F-4, the EXAMPLE_MAIN
procedure starts at 211 (octal). When we enter the breakpoint, we do not need to
qualify the address with the segment, because the breakpoint is in the segment we are
currently in. So instead of entering UC.0, %211+%21, we can enter %211+%21. One
way to enter the address of breakpoints is by specifying the base address and its offset
with the command, which emphasizes the relative offset in the procedure. Another way
050,03,00013-BASE DECIMAL OUT
050,03,00013-d 1, #10
#00001: #00256 #00000 #00003 #00013 #00000 #00000 #00012 #45194
#00009: #00000 #00050
Note. Both of the address output and the data output are displayed in decimal format.
Contrast this with the :D option in the example, where only the data output changes base.
050,03,00013-?
USE SEGMENT ID = NONE
BASE STANDARD IN
BASE DECIMAL OUT
TERM \M5.$ZTN00.#PTAZJAC
PRV = OFF
050,03,00013-BASE STANDARD OUT
050,03,00013-?
USE SEGMENT ID = NONE
BASE STANDARD IN
BASE STANDARD OUT
TERM \M5.$ZTN00.#PTAZJAC
PRV = OFF