RFR: 8231955: ARM32: Address displacement is 0 for volatile field access because of Unsafe field access.
christoph.goettschkes at microdoc.com
christoph.goettschkes at microdoc.com
Thu Oct 24 10:03:42 UTC 2019
Hi,
I already send this RFR to the hotspot-compiler-dev mailing list but
didn't
get any response, so I am cross-posting the request here:
Please review the following changeset. This patch fixes the volatile field
access for 32-bit ARM. The functions LIRGenerator::volatile_field_store
and LIRGenerator::volatile_field_load both assume that the displacement
for the given address is always 0. Both use the given address and pass the
values to add_large_constant() [1], which asserts that the given
displacement is not 0. The change does not call add_large_constant if the
given displacement is 0. The displacement can be 0, because of the
implementation of the unsafe intrinsics. This happens, because the offset
into the object from which the field is accessed is not a constant value.
This fixes the hotspot tier1 tests mentioned in the issue.
Bug: https://bugs.openjdk.java.net/browse/JDK-8231955
Webrev: https://cr.openjdk.java.net/~bulasevich/8231955/webrev.00/
Thanks,
Christoph
[1]
https://hg.openjdk.java.net/jdk/jdk/file/30a9612a657d/src/hotspot/cpu/arm/c1_LIRGenerator_arm.cpp#l166
More information about the aarch32-port-dev
mailing list