From: Guillaume Yziquel <guillaume.yziquel@gmx.ch>
To: Yoonseok Ko <ysko@ropas.snu.ac.kr>
Cc: caml-list@inria.fr
Subject: Re: [Caml-list] A question about GC.
Date: Mon, 13 Jun 2011 11:40:48 +0200 [thread overview]
Message-ID: <20110613094048.GE6158@localhost> (raw)
In-Reply-To: <4DF55B5D.9090302@ropas.snu.ac.kr>
Le Monday 13 Jun 2011 à 09:35:41 (+0900), Yoonseok Ko a écrit :
> Hello everyone.
>
> I have two questions.
>
> 1. Is there any solution? Explicit garbage collection is too slow
> and hard to collect garbage on time.
> I want to know what happened in GC, and why GC won't work.
First you'll have to know what kind of values accumulate in the heap. If
they are custom blocks, then you'll have a pointer in the block pointing
to a structure that identifies the kind of values (as a general rule).
If it's a problem in the binding, then looking closely at custom blocks
is likely a good idea.
Do not know about muddy, but it may be a good idea to tweak parameters
in alloc_custom in order to force garbage collection often. If the
problem goes away, I'd recommend reading closely about alloc_custom,
look at how it is implemented, and modify muddy.c accordingly.
Anyhow, for such GC problems, I'd recommend using ocamlviz.
> 2. Sometimes GC log has this message: "Growing gray_vals to 32768k bytes."
> What does that means?
Good read on the topic:
http://caml.inria.fr/pub/docs/oreilly-book/pdf/chap9.pdf
In the marking phase of Mark & Sweep, gray cells are marked cells whose
descendents are not yet marked.
> Best Regards,
>
> Yoonseok Ko
--
Guillaume Yziquel
next prev parent reply other threads:[~2011-06-13 9:42 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-06-13 0:35 Yoonseok Ko
2011-06-13 9:40 ` Guillaume Yziquel [this message]
2011-06-13 10:37 ` Philippe Wang
2011-06-13 11:34 ` ygrek
2011-06-13 12:19 ` Guillaume Yziquel
2011-06-13 13:26 ` Philippe Wang
2011-06-13 12:21 ` Gerd Stolpmann
2011-06-13 12:26 ` Guillaume Yziquel
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=20110613094048.GE6158@localhost \
--to=guillaume.yziquel@gmx.ch \
--cc=caml-list@inria.fr \
--cc=ysko@ropas.snu.ac.kr \
/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