]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
unroll.c (find_splittable_givs): Don't split givs with a dest_reg that was created...
authorJeffrey A Law <law@cygnus.com>
Thu, 27 Nov 1997 19:23:00 +0000 (19:23 +0000)
committerJeff Law <law@gcc.gnu.org>
Thu, 27 Nov 1997 19:23:00 +0000 (12:23 -0700)
        * unroll.c (find_splittable_givs): Don't split givs with a dest_reg
        that was created by loop.
Fixes bzip2 bug.

From-SVN: r16802

gcc/ChangeLog
gcc/unroll.c

index 588a7d65b2eae57021b22622de1f0ca00bfc2a90..acaa173f91b7952ce3752aacf76582746cb3eb81 100644 (file)
@@ -1,3 +1,8 @@
+Thu Nov 27 12:20:19 1997  Jeffrey A Law  (law@cygnus.com)
+
+       * unroll.c (find_splittable_givs): Don't split givs with a dest_reg
+       that was created by loop.
+
 Thu Nov 27 09:34:58 1997  Jason Merrill  <jason@yorick.cygnus.com>
 
        * expr.c (preexpand_calls): Don't look past a TRY_CATCH_EXPR.
index 0c298751685acf727243555739d171233a0f0157..eccd09f3232fc2b277341b50844f1f3938d5e552 100644 (file)
@@ -2667,6 +2667,12 @@ find_splittable_givs (bl, unroll_type, loop_start, loop_end, increment,
     {
       rtx giv_inc, value;
 
+      
+      /* If this is a new register, can't handle it since it does not have
+        an entry in reg_n_info.  */
+      if (REGNO (v->dest_reg) >= max_reg_before_loop)
+       continue;
+
       /* Only split the giv if it has already been reduced, or if the loop is
         being completely unrolled.  */
       if (unroll_type != UNROLL_COMPLETELY && v->ignore)