RFR: 8350483: AArch64: turn on signum intrinsics by default on Ampere CPUs
Andrew Haley
aph at openjdk.org
Tue Feb 25 14:26:58 UTC 2025
On Tue, 25 Feb 2025 04:57:24 GMT, Patrick Zhang <qpzhang at openjdk.org> wrote:
> > > Maybe we should think about removing the `UseSignumIntrinsic` flag altogether.
> >
> >
> > Ah, the flag is also used by other ports. But it doesn't make much sense for us not to use the intrinsic.
>
> Thanks for your review @theRealAph.
>
> Yes, agree with you that we should turn on signum intrinsics (`-XX:+UseSignumIntrinsic`), probably `-XX:+UseCopySignIntrinsic` too. I had a larger test set on Neoverse-N1 and Ampere CPUs, and compared w/ vs w/o these two flags respectively, no obvious performance regression so far. `-XX:+UseSignumIntrinsic` can produce obvious benefits on `fmov` cases, while `-XX:+UseCopySignIntrinsic` can also bring +15% improvements to `*MathBench.signum*` tests when disabling the signum intrinsics. In Math.java, signum calls copySign, as such the benefit of copysign intrinsics would be hidden in a manner. Therefore, I think they two could be turned on altogether. A JBS ticket is required to track so.
Here's one: [JDK-8350663](https://bugs.openjdk.org/browse/JDK-8350663) Are you interested in picking it up?
-------------
PR Comment: https://git.openjdk.org/jdk/pull/23735#issuecomment-2682151356
More information about the hotspot-dev
mailing list