caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Damien Doligez <damien.doligez@inria.fr>
To: OCaml List <caml-list@yquem.inria.fr>
Subject: Re: [Caml-list] Gc.compact surprisingly helpful
Date: Sat, 5 Dec 2009 18:06:48 +0100	[thread overview]
Message-ID: <95594484-7A9F-4ECA-B7A8-079D433BF4FB@inria.fr> (raw)
In-Reply-To: <c413fcb70912041109n287c3244q7d51cc08a5af036d@mail.gmail.com>


On 2009-12-04, at 20:09, Aaron Bohannon wrote:

> So in a 15 second run (with no
> idle time, as I said), it now does about 130 heap compactions instead
> of 3 and gets better total performance because of it, utterly defying
> my GC intuition.


What is the size of your heap?  Have you tried compacting only once
every 2, 3, 5, or 10 loops?

One possible explanation is that compaction will also compact the
free list into a few large blocks, which makes allocation faster.

-- Damien


  parent reply	other threads:[~2009-12-05 17:06 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-12-04 19:09 Aaron Bohannon
2009-12-04 19:31 ` [Caml-list] " Florian Hars
2009-12-05 17:06 ` Damien Doligez [this message]
2009-12-08  3:30   ` Aaron Bohannon
2009-12-05 17:35 ` Xavier Leroy

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=95594484-7A9F-4ECA-B7A8-079D433BF4FB@inria.fr \
    --to=damien.doligez@inria.fr \
    --cc=caml-list@yquem.inria.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).