http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46728
Summary: GCC no longer generates fmadd for pow (x, 0.75)+y on
powerpc
Product: gcc
Version: 4.6.0
Status: UNCONFIRMED
Severity: enhancement
Priority: P3
Component: tree-optimization
AssignedTo: [email protected]
ReportedBy: [email protected]
Host: powerpc64-linux
Target: powerpc64-linux
Build: powerpc64-linux
Created attachment 22582
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=22582
Test file that when compiled with -ffast-math -mcpu=power6 shows the bug
With Richard Henderson's change on 2010-11-16 to move the FMA generation to the
gimple level, and remove all of the combiners in the backend for fma, the
compiler now does not generate a fma for the __builtin_pow (x, 0.75)
optimization if the result of the pow is added to another value. Now, the
actual benchmark that prompted adding the __builtin_pow (x, 0.75) optimization
does not combine the pow with an add, other people might run into it.
This is due to the fact that the pow transformation is done at the rtl level,
and not the tree level, and with the combiners removed, the compiler does not
do the transformation. The right solution is to move this optimization to the
tree level.