diff options
author | Jan Hubicka <jh@suse.cz> | 2004-01-12 17:32:12 +0100 |
---|---|---|
committer | Jan Hubicka <hubicka@gcc.gnu.org> | 2004-01-12 16:32:12 +0000 |
commit | 432f982f5c2f65daa1d65a9af2fbfc585c88f114 (patch) | |
tree | 7bcdf745057a80c4e44eb2fff2033e874e50eea6 /gcc/cfgrtl.c | |
parent | 9a249c79b355459f3623cfbf8c0f2f6925d1a280 (diff) | |
download | gcc-432f982f5c2f65daa1d65a9af2fbfc585c88f114.zip gcc-432f982f5c2f65daa1d65a9af2fbfc585c88f114.tar.gz gcc-432f982f5c2f65daa1d65a9af2fbfc585c88f114.tar.bz2 |
re PR rtl-optimization/12826 (Optimizer removes reference through volatile pointer)
PR opt/12826
* loop.c (insert_loop_mem): Preffer VOLATILE memory references to be
stored.
PR opt/12863
* cfgcleanup.c (label_is_jump_target_p): Move to...
* rtlanal.c (label_is_jump_target_p): ... here.
* cfgrtl.c (cfg_layout_redirect_edge_and_branch): Fix redirecting of fallthru
edges unified with branch edges.
From-SVN: r75733
Diffstat (limited to 'gcc/cfgrtl.c')
-rw-r--r-- | gcc/cfgrtl.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/gcc/cfgrtl.c b/gcc/cfgrtl.c index c44d252..7839d5b 100644 --- a/gcc/cfgrtl.c +++ b/gcc/cfgrtl.c @@ -2463,10 +2463,18 @@ cfg_layout_redirect_edge_and_branch (edge e, basic_block dest) { /* Redirect any branch edges unified with the fallthru one. */ if (GET_CODE (BB_END (src)) == JUMP_INSN - && JUMP_LABEL (BB_END (src)) == BB_HEAD (e->dest)) + && label_is_jump_target_p (BB_HEAD (e->dest), + BB_END (src))) { - if (!redirect_jump (BB_END (src), block_label (dest), 0)) + if (rtl_dump_file) + fprintf (rtl_dump_file, "Fallthru edge unified with branch " + "%i->%i redirected to %i\n", + e->src->index, e->dest->index, dest->index); + e->flags &= ~EDGE_FALLTHRU; + if (!redirect_branch_edge (e, dest)) abort (); + e->flags |= EDGE_FALLTHRU; + return true; } /* In case we are redirecting fallthru edge to the branch edge of conditional jump, remove it. */ |