aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-ssa-threadupdate.c
diff options
context:
space:
mode:
authorEric Botcazou <ebotcazou@libertysurf.fr>2007-11-07 23:05:37 +0100
committerEric Botcazou <ebotcazou@gcc.gnu.org>2007-11-07 22:05:37 +0000
commit52982a970e03e299950638b623243d7724aa8962 (patch)
tree3b09819b82398b3577c387dc732255b7f014c8d4 /gcc/tree-ssa-threadupdate.c
parent8c6c36a3c9583d2e804edd181c75e076a4f38b3e (diff)
downloadgcc-52982a970e03e299950638b623243d7724aa8962.zip
gcc-52982a970e03e299950638b623243d7724aa8962.tar.gz
gcc-52982a970e03e299950638b623243d7724aa8962.tar.bz2
re PR rtl-optimization/33737 (verify_flow_info failed: Wrong probability of edge 94->1 -6651)
PR rtl-optimization/33737 * cfgcleanup.c (try_crossjump_to_edge): Add count and frequency of target block after computing the probabilities of outgoing edges. Cap the frequency to BB_FREQ_MAX. * tree-ssa-threadupdate.c (redirect_edges): Also adjust count and frequency of the basic block if it has been reused. From-SVN: r129973
Diffstat (limited to 'gcc/tree-ssa-threadupdate.c')
-rw-r--r--gcc/tree-ssa-threadupdate.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/gcc/tree-ssa-threadupdate.c b/gcc/tree-ssa-threadupdate.c
index 1d5500f..fe3876e 100644
--- a/gcc/tree-ssa-threadupdate.c
+++ b/gcc/tree-ssa-threadupdate.c
@@ -442,10 +442,14 @@ redirect_edges (void **slot, void *data)
remove_ctrl_stmt_and_useless_edges (local_info->bb,
rd->outgoing_edge->dest);
- /* And fixup the flags on the single remaining edge. */
+ /* Fixup the flags on the single remaining edge. */
single_succ_edge (local_info->bb)->flags
&= ~(EDGE_TRUE_VALUE | EDGE_FALSE_VALUE | EDGE_ABNORMAL);
single_succ_edge (local_info->bb)->flags |= EDGE_FALLTHRU;
+
+ /* And adjust count and frequency on BB. */
+ local_info->bb->count = e->count;
+ local_info->bb->frequency = EDGE_FREQUENCY (e);
}
}