This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug tree-optimization/46213] [4.6 Regression] gfortran.dg/aliasing_array_result_1.f90 ICE: in vectorizable_reduction, at tree-vect-loop.c:4046 with custom compiler flags


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46213

Ira Rosen <irar at il dot ibm.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED
         AssignedTo|unassigned at gcc dot       |irar at gcc dot gnu.org
                   |gnu.org                     |

--- Comment #4 from Ira Rosen <irar at il dot ibm.com> 2010-11-02 08:32:15 UTC ---
I am testing:

Index: tree-vect-loop.c
===================================================================
--- tree-vect-loop.c    (revision 166172)
+++ tree-vect-loop.c    (working copy)
@@ -1800,7 +1800,11 @@ vect_is_simple_reduction_1 (loop_vec_inf
      simply rewriting this into "res += -x[i]".  Avoid changing
      gimple instruction for the first simple tests and only do this
      if we're allowed to change code at all.  */
-  if (code == MINUS_EXPR && modify)
+  if (code == MINUS_EXPR
+      && modify
+      && (op1 = gimple_assign_rhs1 (def_stmt))
+      && TREE_CODE (op1) == SSA_NAME
+      && SSA_NAME_DEF_STMT (op1) == phi)
     code = PLUS_EXPR;

   if (check_reduction


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]