]> git.ipfire.org Git - thirdparty/gcc.git/commit
Do not generate vmaddfp and vnmsubfp
authorMichael Meissner <meissner@linux.ibm.com>
Mon, 22 May 2023 15:26:08 +0000 (11:26 -0400)
committerMichael Meissner <meissner@linux.ibm.com>
Mon, 22 May 2023 15:26:08 +0000 (11:26 -0400)
commitc970030226341f0c7fa9f319b37786ca81703c6d
tree98a2b59276f9cb178a1ac04553a87db9d9ed4532
parent79a7d8fa0000b389405c935fa5943d28c48baec2
Do not generate vmaddfp and vnmsubfp

This is version 3 of the patch.  This is essentially version 1 with the removal
of changes to altivec.md, and cleanup of the comments.

Version 2 generated the vmaddfp and vnmsubfp instructions if -Ofast was used,
and those changes are deleted in this patch.

The Altivec instructions vmaddfp and vnmsubfp have different rounding behaviors
than the VSX xvmaddsp and xvnmsubsp instructions.  In particular, generating
these instructions seems to break Eigen on big endian systems.

I have done bootstrap builds on power9 little endian (with both IEEE long
double and IBM long double).  I have also done the builds and test on a power8
big endian system (testing both 32-bit and 64-bit code generation).  Chip has
verified that it fixes the problem that Eigen encountered.  Can I check this
into the master GCC branch?  After a burn-in period, can I check this patch
into the active GCC branches?

Thanks in advance.

2023-05-22   Michael Meissner  <meissner@linux.ibm.com>

gcc/

PR target/70243
* config/rs6000/vsx.md (vsx_fmav4sf4): Do not generate vmaddfp.  Back
port from master 04/10/2023.
(vsx_nfmsv4sf4): Do not generate vnmsubfp.

gcc/testsuite/

PR target/70243
* gcc.target/powerpc/pr70243.c: New test.  Back port from master
04/10/2023.
gcc/config/rs6000/vsx.md
gcc/testsuite/gcc.target/powerpc/pr70243.c [new file with mode: 0644]