On Fri, 11 Sep 2020 02:49:04 GMT, David Holmes <dhol...@openjdk.org> wrote:

>> src/hotspot/share/services/threadService.cpp line 888:
>> 
>>> 886:       _thread_status == java_lang_Thread::IN_OBJECT_WAIT_TIMED) {
>>> 887:
>>> 888:     Handle obj = ThreadService::get_current_contended_monitor(thread);
>> 
>> There must be a safepoint here then.
>> I think this would be better and safer if blocker_object and 
>> blocker_object_owner are Handles.  Can you change them to
>> Handles?
>
> I can't see anywhere a safepoint check would occur in that code. This issue 
> was flagged as being in Loom so perhaps the
> loom code is different and is what introduces the safepoint check? But I 
> agree with Coleen that the best solution is to
> just use Handles.

It is not loom-specific and reproduced n jdk/jdk with -XX:+CheckUnhandledOops.

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

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

Reply via email to