RFR: 8319137: release _object in ObjectMonitor dtor to avoid races [v2]

Axel Boldt-Christmas aboldtch at openjdk.org
Tue Nov 21 13:33:08 UTC 2023


On Tue, 21 Nov 2023 11:06:10 GMT, David Holmes <dholmes at openjdk.org> wrote:

> > Lgtm.
> > Could potentially remove the `if (_object.is_null())` checks in `ObjectMonitor::object` and `ObjectMonitor::object_peek`. Should never take those branches.
> 
> @xmas92 is your comment/suggestion now invalidated by the issue we discovered with JNI monitor locking and rclaimed objects?

`WeakHandle::is_null` refers to the pointer into oop storage.

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

PR Comment: https://git.openjdk.org/jdk/pull/16738#issuecomment-1820928116


More information about the hotspot-runtime-dev mailing list