diff options
author | rsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4> | 2004-07-27 07:27:12 +0000 |
---|---|---|
committer | rsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4> | 2004-07-27 07:27:12 +0000 |
commit | a255f65a7c9820a126c7f94f5fa7b1c885a92807 (patch) | |
tree | 3acb7007422c04dcb1bc209a9aeb6d560798c498 /gcc/loop-iv.c | |
parent | 54d688ae6b3f3b5421563eaffca0fbcc53d61641 (diff) | |
download | gcc-a255f65a7c9820a126c7f94f5fa7b1c885a92807.tar.gz |
* expr.h (canonicalize_condition, get_condition): Add an int argument.
* gcse.c (fis_get_condition): Reimplement using get_condition, leaving
it to check whether the condition is still valid at the jump insn.
* ifcvt.c (noce_get_condition): Likewise.
(noce_get_alt_condition): Update call to canonicalize_condition.
* loop-iv.c (simplify_using_initial_values): Update call to
get_condition. Remove FIXME.
(check_simple_exit): Update call to get_condition.
* loop-unswitch.c (may_unswitch_on): Likewise.
* loop.c (check_dbra_loop): Likewise.
(canonicalize_condition, get_condition): Add an argument to say whether
the condition must still be valid at INSN.
(get_condition_for_loop): Update call to get_condition. Require that
the condition be valid at INSN.
* predict.c (estimate_probability): Update call to get_condition.
Remove unused earliest parameter.
(expected_value_to_br_prob): Update call to canonicalize_condition.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@85218 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/loop-iv.c')
-rw-r--r-- | gcc/loop-iv.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/gcc/loop-iv.c b/gcc/loop-iv.c index f390cdd487c..68b0013c06c 100644 --- a/gcc/loop-iv.c +++ b/gcc/loop-iv.c @@ -1737,9 +1737,7 @@ simplify_using_initial_values (struct loop *loop, enum rtx_code op, rtx *expr) insn = BB_END (e->src); if (any_condjump_p (insn)) { - /* FIXME -- slightly wrong -- what if compared register - gets altered between start of the condition and insn? */ - rtx cond = get_condition (BB_END (e->src), NULL, false); + rtx cond = get_condition (BB_END (e->src), NULL, false, true); if (cond && (e->flags & EDGE_FALLTHRU)) cond = reversed_condition (cond); @@ -2472,7 +2470,7 @@ check_simple_exit (struct loop *loop, edge e, struct niter_desc *desc) desc->in_edge = ei; /* Test whether the condition is suitable. */ - if (!(condition = get_condition (BB_END (ei->src), &at, false))) + if (!(condition = get_condition (BB_END (ei->src), &at, false, false))) return; if (ei->flags & EDGE_FALLTHRU) |