Category : Pascal Source Code
Archive   : TPCV13.ZIP
Filename : TPCV.MAN

Output of file : TPCV.MAN contained in archive : TPCV13.ZIP

Source Level Debugging Comes to Turbo Pascal 4.0


Welcome to source level debugging with Turbo Pascal 4.0 and Microsoft
CodeView. TPCV is a utility which reads the .MAP file produced by
TPMAP and appends CodeView debugging records on the executable file
output by Turbo Pascal. The modified .EXE file can then be used with
Codeview for a complete source level debugging environment.


This program was developed out of the need to provide a quality source
level debugging environment for Turbo Pascal 4.0 and is distributed as
shareware. Please feel free to make copies and distribute TPCV among
your friends. We do ask that if you find this program useful, that
you send Paradigm Systems $25.00 as a registration fee. Registered
users of TPCV will be eligible for technical support, an option to
purchase the source code plus other information relating to the use of
TPCV as it becomes available.

Paradigm Systems
PO Box 152
Milford, MA 01757

Using TPCV

For Turbo Pascal 4.0 owners with access to Microsoft CodeView, this
utility will convert the output of Turbo Pascal to a format suitable
for use by CodeView. Under CodeView, all source modules (and units)
can be debugged by stepping line by line or setting breakpoints. When
the user steps into a function or procedure, the source code for the
new module automatically appears and disappears when the module is
exited. Most of the powerful debugging features of CodeView are
available to Turbo Pascal programmers.

Because the initial release works on the .MAP file output by TPMAP and
not the .TPM file output by Turbo Pascal, the debug information is
limited to public symbols and line numbers. There is currently no
support for local variables and function/procedure arguments, thus
declaring variables global for debugging purposes will increase the
effectiveness of CodeView. You will have access to all public symbols
which include all data, function and procedure names that appear in
the interface section of a unit, along with the global data in the
main program. These symbolic names can be used to set breakpoints,
display data in a variety of formats as well as skip through the
source code using a mouse.



Some brief hints and suggestions concerning the use of TPCV. All
files and units to be debugged must be compiled using the /$T+ and
/$D+ switches. Rather than enter these options each time, they can be
permanently enabled by placing them in the TPC.CFG file. The Borland
utility TPMAP is then run on the main program to generate .MAP file
used to access line numbers and publics. The syntax for the utility
is simply

tpcv exe_file

For example, the following sequence would be used to compile and debug
the demo file GRDEMO.PAS (included on the TP 4.0 distribution

tpc grdemo /$D+ /$T+
tpmap grdemo
tpcv grdemo
cv /s grdemo

With TPCV, debugging Turbo Pascal programs such as MCALC are easy.

CodeView Availability

The CodeView debugger is shipped as part of the Microsoft Assembler
5.00 packages or with other Microsoft languages. What better excuse
to upgrade your assembler ($40.00) than to getting a powerful source
level debugger for Turbo Pascal.

Hints on Using CodeView

No data typing is input to CodeView thus it is necessary for the user
of TPCV to specify the data type on the command line when using a
display command. The following examples show how to display the basic
data types from Turbo Pascal:

d CHAR, c
d INT, d

Refer to the CodeView user manual for complete details.

Also note that the Borland floating point format in the emulation is
not supported but that native 8087 code is supported.



This release of TPCV hopefully fixes a bug which prevented source
level debugging when the size of the executable was greater than 64K
in size. While not extensively tested in this area, it appears that
this problem has been fixed. As always, send any problem reports to
the attention of Paradigm Systems.

Thanks for your support and enjoy true source level debugging.

Paradigm Systems