Open System Services Porting Guide (G06.24+, H06.03+)

Table Of Contents
The Development Environment
Open System Services Porting Guide520573-006
2-19
Using the Debuggers With OSS Files
Refer to the Inspect Manual, Native Inspect Manual, or the Visual Inspect online help
for command details.
When an Inspect session begins, Inspect looks for an EDIT file named INSPLOCL in
the Guardian volume and subvolume containing the Inspect program file. The Inspect
program reads and executes Inspect commands contained in the INSPLOCL file. You
can also place Inspect commands in the Inspect custom file INSPCSTM in your default
logon directory. Commands in INSPCSTM are also executed when an Inspect session
begins. Commands in INSPCSTM override those in INSPLOCL because Inspect reads
INSPCSTM after reading INSPLOCL.
Native Inspect also provides a custom file in the default logon directory, named
EINSCSTM. This file can contain any Native Inspect commands you want to be
executed when the Native Inspect session begins.
All three debuggers let you set breakpoints at both code and data locations within your
program. You also can limit a breakpoint so that it suspends program execution only if
certain conditions exists.
Debugging Native Program Files
This subsection briefly introduces what is different about debugging native program
files. Refer to the Inspect Manual, the Native Inspect Manual, or the Visual Inspect
online help for the complete syntax of the debugger commands and detailed
explanations of the debugging features for native program files.
The Inspect, Native Inspect, and Visual Inspect debuggers create and read save files,
or snapshot files, from native processes. These files contain saved stack frames,
global data and heap areas, and the main stack. Inspect supports TNS/R native SRLs,
Native Inspect supports DLLs, and Visual Inspect supports both TNS/R native SRLs
and DLLs. This includes setting code and data breakpoints in SRLs or DLLs per
process, creating save files for applications that use SRLs or DLLs, and displaying and
modifying identifiers from SRLs or DLLs.
Debugging native processes differs from debugging TNS or accelerated processes.
Unlike TNS and accelerated processes, native processes do not maintain the TNS
process environment: for example, the TNS environment registers.
The optimization level option used with the native programs directly affects source-
level debugging. Source-level debugging could result in statements being merged and
a delay in updating memory from registers.
You can also use the noft or enoft utility to examine native program files. The noft
and enoft utilities can set and reset the Inspect flag in a native object file. See Using
the noft and enoft Utilities on Native Program Files on page 2-21 for more information
on debugging native program files.