| Allegro CL version 10.1 Unrevised from 10.0 to 10.1. 10.0 version |
This global variable controls the global garbage collection behavior. Depending on its value, global garbage collections do or do not occur automatically and the user is or is not warned about global gc's.
Note: this variable works as described only if the
value of the variable *gc-after-hook*
is its initial value or a
function that preserves the initial behavior (of recording bytes
tenured correctly). See the description of *gc-after-hook*
for information on modifying
its value in a way that preserves its initial behavior.
The possible values for *global-gc-behavior* are given in the following table:
Value |
Effect |
:auto |
Whenever the number of bytes tenured
since the last global gc exceeds the value of the variable *tenured-bytes-limit* , a
global gc will be triggered automatically. After the global gc,
the tenured byte count is set to 0. |
:warn |
Whenever the number of bytes tenured
since the last global gc or warning exceeds the value of the
variable *tenured-bytes-limit* ,
a warning will be printed to *terminal-io* saying:
Warning: [xxx] bytes have been tenured; (gc t) is recommended No global gc will be triggered; users have to cause a global gc themselves. A global gc can be triggered immediately by evaluating the form (see the description of gc): (excl:gc t) A global gc will occur after the next scavenge if you evaluate the following form: (setf (sys:gsgc-switch :next-gc-is-global) t) (The switch will be reset to |
:auto-and-warn |
The behavior combines that of
:auto and :warn . A global
gc is triggered when the number of bytes tenured exceeds the
value of *tenured-bytes-limit* and a warning
message, explaining that a global gc is occurring, is also printed.
The warning message is designed
to tell the user why Lisp seems to have stopped for a
while (global gc's can take several
minutes to complete). |
A list of 2 or 3 elements | The contents of the list are, in order:
timeout -- a positive integer, specifying a number of seconds factor -- a real >= 1.0 verbose -- (optional) This value should not be used in SMP Lisps (determining
when the system is idle is ill-definied in an SMP Lisp).
If the |
nil |
No warning will be printed and no global gc will be triggered automatically regardless of the number of bytes tenured. |
Note that binding this variable will likely not have the desired effect. Lisp usually runs with multiprocessing enabled (since that is required by the Emacs-Lisp interface). If you bind this variable in one process, the binding will not be seen by another process which could swap in and cause a global gc.
See gc.htm for more information on garbage collection and gsgc parameters. See particularly section Global garbage collection in that document for information on global garbage collection.
Copyright (c) 1998-2022, Franz Inc. Lafayette, CA., USA. All rights reserved.
This page was not revised from the 10.0 page.
Created 2019.8.20.
| Allegro CL version 10.1 Unrevised from 10.0 to 10.1. 10.0 version |