RFR: 8361103: java_lang_Thread::async_get_stack_trace does not properly protect JavaThread [v2]

David Holmes dholmes at openjdk.org
Tue Jul 8 01:32:39 UTC 2025


On Tue, 8 Jul 2025 01:19:10 GMT, David Holmes <dholmes at openjdk.org> wrote:

>> No. This is for virtual thread. We need to get JavaThread from the carrier
>
> Got it.

Actually I think we need a further check here. If we get the carrier thread directly, we have not checked that it is actually protected by the TLH - that is normally done by `cv_internal_thread_to_JavaThread` but that doesn't know about virtual threads and carriers!). I need to check if we have to fix `cv_internal_thread_to_JavaThread` for the virtual thread case.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/26119#discussion_r2191295962


More information about the hotspot-dev mailing list