[lworld] RFR: 8336837: [lworld] Invalid monitor information in JVMState when buffering at return

Tobias Hartmann thartmann at openjdk.org
Tue Aug 13 14:43:31 UTC 2024


Similar to [JDK-8244519](https://bugs.openjdk.java.net/browse/JDK-8244519) / https://github.com/openjdk/valhalla/pull/36, while processing the JVMState of a buffer allocation at method return, we assert because there is no monitor information although the method is synchronized. The problem is that we call `shared_unlock` before buffering the return value (when returning a scalarized value object in non-scalarized form). The fix is to do that only afterwards. I also removed some stale code / comments and added corresponding tests.

Best regards,
Tobias

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

Commit messages:
 - 8336837: [lworld] Invalid monitor information in JVMState when buffering at return

Changes: https://git.openjdk.org/valhalla/pull/1206/files
  Webrev: https://webrevs.openjdk.org/?repo=valhalla&pr=1206&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8336837
  Stats: 32 lines in 2 files changed: 21 ins; 11 del; 0 mod
  Patch: https://git.openjdk.org/valhalla/pull/1206.diff
  Fetch: git fetch https://git.openjdk.org/valhalla.git pull/1206/head:pull/1206

PR: https://git.openjdk.org/valhalla/pull/1206


More information about the valhalla-dev mailing list