Lock contention in Ruby.allocModuleId(RubyModule)
-------------------------------------------------

                 Key: JRUBY-4773
                 URL: http://jira.codehaus.org/browse/JRUBY-4773
             Project: JRuby
          Issue Type: Bug
    Affects Versions: JRuby 1.5
         Environment: JRuby 1.5.0.RC3, JRuby-Rack 0.9.6, Rails 2.3.4.
Java version "1.6.0_17", Java(TM) SE Runtime Environment (build 1.6.0_17-b04), 
Java HotSpot(TM) Server VM (build 14.3-b01, mixed mode) 
Centos 5.4 (Linux 2.6.18-164.el5 #1 SMP Thu Sep 3 03:33:56 EDT 2009 i686 i686 
i386 GNU/Linux)

            Reporter: Yogi
            Assignee: Thomas E Enebo


Hi,

I'm seeing a severe drop in performance in 1.5.0.RC3 compared to 1.3.1 and 
1.4.1. 

Load testing our webapp with Httperf shows that 1.3.1 and 1.4.1 can sustain a 
reply-rate of around 83 replies/sec with 100 requests being generated per 
second. 

With 1.5.0.RC3, this drops to 32 replies/sec, with 50 requests/second (it could 
not sustain the load of 100 requests/sec). The only thing that was varied 
across these runs was the JRuby version.

The profiler shows that the bottleneck is due to severe lock contention on a 
WeakHashSet instance in Ruby.allocModuleId(RubyModule), when called from 
RubyClass.<init> and RubyModule.<init> (both being roughly equal contributors 
to the slowdown). 

The method was introduced in this commit last month: 
http://github.com/jruby/jruby/commit/9414a764ecf84b9c0f2871dabaf51b2036fc1b47.

-Yogi


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

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

    http://xircles.codehaus.org/manage_email


Reply via email to