Linus with some good observations on garbage collection

"Jérôme M. Berger" jeberger at free.fr
Sat Apr 23 00:27:30 PDT 2011


Michael Stover wrote:
> This sort of reference count with cyclic dependency detector is how a
> lot of scripting languages do it, or did it in the past.  The problem
> was that lazy generational GCs are believed to have better throughput in
> general.
>
> I'd like to say "were proved" rather than "are believed", but I don't
> actually know where to go for such evidence.  However, I do believe many
> scripting languages, such as python, eventually ditched the reference
> counting technique for generational, and Java has very fast GC, so I am
> inclined to believe those real-life solutions than Linus.
>
        This is a single benchmark on a single obscure language, so
take it with a grain of salt, but look at the "Nimrod" and "Nimrod
Boehm" lines here: https://bitbucket.org/jmb/shootout/wiki/Home

        By default, Nimrod uses a reference counter but there is a
compiler switch to use the Boehm GC instead. Of particular interest
is the benchmark "Binary trees", since it is specially designed to
exercise memory management. On that benchmark, the Boehm version is
about twice as fast as the refcounting version, while on other
benchmarks, performance is comparable.

		Jerome
-- 
mailto:jeberger at free.fr
http://jeberger.free.fr
Jabber: jeberger at jabber.fr



-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: OpenPGP digital signature
URL: <http://lists.puremagic.com/pipermail/digitalmars-d/attachments/20110423/eb542ecf/attachment.pgp>


More information about the Digitalmars-d mailing list