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 83A34BC88 for ; Mon, 7 Feb 2005 20:55:15 +0100 (CET) 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 j17JtFdn000323 for ; Mon, 7 Feb 2005 20:55:15 +0100 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 UAA20897 for ; Mon, 7 Feb 2005 20:55:14 +0100 (MET) Received: from biscayne-one-station.mit.edu (BISCAYNE-ONE-STATION.MIT.EDU [18.7.7.80]) by nez-perce.inria.fr (8.13.0/8.13.0) with ESMTP id j17JtDte000316 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Mon, 7 Feb 2005 20:55:14 +0100 Received: from outgoing.mit.edu (OUTGOING-AUTH.MIT.EDU [18.7.22.103]) by biscayne-one-station.mit.edu (8.12.4/8.9.2) with ESMTP id j17JtBSs014102; Mon, 7 Feb 2005 14:55:12 -0500 (EST) Received: from [18.98.6.119] (WESTGATE-THREE-SEVENTY-FOUR.MIT.EDU [18.98.6.119]) (authenticated bits=0) (User authenticated as farr@ATHENA.MIT.EDU) by outgoing.mit.edu (8.12.4/8.12.4) with ESMTP id j17Jt40Z014858 (version=TLSv1/SSLv3 cipher=RC4-SHA bits=128 verify=NOT); Mon, 7 Feb 2005 14:55:04 -0500 (EST) In-Reply-To: <20050207.203659.94743120.Christophe.Troestler@umh.ac.be> References: <20050207.195724.87945401.Christophe.Troestler@umh.ac.be> <68b7b7bf7d559600cf85b24d60f06cb2@mit.edu> <20050207.203659.94743120.Christophe.Troestler@umh.ac.be> Mime-Version: 1.0 (Apple Message framework v619.2) Content-Type: text/plain; charset=US-ASCII; format=flowed Message-Id: <05666de9ff3face903514bf411230a8e@mit.edu> Content-Transfer-Encoding: 7bit Cc: caml-list@inria.fr From: "Will M. Farr" Subject: Re: [Caml-list] [Benchmark] NBody Date: Mon, 7 Feb 2005 14:55:03 -0500 To: Christophe TROESTLER X-Mailer: Apple Mail (2.619.2) X-Scanned-By: MIMEDefang 2.42 X-Miltered: at nez-perce with ID 4207C7A3.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Miltered: at nez-perce with ID 4207C7A1.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Spam: no; 0.00; caml-list:01 sqrt:01 inlining:01 christophe:01 troestler:01 wrote:01 wrote:01 breakdown:98 34%:98 caml:02 benchmark:02 gprof:03 hooks:03 profiling:05 profiling:05 X-Spam-Checker-Version: SpamAssassin 3.0.2 (2004-11-16) on yquem.inria.fr X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=disabled version=3.0.2 X-Spam-Level: When I ran it on my system using Shark (a Mac OS X profiling application that doesn't require hooks in the app itself to get the information), the breakdown of the significant values was 48.1% in advance 34% in __sqrt (system function) + random stuff I'm not sure, in light of this, why the aggressive inlining makes any difference. Will On 7 Feb 2005, at 2:36 PM, Christophe TROESTLER wrote: > On Mon, 7 Feb 2005, "Will M. Farr" wrote: >> >> You might try profiling (using gprof); maybe it will give you an >> idea where your time is being spent. > > I did that but I could not see anything: the important spot reads: > > ----------------------------------------------- > 8.05 0.00 1000000/1000000 camlNbody__entry [5] > [6] 99.7 8.05 0.00 1000000 camlNbody__code_begin [6] > ----------------------------------------------- > > Did I miss something??? > >> it looks like the java code is faster, but it clearly has a large >> startup time. > > I thought that. Still, I'd like to know whether there is a way to > make Caml code that fast or if not why. > > Thanks for youe reply, > ChriS