RFR: 8278125: Some preallocated OOMEs are missing stack trace [v3]

Coleen Phillimore coleenp at openjdk.java.net
Mon Dec 20 23:42:17 UTC 2021


On Mon, 20 Dec 2021 23:14:05 GMT, Coleen Phillimore <coleenp at openjdk.org> wrote:

>> OopHandle Universe::_metaspace_string;
>> ...
>> msg = String::intern("Metaspace", CHECK);
>> java_lang_Throwable::set_message(oom_array->obj_at(_oom_metaspace, msg());
>> Universe::_metaspace_string = OopHandle(vm_global(), msg);
>> ...
>> bool Universe::is_metaspace_oome(oop exc) {
>>   return java_lang_Throwable::get_message(exc) == _metaspace_string.resolve();
>> }
>
> Maybe not.  Maybe the exception you're checking could be newly allocated and not use an interned string.

sorry I deleted my last comment.

-------------

PR: https://git.openjdk.java.net/jdk/pull/6672


More information about the hotspot-runtime-dev mailing list