Request for review 8025635: SoftReferences are not cleared before metaspace OOME are thrown
Jon Masamitsu
jon.masamitsu at oracle.com
Fri Oct 4 14:41:14 UTC 2013
On 10/3/2013 10:27 PM, Stefan Karlsson wrote:
> On 10/4/13 12:44 AM, Jon Masamitsu wrote:
>> 8025635: SoftReferences are not cleared before metaspace OOME are thrown
>>
>> If native memory has been exhausted or MaxMetaspaceSize has been set and
>> has been reached, a GC will be done to try and unload classes and
>> free metadata
>> space. If not enough metadata space has been freed, another GC which
>> clears
>> SoftReferences will be done.
>>
>> Note that GC's are normally done to unload classes and free metadata
>> space.
>> If not enough metadata space is freed by the GC, additional
>> space is allocated and used for the metadata allocation. It is only in
>> the situation where no additional native memory can be allocated for
>> metadata that SoftReferences are cleared.
>>
>> http://cr.openjdk.java.net/~jmasa/8025635/webrev.00/
>
> Will this change work with CMS?
You're right. It doesn't work for CMS. Let me work on it.
Thanks.
Jon
>
> thanks,
> StefanK
>
More information about the hotspot-gc-dev
mailing list