On Tue, 20 Dec 2022 20:52:10 GMT, Serguei Spitsyn <[email protected]> wrote:
>> Now the `JvmtiVTMSTransitionDisabler` mechanism supports disabling VTMS
>> transitions for all virtual threads only. It should also support disabling
>> transitions for any specific virtual thread as well. This will improve
>> scalability of the JVMTI functions operating on target virtual threads as
>> the functions can be executed concurrently without blocking each other
>> execution when target virtual threads are different.
>> New constructor `JvmtiVTMSTransitionDisabler(jthread vthread)` is added
>> which has jthread parameter of the target virtual thread.
>>
>> Testing:
>> mach5 jobs are TBD (preliminary testing was completed):
>> - all JVMTI, JDWP, JDI and JDB tests have to be run
>> - Kitchensink
>> - tier5
>
> Serguei Spitsyn has updated the pull request incrementally with one
> additional commit since the last revision:
>
> address wqsecond round review comments
One nit with the "is locked" asserts but otherwise looks good. Thanks for the
updates!
src/hotspot/share/classfile/javaClasses.cpp line 1739:
> 1737: void java_lang_Thread::inc_VTMS_transition_disable_count(oop
> java_thread) {
> 1738: int val = VTMS_transition_disable_count(java_thread);
> 1739: assert(JvmtiVTMSTransition_lock->is_locked(), "Must be locked");
You want to use `owned_by_self()` for these assertions - thanks.
-------------
Marked as reviewed by dholmes (Reviewer).
PR: https://git.openjdk.org/jdk/pull/11690