[Bug tree-optimization/42286] New: October 23rd change to tree-ssa-pre.c breaks calculix on powerpc with -ffast-math
meissner at gcc dot gnu dot org
gcc-bugzilla@gcc.gnu.org
Fri Dec 4 21:14:00 GMT 2009
The October 23rd, 2009 change to tree-ssa-pre.c breaks calculix on powerpc with
-ffast-math. When you start up the benchmark with reference input, it fails
almost immediately because the calculations don't converge.
At this point, I don't have a narrowed down test case, but the following
change:
2009-10-23 Richard Guenther <rguenther@suse.de>
PR tree-optimization/41778
* tree-ssa-pre.c (do_regular_insertion): Only insert if a
redundancy along a path in the CFG we want to optimize for speed
is going to be removed.
(execute_pre): Do partial-PRE only if the function is to be
optimized for speed.
(gate_pre): Do not turn off all of PRE when not optimizing a
function for speed.
Now prevents the spec 2006 calculix benchmark from running if calculix was
built with -ffast-math. The change is due to the special code in rs6000.md
(and mips.md) for optimizing negative multiply and add and negative multiply
and subtract optimizations with -fno-signed-zeros is used (which is set with
-ffast-math).
If I undo this one change in a local compiler, it builds and runs fine at full
speed.
If I disable the negative multiply and subtract operation from the the machine
description, it runs fine, but at about 1/2 speed. Similarly if I disable
-ffast-math, it runs fine, but at 1/2 speed.
If I use the -fno-tree-pre option to disable the PRE pass, it fails.
--
Summary: October 23rd change to tree-ssa-pre.c breaks calculix on
powerpc with -ffast-math
Product: gcc
Version: 4.5.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: tree-optimization
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: meissner at gcc dot gnu dot org
GCC build triplet: powerpc64-unknown-linux-gnu
GCC host triplet: powerpc64-unknown-linux-gnu
GCC target triplet: powerpc64-unknown-linux-gnu
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42286
More information about the Gcc-bugs
mailing list