Thank you for your comments. At least now I have something to work on. (Need to find out why the virtual machine decided to go for premature promotion.)
Command line options are as folows:
-XX:+UseConcMarkSweepGC -XX:+CMSIncrementalMode
-Xloggc:test.gclog -XX:+PrintGCDetails -XX:+PrintGCTimeStamps -XX:+PrintGCApplicationConcurrentTime
-XX:+PrintGCApplicationStoppedTime -XX:+PrintTenuringDistribution
Java Version 1.6.0-14
Java HotSpot build 14.0-b16
A folow-up question I am trying to understand is the opposite of the last question.
In the following garbage collection output (no 2.), even though new threshold is 2,
age=3 generation garbage is collected, and in no. 3, a 2nd generation garbage is collected even though new threshold is 1.
From where do these extra generation guys come?
My guess is that since max threshold is 4 (in all cases), JVM dynamically decided to go for an extra run. Does anyone have any other (correct) idea?