Object Code Accelerator Manual
Debugging OCA Programs
Object Code Accelerator Manual—528144-003
7-2
Register-Exact Points
maintained, no change is required to run existing TNS programs on TNS/E systems
and, with very few exceptions, debugging is the same.
Register-Exact Points
Register-exact points are locations in an accelerated program at which the values in
both memory and the TNS register stack are the same as if the program were
executing on a TNS system. No optimizations cross register-exact points. Complex
statements might contain several such points: at each function call, privileged
instruction, and embedded assignment. Register-exact points are a subset of memory-
exact points.
By default, OCA defines register-exact points only where necessary for correct
execution; for example, following procedure calls. Many statements have no register-
exact point. Register-exact points are the only points at which an accelerated program
makes transitions to and from executing TNS instructions. Some complex statements
might contain several register-exact points, particularly at each function call.
At register-exact points, you can safely use all Visual Inspect, Native Inspect, or
Inspect debugging commands (including modifying memory variables) as if the
program were on a TNS system.
Memory-Exact Points
Memory-exact points are locations in an accelerated program at which the values in
memory (but not necessarily in the register stack) are the same as if the TNS/E
program were running on a TNS processor. Displaying memory variables gives
accurate results at memory-exact points. However, modifying memory variables at
these points might not reliably affect the program’s subsequent actions because the
changed variable might have already been loaded in registers. Most source statement
boundaries are memory-exact points. Register-exact points are a subset of memory-
exact points.
Nonexact Points
Nonexact points are locations in an accelerated program that are not memory-exact
points. Most code locations in an accelerated program are nonexact points. At
nonexact points, the TNS program state is not consistent, displayed memory might not
be current, and the reported current program counter location is only approximate.
Attempting to modify memory at a nonexact point might result in the data being
overwritten by a subsequent store operation.
A Strategy for Debugging
In general, debug the TNS object code version of your complete program before
running OCA. Then accelerate a version of the program containing an Inspect symbols
region, using the Visual Inspect or Native Inspect, and perform final testing.