Forum: JRuby performance of jruby vs jruby-complete.jar

Posted by kristian (Guest)
on 2010-08-17 17:07
(Received via mailing list)
hi,

is there a particular reason why the performance of jruby-complete.jar
is so bad. is more the then factor 2 between them. see
http://gist.github.com/530288
which is against a freshly created rails3 application and they both
use exactly the same environment, OS, java, gems, etc.

how I improve the situation with jruby-complete ?

regards Kristian

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email
Posted by Daniel Lucraft (Guest)
on 2010-08-17 17:14
(Received via mailing list)
On 17 Aug 2010, at 16:07, kristian wrote:
> is there a particular reason why the performance of jruby-complete.jar
> is so bad. is more the then factor 2 between them. see
> http://gist.github.com/530288
> which is against a freshly created rails3 application and they both
> use exactly the same environment, OS, java, gems, etc.
> 
> how I improve the situation with jruby-complete ?

Good question. I get similar results: http://gist.github.com/530333

I'd love to know what's going on here.

Dan

_______________________________
Daniel Lucraft

twitter.com/danlucraft
danlucraft.com/blog






---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email
Posted by Hirotsugu Asari (Guest)
on 2010-08-17 17:30
(Received via mailing list)
On Aug 17, 2010, at 11:13 AM, Daniel Lucraft wrote:

> 
> I'd love to know what's going on here.
> 
> Dan
> 
> _______________________________
> Daniel Lucraft
> 
> twitter.com/danlucraft
> danlucraft.com/blog

They are not equivalent commands. I suspect that JVM needs to look for 
each class found in jruby.jar in order to choose the correct class to 
run main() from.

To wit, giving the bootclasspath makes a big difference. 
http://gist.github.com/530410
---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email
Posted by Nick Sieger (Guest)
on 2010-08-17 17:34
(Received via mailing list)
On Tue, Aug 17, 2010 at 10:29 AM, Hirotsugu Asari <asari.ruby@gmail.com> 
wrote:
>>> how I improve the situation with jruby-complete ?
>> twitter.com/danlucraft
>> danlucraft.com/blog
>
> They are not equivalent commands. I suspect that JVM needs to look for each class found in jruby.jar in order to choose the correct class to run main() from.
>
> To wit, giving the bootclasspath makes a big difference. http://gist.github.com/530410

Yeah, I suspect we're running into slowness due to class verification
here -- JRuby has to load a lot of classes :). Putting the jar on the
bootclasspath avoids verification. You can also try passing
-Xverify:none on the command-line (but this avoids verifying any
classes at all, so be careful with untrusted classes).

/Nick

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email
Posted by kristian (Guest)
on 2010-08-17 17:41
(Received via mailing list)
hmm, with my more complex example there is a slight improvement with
appending the bootclasspath but the factor 2 remains:

http://gist.github.com/530288

so there is more going on here.

Kristian

On Tue, Aug 17, 2010 at 9:04 PM, Nick Sieger <nicksieger@gmail.com> 
wrote:
>>>>
>>>
> -Xverify:none on the command-line (but this avoids verifying any
>
---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email
Posted by Hirotsugu Asari (Guest)
on 2010-08-17 17:49
(Received via mailing list)
On Aug 17, 2010, at 11:40 AM, kristian wrote:

> hmm, with my more complex example there is a slight improvement with
> appending the bootclasspath but the factor 2 remains:
> 
> http://gist.github.com/530288
> 
> so there is more going on here.
> 
> Kristian

There are other options given to JVM, of course. Take a look at the 
second snippet I just added in http://gist.github.com/530410 (with 
native launcher; shell script version may be slightly different)


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email
Posted by kristian (Guest)
on 2010-08-19 17:37
(Received via mailing list)
thanx a lot - I going to use this little result in my jruby launcher:
http://gist.github.com/538166
and jruby-complete can be even faster then the jruby installation !

and found out how to improve start up of maven as well ;-)

regards Kristian

On Tue, Aug 17, 2010 at 9:19 PM, Hirotsugu Asari <asari.ruby@gmail.com> 
wrote:
>> Kristian
>
---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email
Please log in before posting. Registration is free and takes only a minute.
Existing account (Switch to SSL-encrypted connection)
NEW: Do you have a Google/GoogleMail or Yahoo account? No registration required!
Log in with Google account | Log in with Yahoo account
No account? Register here.