From: Jeffrey A Law Date: Fri, 15 Jan 1999 01:54:12 +0000 (+0000) Subject: unroll.c (find_splittable_givs): For a DEST_ADDR giv... X-Git-Tag: prereleases/egcs-1.1.2-prerelease-1~38 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fe7804f9b87de35b803952e8da9c033eebe20fea;p=thirdparty%2Fgcc.git unroll.c (find_splittable_givs): For a DEST_ADDR giv... * unroll.c (find_splittable_givs): For a DEST_ADDR giv, do not share a register with another DEST_ADDR giv if the address is not valid. From-SVN: r24674 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 90ef799ef3b1..688008488b52 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,5 +1,8 @@ Fri Jan 15 01:19:42 1999 Jeffrey A Law (law@cygnus.com) + * unroll.c (find_splittable_givs): For a DEST_ADDR giv, do not share + a register with another DEST_ADDR giv if the address is not valid. + * h8300.h (ASM_OUTPUT_LABELREF): Use asm_fprintf, not fprintf. Mon Jan 11 20:23:34 1999 Richard Henderson diff --git a/gcc/unroll.c b/gcc/unroll.c index 72f1f046442b..cfb51f66c373 100644 --- a/gcc/unroll.c +++ b/gcc/unroll.c @@ -1,5 +1,5 @@ /* Try to unroll loops, and split induction variables. - Copyright (C) 1992, 93, 94, 95, 97, 1998 Free Software Foundation, Inc. + Copyright (C) 1992, 93, 94, 95, 97, 98, 1999 Free Software Foundation, Inc. Contributed by James E. Wilson, Cygnus Support/UC Berkeley. This file is part of GNU CC. @@ -2925,8 +2925,11 @@ find_splittable_givs (bl, unroll_type, loop_start, loop_end, increment, To share a register here, the values must be equal. */ && rtx_equal_p (v->same->mult_val, v->mult_val) - && rtx_equal_p (v->same->add_val, v->add_val)) - + && rtx_equal_p (v->same->add_val, v->add_val) + /* If the memory references have different modes, + then the address may not be valid and we must + not share registers. */ + && verify_addresses (v, giv_inc, unroll_number)) { v->dest_reg = v->same->dest_reg; v->shared = 1;