[aarch64-port-dev ] RFR: 8143067: aarch64: guarantee failure in javac (adrp out of range in relocation)
edward.nevill at gmail.com
Wed Nov 18 13:06:40 UTC 2015
On Tue, 2015-11-17 at 15:34 +0000, Andrew Haley wrote:
> On 11/17/2015 09:56 AM, Edward Nevill wrote:
> > Please review the following webrev
> > http://cr.openjdk.java.net/~enevill/8143067/webrev
> I think this solution is far more complex than it should be. We could
> change it so that if an adrp is out of range for any address in the
> code cache (rather than simply from the current PC) the multi-
> instruction form is emitted. That way we won't need far_adrp() and we
> won't need all the extra patching code.
You are right. That makes it much simpler.
I have kept the adrp/nop and adrp/movk for generating the out of range addresses as this is 2 instructions instead of the 3 for movz/movk/movk.
The byte map base is almost always out of range because of the way it is calculated - IE. (byte map) - (heap base) >> 9 - so using 2 instructions as above gives a small performance boost.
More information about the hotspot-compiler-dev