RFR: 8167659: Access of mark word should use oopDesc::mark_offset_in_bytes() instead of '0'

Roman Kennke rkennke at redhat.com
Thu Oct 13 09:40:25 UTC 2016


In several places in Hotspot's assembly routines, we're using
Address(obj, 0) to access the object's mark word. This is bad style and
makes it very hard to find all the places where the mark word is used.
It should use Address(obj, oopDesc::mark_offset_in_bytes()) instead. 

The change addresses the issue in x86 and aarch64. I'm not familiar
with the othe arches, maybe somebody wants to check and fill them in?

http://cr.openjdk.java.net/~rkennke/markoffset-hs/webrev.00/

Roman



More information about the hotspot-dev mailing list