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-4
Calling Debug From a Process
contains CALLABLE or PRIV procedures) can be put into debug state only by the
local super ID.
If a process is created privileged, it will never run unprivileged, so DEBUG would
be ineffective; therefore, DEBUG is rejected for an initially privileged process. Use
DEBUGNOW instead.
cpu,pin
is the processor in which the program to be debugged is executing and its process
identification number.
process-name
is the process name of the program to be debugged. If you use the process-name
form, the primary process of a process pair enters the debug state.
TERM [[\sys-name.]$terminal-name [.#qualifier ]]
TERM specifies the new home terminal of the process being debugged. If you omit
TERM, Debug prompts appear on the original home terminal of the process. If you
specify TERM but omit the terminal name, Debug uses the terminal from which you
just entered this command. You must include the \sys-name if the new home
terminal is connected to a system other than the current default system.
Example:
(BREAK key pressed)
20> STATUS *,TERM
Process Pri PFR %WT Userid Program file Hometerm
$Z159 1,152 123 R 000 9,215 $VOL1.SV1.POBJ $T1
.
.
21> DEBUG 1,152
DEBUG $PC=0x7000D820
106,01,00152-
Calling Debug From a Process
Programs can include explicit calls to a debug facility. This method is quite useful for
finding elusive error conditions. The procedures that call a debug facility invoke either
Debug or the Inspect debugger depending on which debugger has been previously
selected. These procedures can invoke the debug state for the current process or the
designated process. The procedures are:
•
DEBUG procedure, which invokes Debug for the current process
•
PROCESS_DEBUG_ procedure, which can invoke Debug for either the current
process or the called process
•
DEBUGPROCESS procedure, which invokes Debug for the specified process