RFR: 8345293: Fix generational Shenandoah with compact headers

Roman Kennke rkennke at openjdk.org
Tue Dec 3 16:48:42 UTC 2024


On Mon, 2 Dec 2024 11:09:37 GMT, Roman Kennke <rkennke at openjdk.org> wrote:

> See bug for crash details.
> 
> The problem is in the code that gets the object age out of the mark-word. That code has a special cases for when an object is monitor locked, in which case it fetches the displaced header out of the monitor and extracts the age from there. However, with compact headers, we're running with ObjectMonitorTable, and decoding the monitor-locked mark-word crashes.
> 
> The fix is simple: when we are running with ObjectMonitorTable, the mark-word never gets overloaded by locking, so we can return the age straight out of the mark-word.
> 
> Testing:
>  - [x] hotspot_gc_shenandoah +UCOH

Thanks!

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

PR Comment: https://git.openjdk.org/jdk/pull/22477#issuecomment-2515074738


More information about the shenandoah-dev mailing list