CodeView TOOLS.INI Entries

You may want to specify or change entries in TOOLS.INI to customize CodeView. Table 8.1 summarizes the TOOLS.INI entries.

Table 8.1 CodeView TOOLS.INI Entries

Entry Description

Autostart Commands to execute on startup
Color Screen colors
Cvdllpath Path to CodeView .DLL files
Eval Expression evaluator
Helpbuffer Size of help buffer
Helpfiles List of help files
Model Additional execution model (such as p-code)
Native Native execution model
Printfile Default name for print command or file
Statefileread Read or ignore CURRENT.STS state file
Symbolhandler Symbol handler
Transport Transport layer

Autostart

The Autostart entry specifies a list of Command-window commands that CodeView executes on startup.

Syntax

Autostart:command[[;command]]...

command

A command for CodeView to execute at startup. Separate multiple commands with a semicolon (;).

Example

The following entry automatically executes the program's run-time startup code. It specifies that CodeView always starts with the Screen Swap option off and the Trace Speed option set to fast.

Autostart:OF-;TF;Gmain

Color

The Color entry is retained only for compatibility with previous versions of CodeView. You should set screen colors with the Colors command on the Options menu.

Cvdllpath

The Cvdllpath entry specifies the default path for CodeView's dynamic-link libraries (DLLs). CodeView searches this path when it cannot find its DLLs in CodeView's directory or along the PATH environment variable. This entry is recommended.

Syntax

Cvdllpath:path

path

The path to the CodeView .DLL files.

Eval

The Eval entry specifies an expression evaluator. The expression evaluator looks up symbols, parses, and evaluates expressions that you enter as arguments to CodeView commands. If there is no Eval entry in TOOLS.INI, CodeView loads the C++ expression evaluator by default. CodeView uses the specified expression evaluator when you are debugging modules with source files ending in the specified extensions.

Syntax

Eval:[[path\]]EEhostevaluator.DLL extension...

path

The path to the specified expression evaluator.

host

The host environment.

Specifier Operating Environment

D1 MS-DOS
W0 Windows

evaluator

The source language expression evaluator.

Specifier Source Language

CAN C or MASM
CXX C, C++, or MASM

extension

A source-file extension. CodeView uses the specified expression evaluator when it loads a source file with the given extension. You can list any number of extensions.

Example

The following example loads both the C and C++ expression evaluators for the MS-DOS CodeView:

Eval:C:\C700\DLL\EED1CAN.DLL .C .ABC .ASM .H

Eval:C:\C700\DLL\EED1CXX.DLL .CPP .CXX .XYZ .HXX

With the entries in this example, when you trace into a module whose source file has the extension .C, .ABC, or .ASM, CodeView uses the C expression evaluator. When you trace into a source file with a .CXX, .CPP, or .XYZ extension, CodeView switches to the C++ expression evaluator. Note that the C++ expression evaluator alone is sufficient for most C, C++, and MASM programs.

You can load expression evaluators after CodeView has started by using the Load command from the Run menu. You can override CodeView's automatic choice of expression evaluator by using the Language command on the Options menu or the USE command in the Command window.

For more information about choosing an appropriate expression evaluator and how to use expressions in CodeView, see Chapter 11, “Using Expressions in CodeView.”

Helpbuffer

The Helpbuffer entry specifies the size of the buffer CodeView uses to decompress help files. You can set Helpbuffer to 0 to disable Help and maximize the amount of memory available for debugging. Otherwise, specify a value between 1 and 256.

Syntax

Helpbuffer:size

size

The number of kilobytes (K) of memory to use for decompressing help files. The default help buffer size is 24K. Specify 0 to disable help.

The following table shows values you can specify and the actual size of the buffer that is allocated:

Value Specified Help Buffer Size

1–24 24K
25–128 128K
129–256 256K

The smallest buffer size is 24K, and the largest is 256K.

Helpfiles

The Helpfiles entry lists help files for CodeView to load. These files are loaded before any files listed in the HELPFILES environment variable.

Syntax

Helpfiles:file[[;file]]...

file

A directory or help file. If you list a directory, CodeView loads all files with the .HLP extension in that directory. Separate multiple files or directories with a semicolon (;).

Model

The Model entry specifies an additional execution model that CodeView uses when you are debugging nonnative code such as p-code. The execution model handles tasks specific to the type of executable code that you are debugging.

Syntax

Model:[[path\]]NMhostmodel.DLL

path

The path to the specified file.

host

The host environment must be one of the following:

Specifier Operating Environment

D1 MS-DOS
W0 Windows

model

A nonnative execution model. The p-code execution model (PCD) is required if you plan to debug p-code.

Example

Model:NMD1PCD.DLL

Native

The Native entry specifies the native execution model. This DLL handles tasks that are specific to the machine and operating system on which you are running (the host) and specific to the native code (the target).

Syntax

Native:[[path\]]EMhosttarget.DLL

path

The path to the specified native execution model.

host

The host environment must be one of the following:

Specifier Operating Environment

D1 MS-DOS
W0 Windows

target

The target environment must be one of the following:

Specifier Operating Environment

D1 MS-DOS
W0 Windows

Printfile

The Printfile entry lists the default device name or filename used by the Print command on the File menu. This can be a printer port (for example, LPT1 or COM2) or an output file. If Printfile is omitted, CodeView prints to a file named CODEVIEW.LST in the current directory. This entry is ignored by CVW, which does not have the Print command.

Syntax

Printfile:path

path

The path to the specified output file or the name of a device.

Statefileread

The Statefileread entry tells CodeView to read or ignore the CodeView state file (CURRENT.STS) on startup. You can toggle this setting from the command line using the /TSF (Toggle State File) option. These options have no effect on writing CURRENT.STS. CodeView always saves its state on exit.

Syntax

Statefileread:[[y|n]]

y (yes)

CodeView reads CURRENT.STS on startup.

n (no)

CodeView ignores CURRENT.STS on startup.

Symbolhandler

The Symbolhandler entry specifies a symbol handler. The symbol handler manages the CodeView symbol and type information.

Syntax

Symbolhandler:[[path\]]SHhost.DLL

path

The path to the symbol handler.

host

The host environment must be one of the following:

Specifier Operating Environment

D1 MS-DOS
W0 Windows

Transport

The Transport entry specifies a transport layer. A transport layer provides the data link for communication between the host and target during debugging.

Syntax

Transport:path\TLhosttransport.DLL

path

The path to the specified transport layer.

host

The host environment must be one of the following:

Specifier Operating Environment

D1 MS-DOS
W0 Windows

transport

Specifies a transport layer.

Specifier Transport Layer

LOC Local transport layer
COM Serial remote transport layer

You specify the local transport layer (LOC) when the debugger and the program you are debugging are running on the same machine. With the appropriate transport layer, CodeView can support remote debugging across serial lines or networks. For more information on remote debugging, see Chapter 10.

The following example specifies the transport layer for debugging a program that is running on the same machine.

Example

Transport:C:\C700\DLL\TLW0LOC.DLL