[Bug tree-optimization/33680] [4.3 Regression] ICE when compilling elbg.c from ffmpeg (vectorizer)

irar at il dot ibm dot com gcc-bugzilla@gcc.gnu.org
Thu Oct 11 10:44:00 GMT 2007



------- Comment #13 from irar at il dot ibm dot com  2007-10-11 10:43 -------
Maybe we can fix DCE not to eliminate such vars?

Or somehow fix split_constant_offset?
The following patch changes the base from 
(int[0:D.1553] *) newcentroid.1_22 + (long unsigned int) dim_4(D) * 8
to (int[0:D.1553] *) D.1560_21 + (long unsigned int) dim_4(D) * 8
and, hence, there is no need in the size of newcentroid.1_22:

Index: tree-data-ref.c
===================================================================
--- tree-data-ref.c     (revision 128902)
+++ tree-data-ref.c     (working copy)
@@ -579,8 +579,10 @@ split_constant_offset (tree exp, tree *v
              {
                split_constant_offset (def_stmt_rhs, &var0, &off0);
                var0 = fold_convert (type, var0);
-               *var = var0;
-               *off = off0;
+               split_constant_offset (var0, &var2, &off2);
+               *var = var2;
+               *off = fold_build2 (PLUS_EXPR, TREE_TYPE (off2),
+                                off0, off2);
                return;
              }
          }
Maybe we can check if the base is of the VLA type and then try to further split
it as above (and not to vectorize if we fail)?

Thanks,
Ira


-- 

irar at il dot ibm dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |rakdver at gcc dot gnu dot
                   |                            |org
           Priority|P1                          |P3


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



More information about the Gcc-bugs mailing list