JEP 141: Increase the Client VM's Default Heap Size
Michael Bien
mbien at fh-landshut.de
Wed Feb 22 20:44:56 UTC 2012
On 02/22/2012 04:38 PM, Jon Masamitsu wrote:
>
>
> On 2/22/2012 4:28 AM, Michael Bien wrote:
>> On 02/22/2012 12:48 AM, mark.reinhold at oracle.com wrote:
>>> Posted: http://openjdk.java.net/jeps/141
>>>
>>> - Mark
>>>
>> additional risks:
>> - JVM may not be able to start
>
> Specifically, the JVM tries to reserve enough memory at start up
> for the heap and fails to initialize if it cannot?
>
> Will add it.
>
>> - could contribute to the false impression that java requires a lot
>> of memory to run (JVMs usually don't like to give memory back to the
>> OS once its in use)
>
> Is this an impression the user would get because the JVM would not
> start up as you
> note above? The JVM does not necessarily use all the memory it
> reserves.
yep. However most GCs are quite lazy (by design) to reach good
throughput. My experience so far showed that GCs have the tendency to
expand the heap at a full GC if there is still room left. Shrinking
heaps happened to me only in constructed tests - never in real
applications (esp. not with default config ;)).
i am somehow not very comfortable with the fact that hello world or an
applet would request 1g from the OS. Are there usecases for applications
out there where the developer or admin doesn't know how much memory is
needed? If there are, than a default value would not help those much
anyway (-> expanding heap needed until system limit is reached). All
others set -Xmx :)
just wanted to bring this up, you guys are the experts.
regards,
michael
>
>
> Thanks.
>
> Jon
>>
>> best regards,
>> michael
>>
>
>
--
http://michael-bien.com/
More information about the hotspot-gc-dev
mailing list