summaryrefslogtreecommitdiff
path: root/gcc/tree-flow-inline.h
diff options
context:
space:
mode:
authorbonzini <bonzini@138bc75d-0d04-0410-961f-82ee72b054a4>2006-02-02 13:05:36 +0000
committerbonzini <bonzini@138bc75d-0d04-0410-961f-82ee72b054a4>2006-02-02 13:05:36 +0000
commit306d9c02ee0801d023909806fa094ff68a8578b8 (patch)
treee16c886c00e7c4c7bd7f6e4ba89378213ccc7f6a /gcc/tree-flow-inline.h
parent55d97af6b3edb27a7158cacef3149e71c81d7b4c (diff)
downloadgcc-306d9c02ee0801d023909806fa094ff68a8578b8.tar.gz
2006-02-02 Paolo Bonzini <bonzini@gnu.org>
* tree-flow-inline.h (bsi_after_labels): Rewrite, return what its name says. * lambda-code.c (perfect_nestify): Use bsi_insert_before on bsi_after_labels iterator. * tree-if-conv.c (find_phi_replacement_condition, replace_phi_with_cond_modify_expr): Likewise. * tree-scalar-evolution.c (scev_const_prop): Likewise. * tree-ssa-loop-ivopts.c (compute_phi_arg_on_exit): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@110514 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/tree-flow-inline.h')
-rw-r--r--gcc/tree-flow-inline.h30
1 files changed, 4 insertions, 26 deletions
diff --git a/gcc/tree-flow-inline.h b/gcc/tree-flow-inline.h
index 69bef68f9ac..0ae99b9f0d4 100644
--- a/gcc/tree-flow-inline.h
+++ b/gcc/tree-flow-inline.h
@@ -734,37 +734,15 @@ bsi_start (basic_block bb)
}
/* Return a block statement iterator that points to the first non-label
- block BB. */
+ statement in block BB. */
static inline block_stmt_iterator
bsi_after_labels (basic_block bb)
{
- block_stmt_iterator bsi;
- tree_stmt_iterator next;
-
- bsi.bb = bb;
-
- if (!bb->stmt_list)
- {
- gcc_assert (bb->index < NUM_FIXED_BLOCKS);
- bsi.tsi.ptr = NULL;
- bsi.tsi.container = NULL;
- return bsi;
- }
-
- bsi.tsi = tsi_start (bb->stmt_list);
- if (tsi_end_p (bsi.tsi))
- return bsi;
+ block_stmt_iterator bsi = bsi_start (bb);
- next = bsi.tsi;
- tsi_next (&next);
-
- while (!tsi_end_p (next)
- && TREE_CODE (tsi_stmt (next)) == LABEL_EXPR)
- {
- bsi.tsi = next;
- tsi_next (&next);
- }
+ while (!bsi_end_p (bsi) && TREE_CODE (bsi_stmt (bsi)) == LABEL_EXPR)
+ bsi_next (&bsi);
return bsi;
}