Fast Loading Code Generation Program
Date: 2020-10-07 18:10:00

Up | Next | Prev | PrevTail | Tail

### 19.2 Fast Loading Code Generation Program

In most versions of REDUCE, it is possible to take any set of Lisp, Rlisp or REDUCE commands and build a fast loading version of them. In Rlisp or REDUCE, one does the following:

faslout <filename>;
<commands or IN statements>
faslend;

To load such a ﬁle, one uses the command LOAD, e.g. load foo; or load foo,bah;

This process produces a fast-loading version of the original ﬁle. In some implementations, this means another ﬁle is created with the same name but a diﬀerent extension. For example, in PSL-based systems, the extension is b (for binary). In CSL-based systems, however, this process adds the fast-loading code to a single ﬁle in which all such code is stored. Particular functions are provided by CSL for managing this ﬁle, and described in the CSL user documentation.

In doing this build, as with the production of a Standard Lisp form of such statements, it is important to remember that some of the commands must be instantiated during the building process. For example, macros must be expanded, and some property list operations must happen. The REDUCE sources should be consulted for further details on this.

To avoid excessive printout, input statements should be followed by a $ instead of the semicolon. With LOAD however, the input doesn’t print out regardless of which terminator is used with the command.

If you subsequently change the source ﬁles used in producing a fast loading ﬁle, don’t forget to repeat the above process in order to update the fast loading ﬁle correspondingly. Remember also that the text which is read in during the creation of the fast load ﬁle, in the compiling process described above, is not stored in your REDUCE environment, but only translated and output. If you want to use the ﬁle just created, you must then use LOAD to load the output of the fast-loading ﬁle generation program.

When the ﬁle to be loaded contains a complete package for a given application, LOAD_PACKAGE rather than LOAD should be used. The syntax is the same. However, LOAD_PACKAGE does some additional bookkeeping such as recording that this package has now been loaded, that is required for the correct operation of the system.

Up | Next | Prev | PrevTail | Front