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

si:full-gc & Optimize World

    Date: Tue, 2 Aug 88 10:42 EDT
    From: steinmetz!VEGA!jka@uunet.uu.net (Jim Aragones)

    I've just been rewriting our world-building script to do some new things
    and noticed that the documentation implies that you can't use
    calling (SI:FULL-GC), but the documentation says:

What I assume you are refering to is the first sentence of the
documentation of SI:REORDER-MEMORY: "This function can be run after
SI:FULL-GC."  It is correct, but you are missing one thing: Symbolics
did a full GC before they made the distribution world that was shipped.

    "It is not useful to perform an Incremental Disk Save after running
    si:full-gc. Use a complete disk save."

What this means is that you shouldn't make an IDS world if you have done
a full GC since booting.

The way to understand this is to realize what an IDS world is.  A
complete world is simply a snapshot of the Lispm's virtual memory at the
time it was saved.  An IDS world is a snapshot of those parts of VM that
have changed since the world was booted.  A full GC copies every
accessible object in memory to a new location; when it is done there are
no non-garbage objects on unmodified pages of memory.  An IDS world made
after a full GC would be at least as big as the equivalent complete
world, yet it would not actually use anything from its parents.

    "You should use si:reorder-memory on IDS worlds only if the parent world
    has itself been optimized or if the parent world does not need

SI:REORDER-MEMORY mostly only touches memory that was modified since the
last (SI:FULL-GC) or (SI:REORDER-MEMORY) (whichever is more recent).  If
the parent world wasn't optimized with one of these functions, then it
will have to reorder the memory that was modified in the parent world as
well as in the current bootload.  This will cause the new IDS world to
include new copies of all the pages that came from the parent world.

    Assuming that I want to reorder memory or enable-who-calls for an
    incremental world load, how do I loose (or win) by using (GC-IMMEDIATELY)
    instead of (SI:FULL-GC)?  I could make an educated guess, but I'd rather
    have facts if people have them.

If you want to enable the who-calls database, call SI:ENABLE-WHO-CALLS
and then probably SI:COMPRESS-WHO-CALLS-DATABASE.  If you want to
reorder memory, call SI:REORDER-MEMORY.  The latter should be done after
the former if you do both, so that the who-calls DB will be optimized if
necessary; in general, SI:REORDER-MEMORY should be one of the last
things done before saving the world.  You shouldn't need to do a
GC-IMMEDIATELY; SI:REORDER-MEMORY appears to include much of its