[gclist] What wrong with the GC in xemacs
Daniel Barlow
dan@detached.demon.co.uk
Fri, 12 Apr 1996 20:13:10 +0100
Nick Kramer <nk24+@andrew.cmu.edu> writes:
>Excerpts by ianr@lsl.co.uk
>> We all know that the GC in emacs is bad, but what is wrong with it?
>
>I'm not convinced it *is* bad. Ever since they put in the "do a GC if
>the user's idle" feature in Emacs 19, I have not once been interrupted
>by a GC while typing. So by the "how much it disturbs interactive use"
>criteria, it does just fine. I'm not really sure what other criteria
>there could be -- total execution time spent in GC? Number of annoying
>"Garbage collecting...done" messages?
How about time spent thrashing on too-small-but-ought-to-be-big-enough
machines? Try this:
1) Find an 8Mb machine. Apparently it's hard to get hold of one these
days, but I can let you have mine in return for one of those 32Mb
Pentiums that Microsoft would have us believe are given away in
cornflake boxes these days...
2) Start a reasonable emacs session. Say, five or six files, a couple
of subprocesses (I guess you'll all be wanting to run a lisp
interpreter, right?). Get used to the interactive feel. Perfectly
usable.
3) Repeat (2) with a 200-message RMAIL or vm folder, or anything else
which forces the total size of emacs bigger than the available
physical memory. Major thrashing.
Now, OK, you can't reasonably use a program whose working set is
bigger than available RAM, but the whole point is that even when
you're _not_ reading your mail and the whole 200 message folder should
be sitting quiescent in swap, it's still getting paged in. This is
kind of at odds with the idea that you should start emacs once when
you log in (on a multiuser system) or reboot (on a workstation, or the
PC that I laughably call one) and leave it there to accumulate files
until you have to take it down again. My OS uses `traditional'
explicit memory allocation, and stays up for weeks (when I resist the
temptation to upgrade it); my emacs is GCed to ensure no leaks, and
has to be shut down and restarted every fourth day or so.
A cynic would ask what's so great about GC? :-)
Daniel
--
http://ftp.linux.org.uk/~barlow/, dan@detached.demon.co.uk, PGP key ID 5F263625
``Consistency is the last refuge of the unimaginative'' --- Oscar Wilde