diff options
author | obrien <obrien@FreeBSD.org> | 2002-05-09 20:02:13 +0000 |
---|---|---|
committer | obrien <obrien@FreeBSD.org> | 2002-05-09 20:02:13 +0000 |
commit | c8f5fc7032940ad6633f932ac40cade82ec4d0cc (patch) | |
tree | 29a0f0a6c79a69ecc64f612947a0fe5904311713 /contrib/gcc/unroll.c | |
parent | c9ab9ae440a8066b2c2b85b157b1fdadcf09916a (diff) | |
download | FreeBSD-src-c8f5fc7032940ad6633f932ac40cade82ec4d0cc.zip FreeBSD-src-c8f5fc7032940ad6633f932ac40cade82ec4d0cc.tar.gz |
Gcc 3.1.0 pre-release from the FSF anoncvs repo on 9-May-2002 15:57:15 EDT.
Diffstat (limited to 'contrib/gcc/unroll.c')
-rw-r--r-- | contrib/gcc/unroll.c | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/contrib/gcc/unroll.c b/contrib/gcc/unroll.c index 9a0cfcf..6936a71 100644 --- a/contrib/gcc/unroll.c +++ b/contrib/gcc/unroll.c @@ -727,8 +727,7 @@ unroll_loop (loop, insn_count, strength_reduce_p) if (max_labelno > 0) { - map->label_map = (rtx *) xmalloc (max_labelno * sizeof (rtx)); - + map->label_map = (rtx *) xcalloc (max_labelno, sizeof (rtx)); local_label = (char *) xcalloc (max_labelno, sizeof (char)); } @@ -2222,6 +2221,7 @@ copy_loop_body (loop, copy_start, copy_end, map, exit_label, last_iteration, pattern = copy_rtx_and_substitute (PATTERN (insn), map, 0); copy = emit_call_insn (pattern); REG_NOTES (copy) = initial_reg_note_copy (REG_NOTES (insn), map); + SIBLING_CALL_P (copy) = SIBLING_CALL_P (insn); /* Because the USAGE information potentially contains objects other than hard registers, we need to copy it. */ @@ -3744,7 +3744,18 @@ loop_iterations (loop) for (biv_inc = bl->biv; biv_inc; biv_inc = biv_inc->next_iv) { if (loop_insn_first_p (v->insn, biv_inc->insn)) - offset -= INTVAL (biv_inc->add_val); + { + if (REG_P (biv_inc->add_val)) + { + if (loop_dump_stream) + fprintf (loop_dump_stream, + "Loop iterations: Basic induction var add_val is REG %d.\n", + REGNO (biv_inc->add_val)); + return 0; + } + + offset -= INTVAL (biv_inc->add_val); + } } } if (loop_dump_stream) |