Return-Path: Delivered-To: apmail-harmony-dev-archive@www.apache.org Received: (qmail 47367 invoked from network); 23 Oct 2008 06:55:39 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 23 Oct 2008 06:55:39 -0000 Received: (qmail 16791 invoked by uid 500); 23 Oct 2008 06:55:39 -0000 Delivered-To: apmail-harmony-dev-archive@harmony.apache.org Received: (qmail 16772 invoked by uid 500); 23 Oct 2008 06:55:39 -0000 Mailing-List: contact dev-help@harmony.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@harmony.apache.org Delivered-To: mailing list dev@harmony.apache.org Received: (qmail 16761 invoked by uid 99); 23 Oct 2008 06:55:39 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 22 Oct 2008 23:55:39 -0700 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of alexei.fedotov@gmail.com designates 64.233.170.190 as permitted sender) Received: from [64.233.170.190] (HELO rn-out-0910.google.com) (64.233.170.190) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 23 Oct 2008 06:54:26 +0000 Received: by rn-out-0910.google.com with SMTP id k57so75388rnd.13 for ; Wed, 22 Oct 2008 23:54:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:in-reply-to:mime-version:content-type :content-transfer-encoding:content-disposition:references; bh=foEOf0MLIYgUkZTzJFSFVw/mPejH5a3Zp8k0thevN0g=; b=kiMFAdVNq/1tN1z4N9ZaP9GO1EDfKiwyBPOzUZUstAKTYCS2jdWMk5uqFTnoxqJMpr PfERaRXwRoSMTEBWRMCyYzV/ywqiBnuRH7cdjw1ISg5Q3PgmeUaNx/VWAS53tHNO/3xz e07TcuP4CKFjyRHSRS0XQ41iKDq909C3k1aBs= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:in-reply-to:mime-version :content-type:content-transfer-encoding:content-disposition :references; b=ECZQGTAxImB475Ljr1yngKp66ijTJ0/rUurvtPKAkwqjQ07Ty3VHCPy1hgvKsDrEOv K5KoRinVh56a/T5vVNIURA5QMAOW/4RD4FwkylwbTLwUq8k9PjActmQztYVcX/8vMdGb 6qvHuczY6ExXPpzzlhc6pm4dZV9v9Fi8stjNk= Received: by 10.150.228.19 with SMTP id a19mr3201524ybh.246.1224744894785; Wed, 22 Oct 2008 23:54:54 -0700 (PDT) Received: by 10.150.54.20 with HTTP; Wed, 22 Oct 2008 23:54:54 -0700 (PDT) Message-ID: Date: Thu, 23 Oct 2008 10:54:54 +0400 From: "Alexei Fedotov" To: dev@harmony.apache.org Subject: Re: [performance] Startup cost is high for Harmony (HARMONY-6002) In-Reply-To: <9623c9a50810222321s5ea62c36iad36c3e1c0ff8ef8@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <1001978583.1224684584498.JavaMail.jira@brutus> <48FF8D0F.7010206@gmail.com> <9623c9a50810222321s5ea62c36iad36c3e1c0ff8ef8@mail.gmail.com> X-Virus-Checked: Checked by ClamAV on apache.org Xiao Feng, Thanks for a good question. The optimization improves so-called "peak score" which is calculated from several subsequent executions. If you cache VM state in different files for different command lines, you may even cache pre-compiled class files for a particular benchmark. As I've got from a fellow SPEC committee member this optimization is allowed unless the released VM is specifically tuned to pass the spec. Sorry about the third bullet. Well, I thought if I should mention pre-compiled classes there. I hesitate because I don't know any trusted research which shows that loading pre-compiled classes from disk is quicker than dynamic re-compilation. Thanks! On Thu, Oct 23, 2008 at 10:21 AM, Xiao-Feng Li wrote: > On Thu, Oct 23, 2008 at 1:44 PM, Alexei Fedotov > wrote: >> Hello Wenlong, >> You have addressed a very interesting topic. Let me share few ideas >> how to approach it: >> >> 1. The first thing I would expect to understand here is why we should >> care about "Hello, World" startup. SPEC jvm [0] startup scores are >> much more tempting to approach. Then one should compare the score with >> one of our competitors. Taking into account that 300 ms = 300 context >> switches I would not say that the number itself makes me unhappy about >> Harmony speed. >> >> 2. Due to some bureaucracy the following tempting [1] idea is still >> waiting for an experienced and accurate C coder to complete: >> * load classes into bootstrap class loader once >> * store the internal representation of classes as a memory mapped file; >> * next time, load the file if it exists. > > Fedotov, thanks. I guess this idea can only improve the second-time > startup time? Is this be useful for SPECJVM startup score? Thanks. > > Btw, your email lost bullet 3. :) > > Thanks, > xiaofeng > >> 4. If you don't like C, there are tunable things in a class library >> you may find using Gregory's JVMTI profiler [2]. >> >> [0] http://www.spec.org/jvm2008/ >> [1] a research shows +10% on "Hello, World" >> [2] two first attachments at https://issues.apache.org/jira/browse/HARMONY-4569 >> >> On Thu, Oct 23, 2008 at 12:29 AM, Tim Ellison wrote: >>> >>> Wenlong Li (JIRA) wrote: >>> > The startup time is long for the simple helloworld program. On a Core >>> > 2 Quad-core processor, running the simple helloworld program will take >>> > more than 300 ms. >>> > Can we reduce the startup cost? >>> >>> Yes, I hope so ... concrete suggestions or analysis of startup costs are >>> welcome. >>> >>> Regards, >>> Tim >> >> >> >> -- >> With best regards, >> Alexei >> > > > > -- > http://xiao-feng.blogspot.com > -- With best regards, Alexei