[jdk19] RFR: 8289091: move oop safety check from SharedRuntime::get_java_tid() to JavaThread::threadObj() [v2]

David Holmes dholmes at openjdk.org
Thu Jun 30 03:16:43 UTC 2022


On Wed, 29 Jun 2022 18:40:17 GMT, Daniel D. Daugherty <dcubed at openjdk.org> wrote:

> I'm very glad that I resisted putting the check in threadObj() when I made the changes for ...

The problem has not been (until now) what you put in threadObj but the other checks you decided to put in.

But now the issue has been raised, any code that can be executed in the context of a signal handler must use `Thread::current_or_null_safe()`. I don't know if the sharedRuntime code falls into that category but a call to `threadObj()` certainly can.

Sorry this has not been smooth sailing.

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

PR: https://git.openjdk.org/jdk19/pull/69


More information about the hotspot-runtime-dev mailing list