From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail2-relais-roc.national.inria.fr (mail2-relais-roc.national.inria.fr [192.134.164.83]) by yquem.inria.fr (Postfix) with ESMTP id 80C42BC57 for ; Tue, 2 Mar 2010 21:11:17 +0100 (CET) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AvICABoAjUvRVdvWimdsb2JhbACRFYIQh1UIFQEBAQoJDAcRBR+vW4FehSItiEoBAQMFhHYEgxc X-IronPort-AV: E=Sophos;i="4.49,568,1262559600"; d="scan'208";a="45791342" Received: from mail-ew0-f214.google.com ([209.85.219.214]) by mail2-smtp-roc.national.inria.fr with ESMTP; 02 Mar 2010 21:11:17 +0100 Received: by ewy6 with SMTP id 6so534199ewy.17 for ; Tue, 02 Mar 2010 12:11:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:cc:message-id:from:to :in-reply-to:content-type:content-transfer-encoding:mime-version :subject:date:references:x-mailer; bh=YsjmL9wyJ1u7FmimkOFdduN3kpmlsVLzy2RLQgVRWu8=; b=f8P6bbaHIjzrxlFc9Zwv7m2W/7BgM0gfzSNaoFp8Uy3U0Hyz/cYbfgH735BA8WQymi rjRkSCCf04EBrf2Mvk4ihMAmnpMSsqH/iApBtKcTzKFznKdrAmkeOsPU7uqgqKEFAPd7 8HdfioGgpgdoLSeRvvI12mJrhpiCjTHGW+pyI= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=cc:message-id:from:to:in-reply-to:content-type :content-transfer-encoding:mime-version:subject:date:references :x-mailer; b=WbTz1QCHDEXEBHoO7a4T53e5FCULaHrzjmJWrAzQLbc5Ub9KEwW5X6a3pNS5ocvjmx xbkcnOwqCIbVb0V/uBVty5Sorb4VyWJNJhj2Syf6ZA5VtQ8KTPHCBTPITHdUhwa49til MWoxDJSpSzeiPj+5vD9e4+Ni8sl2PMt5qQ3dg= Received: by 10.103.79.35 with SMTP id g35mr5310766mul.82.1267560676417; Tue, 02 Mar 2010 12:11:16 -0800 (PST) Received: from ?192.168.0.34? (c-24-5-88-93.hsd1.ca.comcast.net [24.5.88.93]) by mx.google.com with ESMTPS id y2sm25750046mug.21.2010.03.02.12.11.14 (version=TLSv1/SSLv3 cipher=RC4-MD5); Tue, 02 Mar 2010 12:11:15 -0800 (PST) Cc: OCaml Message-Id: <5043CED0-7CEC-4813-8325-76C3196E8FEE@gmail.com> From: Warren Harris To: Richard Jones In-Reply-To: <20100301085430.GA16106@annexia.org> Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit Mime-Version: 1.0 (Apple Message framework v936) Subject: Re: [Caml-list] gc overhead Date: Tue, 2 Mar 2010 12:11:11 -0800 References: <37150F07-8902-464A-9A0E-44A0C424C87B@gmail.com> <20100301085430.GA16106@annexia.org> X-Mailer: Apple Mail (2.936) X-Spam: no; 0.00; userspace:01 userspace:01 ocaml:01 wiki:01 ocaml:01 warren:98 28,:98 warren:98 garbage:01 wrote:01 wrote:01 caml-list:01 short:01 kernel:02 gprof:03 On Mar 1, 2010, at 12:54 AM, Richard Jones wrote: > On Sun, Feb 28, 2010 at 04:16:03PM -0800, Warren Harris wrote: >> I would like to determine what percentage of my application's cpu >> time >> is spent in the garbage collector (for tuning purposes, but also just >> to monitor the overhead). Is there any way to obtain this information >> short of using gprof? Additional information provided by Gc.stat >> would >> be ideal, or perhaps a Gc.alarm that was called at the beginning of >> the gc cycle, but neither of these seem to exist. > > I would have to say what's wrong with using gprof? What's wrong with it is that it provides no way to monitor gc overhead in an active service. > > On a related topic: Has anyone tried using SystemTap with userspace > DTrace-compatible probes to measure anything about total kernel + > userspace usage of OCaml programs? ie, this sort of thing: > > http://sourceware.org/systemtap/wiki/AddingUserSpaceProbingToApps > > but with OCaml programs. > > Rich. > > -- > Richard Jones > Red Hat