RFR: 8148783: aarch64: SEGV running SpecJBB2013
edward.nevill at gmail.com
Mon Feb 1 20:33:57 UTC 2016
Please review the following webrev
JIRA Issue: https://bugs.openjdk.java.net/browse/JDK-8148783
The bug is explained in some detail in the JIRA issue.
The problem is that the sign is not preserved in the following code from adrp(...)
long offset = dest_page - pc_page;
offset = (offset & ((1<<20)-1)) << 12;
This generally works because the following movk overwrites bits 32..47
However on larger memory systems of 256 Gb it could happen that the PC address was
in which case the falsely positive offset could wrap to
Bit 48 does not get overwritten by the following movk, hence forming an invalid address.
The solution is to use int32_t for offset instead of long, so it gets sign extended correctly when added to the pc().
All the best,
More information about the hotspot-compiler-dev