[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: GC, exit-to-system

In article <FAHLMAN.12221704534.BABYL@C.CS.CMU.EDU> Fahlman@C.CS.CMU.EDU (Scott E. Fahlman) writes:
>I've been thinking about the GC issue since it first came up.  Even
>though systems differ tremendously in what GC means to them, it might
>make sense to provide a portable GC construct for use in portable code.

I agree.  Perhaps something more generic like CLEAN-STATE would be
appropriate - it could do whatever "freshening up" might be appropriate,
such as handling all pending interrupts or rehashing of internal tables
or whatever other exotic things implementations might be doing concurrently
with computation.

>I am somewhat more doubtful about the usefulness of BYE in any sort of
>portable code.  One could argue that it would give users a standard way
>of getting out of Lisp on any system where that makes sense, and that it
>always is best to have recognizable signs on the emergency exits.

If one were to argue against BYE, then one would also have to flush
ED and ROOM and all other things that are required, but whose operation
is highly unspecified.  Along the same lines, it might make sense to
require that an implementation should have a world dumper called
SAVE-SYSTEM that takes a filename and puts in the file a copy of the 
lisp such that when it is restored (by unspecified means) you are
in the state just before the SAVE-SYSTEM was done.  This is something
almost every Lisp provides, but with wildly varying details.  It would
of course be OK to have lots of extra keywords on such a function, but
a portable implementation of an embedded language can just supply the
filename to SAVE-SYSTEM and expect it to work almost everywhere.