JDK-8354180 : Clean up uses of ObjectMonitor caches
  • Type: Bug
  • Component: hotspot
  • Sub-Component: runtime
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2025-04-09
  • Updated: 2025-04-11
  • Resolved: 2025-04-11
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 25
25 masterFixed
Related Reports
Relates :  
Description
The BasicLock and OMCaches shouldn't be used for deoptimization.  It's an unnecessary optimization and confuses the code when BasicLock cache is set and needs to be unset.

The OMCache has some unnecessary shuffling if the lock is found in the BasicLock cache.  The code to read caches can be made less duplicative.

The BasicLock cache needs to be cleared if a deflated monitor is found.  That's done in the right place now.

Some comments need to be added.
Comments
Changeset: 9ead2b75 Branch: master Author: Coleen Phillimore <coleenp@openjdk.org> Date: 2025-04-11 13:12:16 +0000 URL: https://git.openjdk.org/jdk/commit/9ead2b75cefa42732d3445f086dcf8d51452af2c
11-04-2025

A pull request was submitted for review. Branch: master URL: https://git.openjdk.org/jdk/pull/24545 Date: 2025-04-09 12:47:02 +0000
09-04-2025