Skip to main content

How can CMS be so slow

1 reply [Last post]
hansp
Offline
Joined: 2009-09-30
Points: 0

Hi,

Below is the ParNew phase only 0.015 secs.
The CMS phase takes 2.2 secs.

Has someone an idea?
Tenured space does not seem to be full.

149105.462: [Full GC {Heap before GC invocations=894:
Heap
par new generation total 786432K, used 9407K [0xfffffffed0000000, 0xffffffff10000000, 0xffffffff10000000)
eden space 524288K, 1% used [0xfffffffed0000000, 0xfffffffed092fff0, 0xfffffffef0000000)
from space 262144K, 0% used [0xfffffffef0000000, 0xfffffffef0000000, 0xffffffff00000000)
to space 262144K, 0% used [0xffffffff00000000, 0xffffffff00000000, 0xffffffff10000000)
concurrent mark-sweep generation total 1048576K, used 145533K [0xffffffff10000000, 0xffffffff50000000, 0xffffffff50000000)

concurrent-mark-sweep perm gen total 52544K, used 31525K [0xffffffff50000000, 0xffffffff53350000, 0xffffffff70000000)
149105.463: [ParNew: 9407K->217K(786432K), 0.0155178 secs]149105.478: [CMS: 145533K->145042K(1048576K), 2.2154136 secs] 154941K->145042K(1835008K), [CMS Perm : 31525K->31523K(52544K)] Heap after GC invocations=895:

Heap
par new generation total 786432K, used 0K [0xfffffffed0000000, 0xffffffff10000000, 0xffffffff10000000)
eden space 524288K, 0% used [0xfffffffed0000000, 0xfffffffed0000000, 0xfffffffef0000000)
from space 262144K, 0% used [0xffffffff00000000, 0xffffffff00000000, 0xffffffff10000000)
to space 262144K, 0% used [0xfffffffef0000000, 0xfffffffef0000000, 0xffffffff00000000)
concurrent mark-sweep generation total 1048576K, used 145042K [0xffffffff10000000, 0xffffffff50000000, 0xffffffff50000000)

concurrent-mark-sweep perm gen total 52544K, used 31523K [0xffffffff50000000, 0xffffffff53350000, 0xffffffff70000000)
} , 2.2318615 secs]

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
uvoigt
Offline
Joined: 2006-01-26
Points: 0

Hi,

the concurrent phase of the CMS took 2.2 sec. Your application should not be stopped within this time. Use the parameter -XX:+PrintGCApplicationStoppedTime to printout the real application stop times.

Sometimes I got VERY long GC times when my application was running on linux and did have lots of memory. Some longtime unused parts seemed to be swapped out and when the GC started a full GC it took a long time to reswap it.