RFR: 8305895: Implement JEP 450: Compact Object Headers (Experimental) [v6]
Chris Plummer
cjplummer at openjdk.org
Mon Sep 9 16:56:08 UTC 2024
On Mon, 9 Sep 2024 14:32:49 GMT, Roman Kennke <rkennke at openjdk.org> wrote:
>> src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/oops/Oop.java line 169:
>>
>>> 167: } else {
>>> 168: visitor.doMetadata(klass, true);
>>> 169: }
>>
>> Why is there no `visitor.doMetadata()` call for the compact object header case?
>
> There is no dedicated klass field anymore, the Klass* is encoded in the mark, and we would need to extract it. What is the purpose of the visitors? Do they need to see the klass/compressedKlass, or is it sufficient to visit the mark-word (which we already do, but as CInt).
I've been looking into this. It's a bit hard to follow but I think you do need to do something more here. Can you run ClhsdbInspect.java and send me the output. In specific I need to know if the log includes the following:
hsdb> + inspect 0x00000007cff154b8
instance of Oop for java/util/concurrent/locks/AbstractQueuedSynchronizer$ConditionObject @ 0x00000007cff154b8 (size = 24)
_mark: 1
_metadata._compressed_klass: InstanceKlass for java/util/concurrent/locks/AbstractQueuedSynchronizer$ConditionObject
firstWaiter: Oop for java/util/concurrent/locks/AbstractQueuedSynchronizer$ConditionNode @ 0x00000007cfff5f80
lastWaiter: Oop for java/util/concurrent/locks/AbstractQueuedSynchronizer$ConditionNode @ 0x00000007cfff5f80
this$0: Oop for java/util/concurrent/locks/ReentrantLock$NonfairSync @ 0x00000007cff15498
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/20677#discussion_r1750598648
More information about the serviceability-dev
mailing list