caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: "Neal Wang" <neal.wang@gmail.com>
To: "j h woodyatt" <jhw@conjury.org>
Cc: "The Caml Trade" <caml-list@inria.fr>
Subject: Re: [Caml-list] Can GC be BLOCKed?
Date: Thu, 30 Nov 2006 16:07:51 -0800	[thread overview]
Message-ID: <1965df800611301607g330f5517saeba25d40c3321ca@mail.gmail.com> (raw)
In-Reply-To: <1FB91514-18D1-4502-AF67-C1003EB8636B@mac.com>

Thanks for your help.  But your solution only work for a function
which allocates
  memory of fixed size. Unfortunately, the atomic function, which
cannot be interrupted by GC, read input data from external channels
and the memory needed to store the input data is not determined ahead.
The official interface of GC doesn't not provide a  way to stop GC. Is
there a backdoor such that we can use to stop GC?

   Thanks again
Neal

On 11/29/06, James Woodyatt <jhwoodyatt@mac.com> wrote:
> On Nov 29, 2006, at 4:33 PM, Neal Wang wrote:
> >
> > I have a function which cannot be interrupted by GC?  Is there a
> > way to BLOCK GC when the function is called.  Thanks
>
> We're getting some interesting spam on the OCaml list now.  Just
> after the message above appeared in my inbox, there came the
> following...
>
> On Nov 29, 2006, at 5:22 PM, Rosendo Larson wrote:
> >
> > The lot is cast into the heap, but the whole disposing there of is
> > of the Lord. There never was a great soul that did not have some
> > divine inspiration.
>
> At first, I thought this was intended to be a serious response to the
> question.
>
> I don't think you can stop collection from happening by explicitly
> blocking it in the GC, but if you know how much memory your function
> will allocate, you might be able to get a winning workaround by
> modifying the GC control parameters for space_overhead and
> major_head_increment.  Use the verbose flag to see if your function
> is triggering the collection phase.
>
>
> —
> j h woodyatt <jhw@conjury.org>
> http://jhw.vox.com/
>
> _______________________________________________
> Caml-list mailing list. Subscription management:
> http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list
> Archives: http://caml.inria.fr
> Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
> Bug reports: http://caml.inria.fr/bin/caml-bugs
>


  reply	other threads:[~2006-12-01  0:07 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-11-30  0:33 Neal Wang
2006-11-30  3:07 ` [Caml-list] " James Woodyatt
2006-12-01  0:07   ` Neal Wang [this message]
2006-12-01  0:38     ` Tom
2006-12-01  9:19     ` Richard Jones
2006-12-01 13:39       ` Dmitry Bely
2006-12-01 23:28         ` Philippe Wang
2006-12-02 10:04           ` Dmitry Bely
2006-12-02 12:14             ` Philippe Wang
2006-12-02 11:19         ` Richard Jones
2006-12-01 18:53       ` Neal Wang
2006-12-01 19:13         ` Chris King
2006-12-04  9:37         ` Hendrik Tews

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=1965df800611301607g330f5517saeba25d40c3321ca@mail.gmail.com \
    --to=neal.wang@gmail.com \
    --cc=caml-list@inria.fr \
    --cc=jhw@conjury.org \
    /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).