Specifications
Saturn The DBUGSAT Debugger 11-9
Psy-Q Development System
You can step, trace, run to cursor and set breakpoints in the source code in much the
same way as a for Disassembly window. The cursor in the currently active text
window will track the PC during a trace. Note, however, that unlike tracing in a
Disassembly window, a trace at Source Level may trace more than one instruction as
it will trace the entire source line, which, if it is a macro or a 'C' source line, may
correspond to the execution of one or more instructions. Similarly F8 (Stepover) will
step-over the entire source line, which could be equivalent to stepping over several
subroutine calls.
If you are unsure of how a Source Level operation will behave, a Disassembly
window can be viewed at the same time to determine how the operations correspond
to actual processor instructions. If you attempt to step into a C function or Assembly
language subroutine for which the Debugger does not have any source level
information then the Debugger will attempt to perform a step-over operation instead.
If this is not possible (e.g. if the code without source level information is jumped to
rather than called), then the window display will switch to Disassembly mode. The
trace can be continued and when the PC returns to a region for which there is Source
information, the window will switch back to the Text display.
In order to use any of the Source Level features you must have the necessary extra
debugging information in your Symbol File(s). If it is not present then the Debugger
will be unable to switch to Source mode and Source Level operations will produce
appropriate error messages. This information is added to the Symbol Files by the C
compiler if you add the -g switch to your CCSAT command line or by the Assembler
if you specify the /zd switch on the ASMSAT command line.
The Symbol File normally contains the full original pathnames of all files used to build
your project. When Source Level debugging the Debugger will attempt to load those
files from the same locations. In some cases this may not be convenient e.g. if part of
the project was built by another developer on a different PC or on a network drive;
even if you have a copy of the appropriate Source Files you may not have them at the
same location.
To get around this you can provide the Debugger with a search patch for Source
Files. To do this just select a Source File window and type Alt-P. You will be
prompted to enter a normal DOS search path. This search path can contain many
entries and be as long as you wish.
e.g.
c:\;c:\temp\myfiles;c:\gnumips\src\common