Search                        Top                                  Index
HELP POPMEMLIM                                A. Law, August 1987

The variable -popmemlim- has an integer value that specifies the maximum
number of words to which the system should expand the combined memory
area for the heap and user stack.

The related variable -popminmemlim- is used to specify the minimum
allocation of space. It is often useful if you need to force the memory
manager to make use of available memory. See REF * POPMINMEMLIM

If attempting to create a data-structure proves impossible because
all the space in the heap is in use, the store manager will cause
a garbage collection. If there is still not enough space it will try
to allocate extra space, within the limit set by -popmemlim-. If there
is already that amount of heap+stack space allocated, and there is no
space to create a data-structure required y the user, then system
will mishap, with the message:

    ROM: MEMORY LIMIT (popmemlim) EXCEEDED (allocating XXX space)

where XXX is 'heap' or 'stack' to indicate whether the memory allocation
request  that caused  the mishap  was for  a data structure in the heap,
or for space on the user stack.

    The default value for -popmemlim- is 100000 (i.e. 400,000 Kbytes)
(but higher defaults are used by the Prolog and Lisp systems); if this
is not large enough for your program, you should experiment with
increasing it gradually (e.g. in steps of 100000, or doubling it, etc).
(Increasing it by too large an amount may cause garbage collections
to become slower, by virtue of there being insufficient extra
memory available to use the copying GC algorithm -- see REF * SYSTEM).

Note that, regardless of POPMEMLIM, the mishap

    'ROM: NO MORE MEMORY AVAILABLE (allocating XXX space)'

may also occur;  this indicates  that the system  can expand  no
further, because  no  more  memory can  be  allocated  from  the
operating system (either because of a set limit on process size, or
through a lack of swap space, etc).


-- RELATED DOCUMENTATION ----------------------------------------------

REF *SYSTEM     - more details of system control procedures
REF *PROCEDURE  - (-pop_callstack_lim-) max length of call stack
REF *PROLOG     - (-pop_prolog_lim-) max size of continuation stack and
                    trail

--- C.all/help/popmemlim
--- Copyright University of Sussex 1990. All rights reserved. ----------