HOW TO USE THE DEBUG INTRINSIC [ MPE Debug/Stack Dump Reference Manual ] MPE/iX 5.0 Documentation
MPE Debug/Stack Dump Reference Manual
HOW TO USE THE DEBUG INTRINSIC
In order to use the DEBUG intrinsic in a FORTRAN program, you should
insert in your program declarations, the following statement:
SYSTEM INTRINSIC DEBUG
This defines the intrinsic to the program and allows you to make calls to
DEBUG. Then all you need to do is insert a call to DEBUG at the beginning
of your program as the first executable statement. When this call is
executed, it places the program in DEBUG mode exactly as if you had run
the program with the DEBUG parameter in the :RUN command. Note that the
intrinsic is ignored if the program is executed in a batch job.
Figure 3-6 shows the compilation listing of the FORTRAN program DBTE ST.
The program is identical to DBTEST1 used in the previous discussion
except for the call to DEBUG and its declaration. (Refer to items I and
2.) The new statement increases all subsequent locations by 1 so that
the instruction at label 10 is now at code offset 13, and the instruction
at label 20 is at code offset 76. Otherwise, the compilation listings
for the two programs are identical.
Figure 3-7 shows the PMAP listing for program DBPROG (the prepared
program file resulting from preparation of DBTEST). This map is identical
to the map for DBPROG1 (see Figure 3-2) except that the intrinsic DEBUG
requires a new STT entry, and the STT entry for TERMINATE' has been
increased to compensate.
MPE/iX 5.0 Documentation