Commit 40fc4e6a by Jan Hubicka Committed by Jan Hubicka

flow.c (try_forward_edges): Accept fallthru edge; Update comment.

	* flow.c (try_forward_edges): Accept fallthru edge; Update comment.
	(try_crossjump_to_edge): Update commetns.
	(try_crossjump_bb): Likewise.

From-SVN: r44318
parent e7139885
Wed Jul 25 00:32:49 CEST 2001 Jan Hubicka <jh@suse.cz>
* flow.c (try_forward_edges): Accept fallthru edge; Update comment.
(try_crossjump_to_edge): Update commetns.
(try_crossjump_bb): Likewise.
2001-07-24 Richard Henderson <rth@redhat.com> 2001-07-24 Richard Henderson <rth@redhat.com>
* combine.c (distribute_notes): Move set of need_refresh * combine.c (distribute_notes): Move set of need_refresh
......
...@@ -3106,8 +3106,11 @@ try_forward_edges (b) ...@@ -3106,8 +3106,11 @@ try_forward_edges (b)
next = e->succ_next; next = e->succ_next;
/* Skip complex edges because we don't know how to update them. /* Skip complex edges because we don't know how to update them.
Skip fallthru edges because there's no jump to update. */
if (e->flags & (EDGE_COMPLEX | EDGE_FALLTHRU)) Still handle fallthru edges, as we can suceed to forward fallthru
edge to the same place as the branch edge of conditional branch
and turn conditional branch to an unconditonal branch. */
if (e->flags & EDGE_COMPLEX)
continue; continue;
target = first = e->dest; target = first = e->dest;
...@@ -3517,14 +3520,14 @@ try_crossjump_to_edge (mode, e1, e2) ...@@ -3517,14 +3520,14 @@ try_crossjump_to_edge (mode, e1, e2)
&& forwarder_block_p (e2->dest->succ->dest)) && forwarder_block_p (e2->dest->succ->dest))
return false; return false;
/* Likewise with dead code. */ /* Likewise with dead code (possibly newly created by the other optimizations
/* ??? Won't we have eliminated these by now? */ of cfg_cleanup). */
if (!src1->pred || !src2->pred) if (!src1->pred || !src2->pred)
return false; return false;
/* Likewise with non-jump edges. */ /* Likewise with complex edges.
/* ??? Non-jump? You mean GET_CODE (e1->src-end) != JUMP_INSN? ??? We should be able to handle most complex edges later with some
This fails for computed-goto as well, which may in fact be joinable. */ care. */
if (e1->flags & EDGE_COMPLEX) if (e1->flags & EDGE_COMPLEX)
return false; return false;
...@@ -3724,7 +3727,6 @@ try_crossjump_bb (mode, bb) ...@@ -3724,7 +3727,6 @@ try_crossjump_bb (mode, bb)
checks of crossjump(A,B). In order to prevent redundant checks of crossjump(A,B). In order to prevent redundant
checks of crossjump(B,A), require that A be the block checks of crossjump(B,A), require that A be the block
with the lowest index. */ with the lowest index. */
/* ??? Perhaps better is lowest execution frequency. */
if (e->src->index > e2->src->index) if (e->src->index > e2->src->index)
continue; continue;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment