VLISP provides a number of
options for compiling and linking a project's source code that affect
the efficiency of the compiled code. For example, you can specify
whether to create a separate FAS file for each source file or merge all
compiled files into a single FAS file. You can choose to have the
compiler remove the names of all local symbols from your compiled
files. You specify these options in the Project Properties dialog
box.
To specify project build options
- Open
the project file (choose Project
Open Project from the
VLISP menu).
- Choose
the Project Properties button in the Project window toolbar.
- Select
the Build Options tab in the Project Properties dialog box. VLISP
displays the Build Options dialog box:
Some
of the build options require extensive background information, which is
provided in the following sections of this chapter. The build options
are:
- Compilation Mode
-
Choose between standard
and optimized compilation. Optimized compilation creates smaller
and faster programs but is not suited for every project. See
Choosing a Compilation Mode for
more information on this topic.
- Merge Files Mode
-
Tell the compiler whether
to create a separate FAS file for each source file, or to merge
all compiled files into a single FAS file.
A single FAS file is faster to load and is required for
certain types of optimization. Sometimes, however, you will prefer
to load your code one file at a time. This is important if you have
not completed the debugging or modification of the application's
code. FAS files do not allow source code debugging, so it is recommended
that you compile your code only after the initial debugging is done.
- Edit Global Declarations
-
Create or edit a global
declarations file for the project.
This feature is provided for compatibility with the
Preview version of VLISP.
- FAS Directory
-
Specify
the directory for compiled files. If you indicate a relative path,
VLISP applies it in relation to the project's home directory. If
you leave the field blank, VLISP places compiled files in the same
directory as the project definition (.prj) file.
- Tmp Directory
-
Specify
the directory for project-related temporary files. A relative path
is applied in relation to the project's home directory.
- Link Mode
-
Specify
how function calls are to be optimized. This option is only available
if optimized compilation is selected. Choose from the following:
- Do
not link: This results in indirect linking of functions.
The compiler stores the address of the symbol naming the function.
- Link: If
selected, the compiler directly addresses function definitions and
all calls where the functions are referenced.
- Internal: This
directly links function calls and removes (drops) the function names
from the resulting FAS files.
See
Choosing a Link Mode for
further information on these options.
- Localize Variables
-
If this
option is selected, the compiler removes (drops) the names of all
local symbols from compiled files and directly links their references, wherever
possible. This means the program code points to the address where
a variable is stored, not to a symbol used to find the address of
the variable.
- Safe Optimize
-
If this option is selected, this
option directs the compiler to refuse some types of optimization,
if there is a chance they will result in incorrect code. For more
information on optimization, see
Choosing a Compilation Mode below.
- Message Mode
-
Select
the level of detail you want VLISP to produce in its compilation
reports. You can choose to receive a report showing only fatal errors
(those causing compilation failure), a report showing errors and
warning messages, or a full report showing errors, warnings, and compiler
statistics.