Newsgroups: comp.lang.lisp
Path: cantaloupe.srv.cs.cmu.edu!rochester!udel!news.mathworks.com!newsfeed.internetmci.com!EU.net!peer-news.britain.eu.net!newsfeed.ed.ac.uk!edcogsci!jeff
From: jeff@cogsci.ed.ac.uk (Jeff Dalton)
Subject: Re: Why garbage collection?
Message-ID: <DL8AKK.9vF.0.macbeth@cogsci.ed.ac.uk>
Organization: Centre for Cognitive Science, Edinburgh, UK
References: <rvillDL7MKJ.58H@netcom.com>
Date: Mon, 15 Jan 1996 15:19:32 GMT
Lines: 51

In article <rvillDL7MKJ.58H@netcom.com> rvill@netcom.com (Richard Villanueva) writes:
>Erik Naggum (erik@naggum.no) wrote:
>
>: so your AI research supporter (?) was not ill-informed, but what he told
>: you was not what you thought you heard.  garbage collection hindered the
>: acceptance, but garbage collection was not at fault, the _perception_ of
>: garbage collection was the actual cause.
>
>Actually, my friend is a system and network administrator.  I recently got
>the free version of Allegro Common Lisp for Windows, and unless I am
>horribly mistaken, I saw it pause for a painful length of time to do garbage
>collection.

How long was the painful length of time?  How do you even know
it was for garbage collection (rather than, say, for paging)?
If it's because the system printed a message to say it was
garbage collecting, would you have noticed if the message had
not been printed?  (Try turning the message off.)

How often does this occur?

How much of the total time was spent in these painful pauses?

I haven't used Allegro Common Lisp for Windows, so I don't know what
its properties are.  But I regularly compile moderately large systems
in Lisp without being bothered by gc pauses.  I find GC a problem only
when I'm pushing near the limits of what the machine can handle in any
case.

It's true that some programs will spend lots of time garbage
collecting, just as some will spend lots of time paging.


>If true, this either means that they are not using superior
>algorithms that are well known, or garbage collection is an obstacle after
>all. 

An obstacle to what?

>My comment about reference counts was not meant to say "listen to my
>new idea", but only to say "even this old idea would be better than having
>to endure such long pauses, so what's the deal?"

How do you know reference counting gives you better performance?

Perhaps you think it's obvious, because reference counting distributes
the collection costs throughout the computation, rather than doing it
all at once in a pause.  But many GC algorithms also distribute
the work.

-- jd
