return false;
}
+ basic_block dest = single_succ_edge (bb)->dest;
+
/* Now walk through the statements backward. We can ignore labels,
anything else means this is not a forwarder block. */
for (gsi = gsi_last_bb (bb); !gsi_end_p (gsi); gsi_prev (&gsi))
switch (gimple_code (stmt))
{
case GIMPLE_LABEL:
- if (DECL_NONLOCAL (gimple_label_label (as_a <glabel *> (stmt))))
+ if (DECL_NONLOCAL (gimple_label_label (as_a <glabel *> (stmt)))
+ || EH_LANDING_PAD_NR (gimple_label_label (as_a <glabel *> (stmt))))
return false;
if (!optimize
&& (gimple_has_location (stmt)
if (current_loops)
{
- basic_block dest;
/* Protect loop headers. */
if (bb_loop_header_p (bb))
return false;
- dest = EDGE_SUCC (bb, 0)->dest;
/* Protect loop preheaders and latches if requested. */
if (dest->loop_father->header == dest)
{
edge_iterator ei;
gimple_stmt_iterator gsi, gsi_to;
- /* If the destination block consists of a nonlocal label or is a
- EH landing pad, do not merge it. */
- stmt = first_stmt (dest);
- if (stmt)
- if (glabel *label_stmt = dyn_cast <glabel *> (stmt))
- if (DECL_NONLOCAL (gimple_label_label (label_stmt))
- || EH_LANDING_PAD_NR (gimple_label_label (label_stmt)) != 0)
- return false;
-
/* If there is an abnormal edge to basic block BB, but not into
dest, problems might occur during removal of the phi node at out
of ssa due to overlapping live ranges of registers.
{
edge succ = single_succ_edge (bb);
basic_block dest = succ->dest;
- gimple *label;
basic_block dombb, domdest, dom;
- /* If the destination block consists of a nonlocal label, do not
- merge it. */
- label = first_stmt (dest);
- if (label)
- if (glabel *label_stmt = dyn_cast <glabel *> (label))
- if (DECL_NONLOCAL (gimple_label_label (label_stmt)))
- return false;
-
/* Record BB's single pred in case we need to update the father
loop's latch information later. */
basic_block pred = NULL;