This is a general cleanup after removing LockingMode related code.
It includes:
- Removing asserts() that are no longer necessary, since we removed legacy locking and monitor locking.
- Rewriting or deleting comments and arguments that are related to displaced headers.
- Dropping the lightweight prefix/suffix (e.g. fast_lock_lightweight and fast_unlock_lockweight should be renamed fast_lock and fast_unlock).
- Etc., etc.
In the review of JDK-8365190 a number of suggestions for further clean up came up. I'll list them here so we don't lose them:
- https://github.com/openjdk/jdk/pull/27041#discussion_r2317063086 (Delete displaced_header_offset_in_bytes)
- https://github.com/openjdk/jdk/pull/27041#discussion_r2317069783 (Can we now remove _held_monitor_count next)
- https://github.com/openjdk/jdk/pull/27041#discussion_r2317095107 (Remove dispatch functions)
- https://github.com/openjdk/jdk/pull/27041#discussion_r2318041555 (Simplify and unify this with FastHashCode)
- https://github.com/openjdk/jdk/pull/27041#discussion_r2317998409 (Remove parameter from MonitorExitStub)
- https://github.com/openjdk/jdk/pull/27041#discussion_r2320634417 (Re-type/name metadata in BasicLock)
- https://github.com/openjdk/jdk/pull/27041#discussion_r2320643671 (Delete displaced_header_offset_in_bytes)
- https://github.com/openjdk/jdk/pull/27041#discussion_r2317088830 (Eliminating the middle call)
It includes:
- Removing asserts() that are no longer necessary, since we removed legacy locking and monitor locking.
- Rewriting or deleting comments and arguments that are related to displaced headers.
- Dropping the lightweight prefix/suffix (e.g. fast_lock_lightweight and fast_unlock_lockweight should be renamed fast_lock and fast_unlock).
- Etc., etc.
In the review of JDK-8365190 a number of suggestions for further clean up came up. I'll list them here so we don't lose them:
- https://github.com/openjdk/jdk/pull/27041#discussion_r2317063086 (Delete displaced_header_offset_in_bytes)
- https://github.com/openjdk/jdk/pull/27041#discussion_r2317069783 (Can we now remove _held_monitor_count next)
- https://github.com/openjdk/jdk/pull/27041#discussion_r2317095107 (Remove dispatch functions)
- https://github.com/openjdk/jdk/pull/27041#discussion_r2318041555 (Simplify and unify this with FastHashCode)
- https://github.com/openjdk/jdk/pull/27041#discussion_r2317998409 (Remove parameter from MonitorExitStub)
- https://github.com/openjdk/jdk/pull/27041#discussion_r2320634417 (Re-type/name metadata in BasicLock)
- https://github.com/openjdk/jdk/pull/27041#discussion_r2320643671 (Delete displaced_header_offset_in_bytes)
- https://github.com/openjdk/jdk/pull/27041#discussion_r2317088830 (Eliminating the middle call)