Optimizing byte reverse code for int value
martin.doerr at sap.com
Tue Apr 11 13:43:04 UTC 2017
thank you for your helpful comments. I fully agree with you.
In addition, I noticed that we don't have match rules which exploit byte reverse load/store instructions on PPC64.
SPARC already has them:
match(Set dst (ReverseBytesI/L/US/S (LoadI src)));
match(Set dst (StoreI dst (ReverseBytesI/L/US/S src)));
I think we should add them for jdk10. They should be used when the platform endianness doesn't match the bigEndian parameter in Unsafe methods.
From: hotspot-dev [mailto:hotspot-dev-bounces at openjdk.java.net] On Behalf Of Andrew Haley
Sent: Dienstag, 11. April 2017 13:02
To: Michihiro Horie <HORIE at jp.ibm.com>
Cc: Simonis, Volker <volker.simonis at sap.com>; ppc-aix-port-dev at openjdk.java.net; hotspot-dev at openjdk.java.net; Hiroshi H Horii <HORII at jp.ibm.com>
Subject: Re: Optimizing byte reverse code for int value
On 11/04/17 11:36, Michihiro Horie wrote:
> Thank you very much for letting us know Unsafe.getIntUnaligned is available in
> JDK9. I do agree we should fix Java source code.
> We think our byte-reverse optimization would still work on jdk8u as Hiroshi
> mentioned. Would you agree on this point?
I do, but I do not agree that this patch should necessarily be done in
the PowerPC-specific back end. Have you considered it as a generic
optimization for all processors?
More information about the hotspot-dev