[gclist] GC topics

boehm.PARC@xerox.com boehm.PARC@xerox.com
Tue, 20 Feb 1996 13:53:05 PST


"I would like to use GC for business applications with GUIs.  However, the
systems using GC with which I am personally familiar (e.g. Lisp) have the
problem that a GC causes the GUI to stutter or hang and annoy the user."

I think this is much less of a problem nowadays than it used to be, for a
variety of reasons:

1. Processors have been getting much faster.  Memories and hence heap sizes
have only been getting a little bigger, especially in the PC world.  Hence even
dumb garbage collectors often look fairly good on modern machines, at least if
the application doesn't page.  The average Pentium PC is grossly
underconfigured with respect to memory.

2. There are well-known techniques for real-time GC that don't have this
problem.  They tend to be a bit more expensive to implement in practice.
Really small pauses with small GC overhead require compiler cooperation.  There
are smart pointer based collectors for C++ that have small pause times, but are
slow in terms of total cpu time.

3. There are incremental collection algorithm that rely on VM support to
usually give reasonable pause times (order of 50 msecs) even with very large
heaps.  Several of these can usually be used with normally compiled C/C++
programs.  See ftp://parcftp.xerox.com/pub/gc/gc.html.  It's usually fairly
easy to try it and see.

4. Network latencies have generally gotten worse, hiding everything else, and
improving people tolerance of pauses.  (I'm only half kidding.)

Hans-J. Boehm
(boehm@parc.xerox.com)
Standard disclaimer ...