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

Introduction
Debug Manual—421921-003
1-7
Why a Process Enters Debug
3. When linking the program object file, specify the nld or Binder command
SET INSPECT OFF. Note that the command SET SAVEABEND ON also sets
INSPECT ON. You might want to ensure that the command
SET SAVEABEND OFF is also specified. If the program object file has already
been created, you can accomplish the same thing by specifying the nld or Binder
commands CHANGE INSPECT OFF and CHANGE SAVEABEND OFF for the file.
For more information on nld commands, see the nld Manual and the noft Manual.
For more information on Binder commands, see the Binder Manual. For more
information on compiler directives, see the reference manual for the particular
compiler.
Why a Process Enters Debug
There are several reasons a process might unexpectedly enter Debug by default:
•
The process tried to call an undefined external procedure.
•
The process called the DEBUG procedure.
•
Another process specified the process in a call to the DEBUGPROCESS or
PROCESS_DEBUG_ procedure.
•
In the case of a TNS/R native process, the process received a signal and either the
installed signal action was SIG_DEBUG or a user-supplied signal handler invoked
Debug.
•
In the case of a TNS/R native process that previously had been in the debug state,
the installed signal action is SIG_DFL and the process received a signal for which
the SIG_DFL action is normally process termination. For such a process, the
SIG_DFL action for these signals becomes invocation of Debug. (This applies to
all native signals and to most OSS signals.)
•
In the case of a TNS process, a trap occurred and the process had previously
neither specified its own trap-handling mechanism nor disabled traps by a call to
the ARMTRAP procedure.
How to Determine Process State on a Trap or
Signal
If a TNS process enters Debug because a trap occurred, Debug automatically displays
the number of the trap. The trap numbers that can be displayed are:
Trap Number Trap Condition (page 1 of 2)
0 Illegal address reference
1 Instruction failure
2 Arithmetic overflow
3 Stack overflow