From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 11625 invoked by alias); 4 Dec 2007 18:06:13 -0000 Received: (qmail 11614 invoked by uid 22791); 4 Dec 2007 18:06:13 -0000 X-Spam-Check-By: sourceware.org Received: from smtp1.dnsmadeeasy.com (HELO smtp1.dnsmadeeasy.com) (205.234.170.144) by sourceware.org (qpsmtpd/0.31) with ESMTP; Tue, 04 Dec 2007 18:05:54 +0000 Received: from smtp1.dnsmadeeasy.com (localhost [127.0.0.1]) by smtp1.dnsmadeeasy.com (Postfix) with ESMTP id 7B7A8310CF4; Tue, 4 Dec 2007 18:06:04 +0000 (UTC) X-Authenticated-Name: js.dnsmadeeasy X-Transit-System: In case of SPAM please contact abuse@dnsmadeeasy.com Received: from avtrex.com (unknown [67.116.42.147]) by smtp1.dnsmadeeasy.com (Postfix) with ESMTP; Tue, 4 Dec 2007 18:06:04 +0000 (UTC) Received: from [192.168.7.26] ([192.168.7.26]) by avtrex.com with Microsoft SMTPSVC(6.0.3790.1830); Tue, 4 Dec 2007 10:05:50 -0800 Message-ID: <475596FE.4060705@avtrex.com> Date: Tue, 04 Dec 2007 18:06:00 -0000 From: David Daney User-Agent: Thunderbird 1.5.0.12 (X11/20071019) MIME-Version: 1.0 To: Joe Hoffert Cc: Andrew Haley , gcc-help@gcc.gnu.org Subject: Re: GCJ .jar to .so with native method References: <1196774413.3986.18.camel@sirion.dre.vanderbilt.edu> <18261.21978.841368.32225@zebedee.pink> <1196777200.3362.11.camel@sirion.dre.vanderbilt.edu> <18261.28465.895232.916931@zebedee.pink> <1196782972.3362.22.camel@sirion.dre.vanderbilt.edu> <18261.31076.962649.532047@zebedee.pink> <1196786104.3362.47.camel@sirion.dre.vanderbilt.edu> <18261.33673.40725.493124@zebedee.pink> <1196790426.3362.60.camel@sirion.dre.vanderbilt.edu> In-Reply-To: <1196790426.3362.60.camel@sirion.dre.vanderbilt.edu> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org X-SW-Source: 2007-12/txt/msg00091.txt.bz2 Joe Hoffert wrote: > One more question. Is there any advantage to converting a .jar library > to a .so library and using it as opposed to simply using the > original .jar file with the Java invocation API and the JNI to call back > to C++ from Java? I thought I would get a performance increase with > using the .so library but perhaps there are no substantive differences > between the two approaches. > It depends on how much work the code in the .jar is doing. Compiling to a .so will generally produce faster code, but the memory overhead of a .so may make using the interpreter on the .jar a better option. If you really care, you could try both ways. David Daney