[concurrency-interest] @Contended (JEP-142)

Aleksey Shipilev aleksey.shipilev at oracle.com
Fri Nov 30 08:41:08 EST 2012

On 11/30/2012 05:36 PM, Vitaly Davidovich wrote:
> What's the plan for making this info available in heap dumps (taken
> using jmap)? I'd imagine tools like Eclipse MAT may want to indicate
> that a given instance of a class has padding applied.  Otherwise, the
> object size reported won't match expectation (without knowing that
> padding was applied).

Can't speak for other implementations, but HotSpot would report the
proper sizes/offset via Instrumentation.objectSize and
Unsafe.*fieldOffset. As long as tooling is not doing dumb
"sum(fieldTypeCount*fieldSizeAsMandatedByJLS)", it should pick up the
proper sizes.


More information about the Concurrency-interest mailing list