From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by yquem.inria.fr (Postfix) with ESMTP id 60B99BCA2 for ; Thu, 18 Aug 2005 05:57:15 +0200 (CEST) Received: from pauillac.inria.fr (pauillac.inria.fr [128.93.11.35]) by nez-perce.inria.fr (8.13.0/8.13.0) with ESMTP id j7I3vFA1014187 for ; Thu, 18 Aug 2005 05:57:15 +0200 Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id FAA31856 for ; Thu, 18 Aug 2005 05:57:14 +0200 (MET DST) Received: from wproxy.gmail.com (wproxy.gmail.com [64.233.184.204]) by nez-perce.inria.fr (8.13.0/8.13.0) with ESMTP id j7I3vDNi014182 for ; Thu, 18 Aug 2005 05:57:14 +0200 Received: by wproxy.gmail.com with SMTP id i34so263049wra for ; Wed, 17 Aug 2005 20:57:13 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=WXSqKD8AigX4Yjsgr72H7LbwAjvLP5Skl771miGoanN94TNZZixZfVyb41gzmPEi3iXon/4JCZ1SfH6MKy2uE4NMiZPZWzSKqMsyrfyAN6g3+yGLQ2kzZtFLGsBStX2/5Mc6xWNA569Og2ygHtxTnE0NSeRy0BR9SDIyFk0Kbgc= Received: by 10.54.36.35 with SMTP id j35mr882499wrj; Wed, 17 Aug 2005 20:57:13 -0700 (PDT) Received: by 10.54.22.52 with HTTP; Wed, 17 Aug 2005 20:57:13 -0700 (PDT) Message-ID: Date: Wed, 17 Aug 2005 23:57:13 -0400 From: Markus Mottl To: Nathaniel Gray Subject: Re: [Caml-list] Cost of register_global_root (was: Stopping a value from getting GC'd) Cc: ocaml In-Reply-To: Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: X-Miltered: at nez-perce with ID 4304071B.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Miltered: at nez-perce with ID 43040719.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Spam: no; 0.00; markus:01 mottl:01 markus:01 mottl:01 caml-list:01 gc'd:01 afaik:01 minor:01 ocaml:01 wrote:01 roots:02 root:03 root:03 maybe:07 thousands:91 X-Spam-Checker-Version: SpamAssassin 3.0.3 (2005-04-27) on yquem.inria.fr X-Spam-Level: X-Spam-Status: No, score=0.5 required=5.0 tests=INFO_TLD,RCVD_BY_IP autolearn=disabled version=3.0.3 On 8/17/05, Nathaniel Gray wrote: > One thing that the FM doesn't mention is how expensive it is to > register a global root. Can I register thousands of them or will > there be performance problems? There is a severe performance penalty for registering many thousands of roots as I have seen in one of our applications. AFAIK, they are scanned at each minor collection. This will drive up CPU-usage even if your program doesn't do much otherwise. Maybe the GC could be improved in that area. Regards, Markus --=20 Markus Mottl http://www.ocaml.info markus.mottl@gmail.com