12.7.2 Specifying Overlays

Specify overlays by enclosing object-file (and possibly load-library) names in parentheses in the objfiles field. Each group of object files bracketed by parentheses represents one overlay. Overlays cannot be nested.

The remaining modules (those not in parentheses), and any drawn from the run-time libraries, constitute the resident (or root) part of your program. The entry point to the program (for example, main() in a C program, or PROGRAM in a FORTRAN program) must be in the root.

Example

The following list of files contains three overlays:

a + (b+c) + (d+e) + f + (g)

In this example, the groups (b+c), (d+e), and (g) are overlays. The remaining files a and f and any modules from libraries in the libraries field remain memory-resident throughout the execution of the program.

It is important to remember that whichever object file first defines a segment gets all contributions to that segment. In the example above, if D.OBJ and F.OBJ both define the same segment, the contribution from F.OBJ to that segment goes into the (d+e) overlay rather than into the root.