From: Jeffrey A Law Date: Thu, 27 Nov 1997 19:23:00 +0000 (+0000) Subject: unroll.c (find_splittable_givs): Don't split givs with a dest_reg that was created... X-Git-Tag: releases/egcs-1.0.0~32 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8ea8344137367f231a5ebbac2dd671d4d35204f7;p=thirdparty%2Fgcc.git unroll.c (find_splittable_givs): Don't split givs with a dest_reg that was created by loop. * unroll.c (find_splittable_givs): Don't split givs with a dest_reg that was created by loop. Fixes bzip2 bug. From-SVN: r16802 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 588a7d65b2ea..acaa173f91b7 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -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 * expr.c (preexpand_calls): Don't look past a TRY_CATCH_EXPR. diff --git a/gcc/unroll.c b/gcc/unroll.c index 0c298751685a..eccd09f3232f 100644 --- a/gcc/unroll.c +++ b/gcc/unroll.c @@ -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)