How does -XX:NewSize -XX:MaxNewSize effect Garbage Collection?

If you have the following JVM options:
-XX:NewSize=nnn -XX:MaxNewSize=mmm Then you will get Memory (Heap) usage graph as follows:
Without the NewSize options, you will get Memory (Heap) usage graph as follows:
What does this indicate?In the first case short-lived objects are allowed to grow in Eden Space until it gets full, and then Full GC happens.In the Second case minor GC keeps happening frequently, and short-lived objects are GC’ed frequently.
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: