aboutsummaryrefslogtreecommitdiff
path: root/gcc/cfgcleanup.c
diff options
context:
space:
mode:
authorJan Hubicka <jh@suse.cz>2001-09-11 11:39:11 +0200
committerJan Hubicka <hubicka@gcc.gnu.org>2001-09-11 09:39:11 +0000
commit7ded4467c9ee286111320967832db758d71acf4c (patch)
tree0b80eab87a8ff974cac08543ff1bb4f76eff3798 /gcc/cfgcleanup.c
parent30102605e710a95f8cb00ddd14303d7fcc284fae (diff)
downloadgcc-7ded4467c9ee286111320967832db758d71acf4c.zip
gcc-7ded4467c9ee286111320967832db758d71acf4c.tar.gz
gcc-7ded4467c9ee286111320967832db758d71acf4c.tar.bz2
basic-block.h (cached_make_edge, [...]): New.
* basic-block.h (cached_make_edge, make_single_succ): New. (make_edge): Remove first parameter. * bb-reroder.c (fixup_reorder_chain): Use make_single_succ_edge. * cfg.c (cached_make_edge): Rename from make_edge; return newly created edge; use obstack allocation. (make_edge, make_single_succ_edge): New. (first_removed_edge): New static variable. (init_flow): Initialize first_removed_edge and n_edges. (clear_edges): Use remove_edge. (flow_delete_block): Likewise. (remove_edge): Add removed edges to the removed edges list. (split_block, redirect_edge_and_branch_force, split_edge): Use make_edge. * cfganal.c (flow_call_edges_add): Updaet make_edge call. (add_noreturn_fake_exit_edges): Likewise. (connect_infinite_loops_to_exit): Liekwise. * cfgbuild.c (make_label_edge, make_edges, find_sub_basic_blocks): Use cached_make_edge. * cfgcleanup.c (try_crossjump_to_edge): Use make_single_succ_edge. * profile.c (branch_prob): Update make_edge call. * ssa-dce.c (ssa_eliminate_dead_code): Likewise. From-SVN: r45540
Diffstat (limited to 'gcc/cfgcleanup.c')
-rw-r--r--gcc/cfgcleanup.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/gcc/cfgcleanup.c b/gcc/cfgcleanup.c
index 00eb80a..4413c02 100644
--- a/gcc/cfgcleanup.c
+++ b/gcc/cfgcleanup.c
@@ -941,9 +941,7 @@ try_crossjump_to_edge (mode, e1, e2)
/* Update CFG. */
while (src1->succ)
remove_edge (src1->succ);
- make_edge (NULL, src1, redirect_to, 0);
- src1->succ->probability = REG_BR_PROB_BASE;
- src1->succ->count = src1->count;
+ make_single_succ_edge (src1, redirect_to, 0);
return true;
}