RFR: 8341273: JVMTI is not properly hiding some continuation related methods [v3]

Serguei Spitsyn sspitsyn at openjdk.org
Tue Oct 15 22:02:12 UTC 2024


On Tue, 15 Oct 2024 20:40:50 GMT, Alex Menkov <amenkov at openjdk.org> wrote:

>> Serguei Spitsyn has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Disallow NotifyFramePop for enter/enter0/VirtualThread.run/VThreadContinuation.run
>
> src/hotspot/share/prims/jvmtiEnvBase.cpp line 692:
> 
>> 690:   if (jt->is_in_VTMS_transition()) {
>> 691:     jvf = check_and_skip_hidden_frames(jt->is_in_VTMS_transition(), jvf);
>> 692:   } else if (is_virtual) { // filter out pure continuations
> 
> Not sure I follow the logic here.
> As far as I understand yield/yield need to be filtered out only for unmounted virtual threads. But `is_virtual` here means we have mounted VT?
> Looks like almost all callers call this method only if `jt->is_in_JTMS_transilition()` is true
> Exception is a call from `get_vthread_jvf()` when vthread is mounted.

This seems to be a good catch. The call to `skip_top_jvmti_annotated_frames()` should not be needed.
It does not harm either, so I've added it for safety.
Will remove it and rerun mach5 tiers to make sure there is nothing unexpected.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/21397#discussion_r1802065755


More information about the serviceability-dev mailing list