The best GC daemon for Java

Just to clarify a point I seen here indirectly answered:

Is the best GC to use on multi-CPU / multi-Core machine, which mostly runs the application, is ConcurrentMarkSweeper (aka -XX:+UseConcMarkSweepGC)?

Also, there is something called G1, any idea when it will become available for Java6 ?

EDIT: I'm using Sun Java VM, 1.6.0_16-b01. I have real-time (as close to real-time as possible in Java) application, and naturally want GC sweeps to be as short as possible. There is plenty of CPU power (which ConcMarkSweep seems to require).

Thanks.

It depends on what type of tolerance the application has for GC pauses. ConcurrentMarkSweep is best for reducing the size of the GC pauses and therefore latency while the Parellel GC will achieve the best throughput at the expense of longer GC pauses.

G1 is currently an experimental feature. I think it will not be generally available until Java7 is released.

I recommend you take a look at this page: http://java.sun.com/javase/technologies/hotspot/gc/gc_tuning_6.html

It contains a lot of information about the GC algorithms and behaviour. There is a section with advice for selecting the best GC for your application: http://java.sun.com/javase/technologies/hotspot/gc/gc_tuning_6.html#available_collectors.selecting

我来评几句
登录后评论

已发表评论数()

相关站点

+订阅
热门文章