0

Intellij Idea JVM options benchmark: defalut settings are worst

Hi, All.

I benchmarked VM options for Idea. Let me share my results.


Test: Startup + open big project > 100k classes

Environment: WinXp, jre 1.6.26, Xeon 2Gh

Tested VM options:

  1. Default (-Xms128m -Xmx512m)
  2. Default "enhanced" -Xms768m -Xmx768m
  3. UseParallelOldGC
  4. UseParNewGC
  5. UseConcMarkSweepGC UseParNewGC
  6. UseConcMarkSweepGC UseParNewGC NewSize=128m



All Parallel GCs share common part -Xms768m -Xmx768m -server -XX:ParallelGCThreads=8 (8 because of cpu cores)

      

Results:

Time to start + open project:

1)       Default => 36 secs

2)       Default+Xms768m => 37 seconds

3)       Any parallel config ~24 seconds


GC charts (less is better for all):
overhead.png
Max.png
Min.png
Note: ParNewGc and default show good min results because of low newSize on startup~40m, which is grows with time, so shouldn't be considered valid.

stats.PNG
Numbers are better than comments:
stats-compare.PNG

Conclusion and advices:

1) shipped settings are worst of all and should be refused for multicore processors.

2) Setting just large Xmx brings even larger pauses to application with small overhead win and impacts responsivness.

3) roughly, the best suited GC is CMS. Taking into account it could shorten major GC pauses, i suggest to use these settings (ParallelGCThreads depends on CPU):

-Xms768m

-Xmx768m

-XX:MaxPermSize=250m

-XX:ReservedCodeCacheSize=64m

-server

-XX:NewSize=128m

-XX:+UseParNewGC

-XX:ParallelGCThreads=8

-XX:+UseConcMarkSweepGC

-XX:CMSInitiatingOccupancyFraction=60

Any questions and suggestions ae very welcome. GC logs could be found in attachement.

regards, Alex



Attachment(s):
idea-gc-test.zip

6 comments

Please sign in to leave a comment.