Re: RFR: 8297286: runtime/vthread tests crashing after JDK-8296324 [v14]

2023-03-31 Thread Serguei Spitsyn
On Fri, 31 Mar 2023 06:52:18 GMT, Serguei Spitsyn  wrote:

>> The fix is to enable virtual threads support for late binding JVMTI agents.
>> The fix includes:
>> - New function `JvmtiEnvBase::enable_virtual_threads_notify_jvmti()` which 
>> does enabling JVMTI VTMS transition notifications in case of agent loaded 
>> into running VM. This function executes a VM operation counting VTMS 
>> transition bits in all `JavaThread`'s to correctly set the static counter 
>> `_VTMS_transition_count` needed for VTMS transition protocol.
>> - New function `JvmtiEnvBase::disable_virtual_threads_notify_jvmti()` which 
>> is needed for testing. It is used by the `WhiteBox` API.
>> - New WhiteBox function `WB_SetVirtualThreadsNotifyJvmtiMode(JNIEnv* env, 
>> jobject wb, jboolean enable)` needed for testing of this update.
>> - New regression test: `serviceability/jvmti/vthread/ToggleNotifyJvmtiTest`
>> 
>> Testing:
>> - New test: `serviceability/jvmti/vthread/ToggleNotifyJvmtiTest`
>> - The originally failed tests are expected to pass now:
>>   `runtime/vthread/RedefineClass.java`
>>   `runtime/vthread/TestObjectAllocationSampleEvent.java` 
>> - In progress: Run the tiers 1-6 to make sure there are no regression.
>
> Serguei Spitsyn has updated the pull request incrementally with one 
> additional commit since the last revision:
> 
>   review: addressed next round of review suggestions

Leonid and Chris, thank you for review!

-

PR Comment: https://git.openjdk.org/jdk/pull/13133#issuecomment-1492575146


Re: RFR: 8297286: runtime/vthread tests crashing after JDK-8296324 [v14]

2023-03-31 Thread Chris Plummer
On Fri, 31 Mar 2023 06:52:18 GMT, Serguei Spitsyn  wrote:

>> The fix is to enable virtual threads support for late binding JVMTI agents.
>> The fix includes:
>> - New function `JvmtiEnvBase::enable_virtual_threads_notify_jvmti()` which 
>> does enabling JVMTI VTMS transition notifications in case of agent loaded 
>> into running VM. This function executes a VM operation counting VTMS 
>> transition bits in all `JavaThread`'s to correctly set the static counter 
>> `_VTMS_transition_count` needed for VTMS transition protocol.
>> - New function `JvmtiEnvBase::disable_virtual_threads_notify_jvmti()` which 
>> is needed for testing. It is used by the `WhiteBox` API.
>> - New WhiteBox function `WB_SetVirtualThreadsNotifyJvmtiMode(JNIEnv* env, 
>> jobject wb, jboolean enable)` needed for testing of this update.
>> - New regression test: `serviceability/jvmti/vthread/ToggleNotifyJvmtiTest`
>> 
>> Testing:
>> - New test: `serviceability/jvmti/vthread/ToggleNotifyJvmtiTest`
>> - The originally failed tests are expected to pass now:
>>   `runtime/vthread/RedefineClass.java`
>>   `runtime/vthread/TestObjectAllocationSampleEvent.java` 
>> - In progress: Run the tiers 1-6 to make sure there are no regression.
>
> Serguei Spitsyn has updated the pull request incrementally with one 
> additional commit since the last revision:
> 
>   review: addressed next round of review suggestions

Changes look good, but for the most part I just looked at the test related 
changes.

-

Marked as reviewed by cjplummer (Reviewer).

PR Review: https://git.openjdk.org/jdk/pull/13133#pullrequestreview-1367488100


Re: RFR: 8297286: runtime/vthread tests crashing after JDK-8296324 [v14]

2023-03-30 Thread Serguei Spitsyn
> The fix is to enable virtual threads support for late binding JVMTI agents.
> The fix includes:
> - New function `JvmtiEnvBase::enable_virtual_threads_notify_jvmti()` which 
> does enabling JVMTI VTMS transition notifications in case of agent loaded 
> into running VM. This function executes a VM operation counting VTMS 
> transition bits in all `JavaThread`'s to correctly set the static counter 
> `_VTMS_transition_count` needed for VTMS transition protocol.
> - New function `JvmtiEnvBase::disable_virtual_threads_notify_jvmti()` which 
> is needed for testing. It is used by the `WhiteBox` API.
> - New WhiteBox function `WB_SetVirtualThreadsNotifyJvmtiMode(JNIEnv* env, 
> jobject wb, jboolean enable)` needed for testing of this update.
> - New regression test: `serviceability/jvmti/vthread/ToggleNotifyJvmtiTest`
> 
> Testing:
> - New test: `serviceability/jvmti/vthread/ToggleNotifyJvmtiTest`
> - The originally failed tests are expected to pass now:
>   `runtime/vthread/RedefineClass.java`
>   `runtime/vthread/TestObjectAllocationSampleEvent.java` 
> - In progress: Run the tiers 1-6 to make sure there are no regression.

Serguei Spitsyn has updated the pull request incrementally with one additional 
commit since the last revision:

  review: addressed next round of review suggestions

-

Changes:
  - all: https://git.openjdk.org/jdk/pull/13133/files
  - new: https://git.openjdk.org/jdk/pull/13133/files/1bb250a7..aef87273

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=13133&range=13
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=13133&range=12-13

  Stats: 34 lines in 1 file changed: 3 ins; 7 del; 24 mod
  Patch: https://git.openjdk.org/jdk/pull/13133.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/13133/head:pull/13133

PR: https://git.openjdk.org/jdk/pull/13133