caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Christophe Raffalli <christophe.raffalli@univ-savoie.fr>
To: Damien Doligez <damien.doligez@inria.fr>
Cc: caml-list <caml-list@inria.fr>
Subject: Re: [Caml-list] GC and caml_oldify_local_roots taking too much time
Date: Mon, 19 Jul 2004 15:33:07 -0400	[thread overview]
Message-ID: <40FC21F3.3040108@univ-savoie.fr> (raw)
In-Reply-To: <3B84CC2A-D97E-11D8-A7B0-00039310CAE8@inria.fr>

Damien Doligez wrote:
> On Jul 19, 2004, at 19:59, Christophe Raffalli wrote:
> 
>> What could cause the increase of time spent in caml_oldify_local_roots ?
>> And what is this function in the first place ?
> 
> 
> It is the function that finds the roots of the memory graph:
> 
> 1. in the stack
> 2. in the global C roots
> 3. among finalised values
> 4. in the stacks of other threads, if any
> 
> I guess your program does one or more of the following:
> 
> 1. allocate lots of stack space (deep recursion)

That's not the case, I am in a while loop so recursion depth is bounded

> 2. declare lots of C roots (with caml_register_global_root)

That may be a bug in the lablGL code ... I had a short look but found 
nothing.

> 3. launch lots of threads that allocate big stacks

I launch only two threads (native posix threads)


> I don't think finalised values can be the problem, because this
> particular set of roots is emptied after each minor collection.

I removed call to finalise and saw no change. Anyway I have always less 
than 10 not collected object with finaliser.

> It should be possible to do something better for case (2), but
> if you declare arbitrary amounts of C roots, you will still pay
> the price at each major collection (instead of each minor
> collection as it is now).

I will look better at lablGL/Glut code now.

Thanks


> -- Damien
> 
> -------------------
> To unsubscribe, mail caml-list-request@inria.fr Archives: 
> http://caml.inria.fr
> Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: 
> http://caml.inria.fr/FAQ/
> Beginner's list: http://groups.yahoo.com/group/ocaml_beginners

-- 
Christophe Raffalli
Université de Savoie
Batiment Le Chablais, bureau 21
73376 Le Bourget-du-Lac Cedex

tél: (33) 4 79 75 81 03
fax: (33) 4 79 75 87 42
mail: Christophe.Raffalli@univ-savoie.fr
www: http://www.lama.univ-savoie.fr/~RAFFALLI
---------------------------------------------
IMPORTANT: this mail is signed using PGP/MIME
At least Enigmail/Mozilla, mutt or evolution
can check this signature
---------------------------------------------

-------------------
To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners


  reply	other threads:[~2004-07-19 13:32 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-07-19 17:59 Christophe Raffalli
2004-07-19 12:21 ` Damien Doligez
2004-07-19 19:33   ` Christophe Raffalli [this message]
2004-07-19 20:17   ` Christophe Raffalli
2004-07-19 14:28     ` Richard Jones
2004-07-19 14:38       ` Richard Jones
2004-07-19 15:12     ` Olivier Andrieu
2004-07-19 20:36   ` Christophe Raffalli
2004-07-20 20:00   ` [Caml-list] Calback (was caml_oldify_local_roots taking too much time) Christophe Raffalli
2004-07-20 14:40     ` [Caml-list] Calback Olivier Andrieu
     [not found]       ` <40FD9FDE.3070000@univ-savoie.fr>
2004-07-20 22:44         ` Christophe Raffalli
2004-07-21  0:54           ` Jere Sanisalo
2004-07-20 23:09       ` Christophe Raffalli

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=40FC21F3.3040108@univ-savoie.fr \
    --to=christophe.raffalli@univ-savoie.fr \
    --cc=caml-list@inria.fr \
    --cc=damien.doligez@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).