aboutsummaryrefslogtreecommitdiff
path: root/gcc/loop.c
diff options
context:
space:
mode:
authorJan Hubicka <jh@suse.cz>2001-06-18 17:35:47 +0200
committerJan Hubicka <hubicka@gcc.gnu.org>2001-06-18 15:35:47 +0000
commit923cbdc322ee080c02b94a95eece0618a2a78b47 (patch)
tree0803743d2349ea46ce205c05df7cae76a3374b1f /gcc/loop.c
parent049d2def48689b21149b6a7ad19c865e1d393627 (diff)
downloadgcc-923cbdc322ee080c02b94a95eece0618a2a78b47.zip
gcc-923cbdc322ee080c02b94a95eece0618a2a78b47.tar.gz
gcc-923cbdc322ee080c02b94a95eece0618a2a78b47.tar.bz2
unroll.c: Include predict.h.
* unroll.c: Include predict.h. (unroll_loop): Drop prediction notes on preconditioning. * predict.def (PRED_LOOP_PRECONDITIONG, PRED_LOOP_CONDITION): New; add comments on the others. * Makefile.in: (unroll.o): Add dependancy on predict.h. * loop.c (strength_reduce): Fix branch prediction. * stmt.c (emit_case_nodes): Optimize test whether index is in given interval. * predict.c (estimate_probability): Do not bail out early when note is present. (combine_predictions_for_insn): Fix note removal code. From-SVN: r43441
Diffstat (limited to 'gcc/loop.c')
-rw-r--r--gcc/loop.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/loop.c b/gcc/loop.c
index ec8dc0a..82f09f3 100644
--- a/gcc/loop.c
+++ b/gcc/loop.c
@@ -4505,7 +4505,7 @@ strength_reduce (loop, flags)
if ((flags & LOOP_BCT)
&& loop_info->n_iterations / loop_info->unroll_number > 1)
{
- int n = loop_info->n_iterations / loop_info->unroll_number - 1;
+ int n = loop_info->n_iterations / loop_info->unroll_number;
predict_insn (PREV_INSN (loop->end),
PRED_LOOP_ITERATIONS,
REG_BR_PROB_BASE - REG_BR_PROB_BASE / n);