Go backward to The quit Command
Go up to Debugging Facilities
Go forward to Displaying Variables

The where Command

where
When debugging mode is entered, the simulator prints a message indicating where in the program the breakpoint occurred. Additional information about the program's point of execution can be obtained using the "where" command. This command takes no arguments. When it is issued, the debugger prints a traceback listing all active functions on the call chain. That is, it lists the current active function, the caller of the current active function, the caller of the caller of the current active function, and so on. In addition, it displays the instruction from which each function called the next lower function on the call chain. The format of this display is determined by the debugger's mode.

The where command determines the call chain by examining the contents of the call stack in the machine's memory. Accordingly, if the program stack is corrupted due to an error in the program being simulated, it may not be possible to produce an accurate traceback.



Prev Up Next