At 05:29 PM 2/9/2001 -0200, Branden wrote:
>Ken Fox wrote:
> > 2. Work proportional to live data, not total data. This is hard to
> > believe for a C programmer, but good garbage collectors don't have
> > to "free" every allocation -- they just have to preserve the live,
> > or reachable, data. Some researchers have estimated that 90% or
> > more of all allocated data dies (becomes unreachable) before the
> > next collection. A ref count system has to work on every object,
> > but smarter collectors only work on 10% of the objects.
>
>Does this 90/10 ratio mean that the memory usage is actually 10 times it
>needs to be? (if it were even _possible_ to pack all the data without
>fragmentation problems)
No. It means that 90% of the memory allocated between runs of the GC gets
freed. The memory isn't wasted, by any means.
Most memory is allocated for ephemeral things--objects that come and go,
temporary buffers, scratch space, and suchlike things. It's normal.
Dan
--------------------------------------"it's like this"-------------------
Dan Sugalski even samurai
[EMAIL PROTECTED] have teddy bears and even
teddy bears get drunk