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/22506] [4.1 regression] ICE with -ftree-vectorize in var_ann, at tree-flow-inline.h:115


------- Additional Comments From dorit at il dot ibm dot com  2005-07-27 14:27 -------
This patch should fix it:

Index: tree-vectorizer.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/tree-vectorizer.c,v
retrieving revision 2.105
diff -c -3 -p -r2.105 tree-vectorizer.c
*** tree-vectorizer.c   25 Jul 2005 12:04:51 -0000      2.105
--- tree-vectorizer.c   27 Jul 2005 14:01:46 -0000
*************** slpeel_update_phi_nodes_for_guard2 (edge
*** 640,645 ****
--- 640,649 ----
      {
        orig_phi = update_phi;
        orig_def = PHI_ARG_DEF_FROM_EDGE (orig_phi, e);
+       /* This loop-closed-phi actually doesn't represent a use
+        out of the loop - the phi arg is a constant.  */
+       if (TREE_CODE (orig_def) != SSA_NAME)
+       continue;
        orig_def_new_name = get_current_def (orig_def);
        arg = NULL_TREE;

(There's a loop-exit-phi that looks like this:
i13 = phi(0).
Since the phi arg is constant no updates are needed, 
we can just skip this phi).

-- 


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


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