Relates :
|
|
Relates :
|
|
Relates :
|
The JVMTI functions GetOwnedMonitorInfo() and GetOwnedMonitorStackDepthInfo() can be used to retrieve objects locked by a thread. In terms of escape analysis those references escape and optimizations like scalar replacement become invalid. The runtime currently does not revert optimizations based on escape analysis before objects escape through JVMTI (try included tests). Therefore escape analysis should be disabled if an agent requests the capabilities can_get_owned_monitor_info or can_get_owned_monitor_stack_depth_info. can_get_owned_monitor_info and can_get_owned_monitor_stack_depth_info are both OnLoad capabilities that cannot be changed once the VM is executing the Java program. With JDK-8227745 escape analysis can remain enabled.
|