5.2 Storage allocation

5.2.2 Storage areas

Lisp organizes memory into storage areas that consist of 64-kilobyte Lisp segments. Note that a Lisp segment might not be the same as a segment in the underlying operating system or hardware. Each storage area is named according to the kind of data that it contains:

The two read-only areas are the readonly-non-pointer area and the readonly-pointer area. These areas contain data structures whose contents cannot be altered and cannot contain pointers. Compiled code, symbol names, and various constant structures are put into read-only areas. Storage in these areas cannot be reclaimed by garbage collection.

This area contains data structures whose contents can be altered but cannot contain pointers. Certain permanent data structures are put into the read-write area. Storage in this area cannot be reclaimed by garbage collection.

This area contains data structures whose contents can be altered and can contain pointers to objects in dynamic space or ephemeral space. The static area contains permanent data structures, such as symbols, and various tables and buffers that are internal to the system. Storage in this area cannot be reclaimed by garbage collection.

This area contains space that can be allocated to the read-only, read-write, and static areas when those areas are full. Space from the reserved area is also allocated to the ephemeral area when ephemeral garbage collection is enabled. When the reserved area is depleted, space is reallocated to it from the dynamic areas.

This area contains user-defined data structures. Ephemeral storage is normally organized into three ephemeral levels that are created from the reserved area only when ephemeral garbage collection is enabled. Storage in this area is reclaimed by garbage collection when any of the levels is full.

This area contains user-defined data structures. Dynamic storage is normally organized into two semi-spaces, only one of which is in use at any time. Storage in this area is reclaimed by garbage collection when one of the semi-spaces is full. Storage is allocated to this area from the operating system pool.

The two discardable areas are the discardable-read-write-area and the discardable-static-area. These areas contain data structures that are not saved in an image saved bydisksave. Storage in this area cannot be reclaimed by garbage collection.

Memory can also contain foreign areas, storage areas that are used by programs in computer languages other than Lisp. See Chapter 4, "Working Beyond the Lisp Environment" in The Advanced User's Guide for more information.


The User's Guide - 9 SEP 1996

Generated with Harlequin WebMaker