diff options
author | Paolo Bonzini <bonzini@gnu.org> | 2006-02-02 13:05:36 +0000 |
---|---|---|
committer | Paolo Bonzini <bonzini@gcc.gnu.org> | 2006-02-02 13:05:36 +0000 |
commit | 35771d345fbe800cb3769316ffe874909bccdc4b (patch) | |
tree | e16c886c00e7c4c7bd7f6e4ba89378213ccc7f6a /gcc/tree-flow-inline.h | |
parent | 8843c120f1f0a562b0250c59ec66317feae2fb0c (diff) | |
download | gcc-35771d345fbe800cb3769316ffe874909bccdc4b.zip gcc-35771d345fbe800cb3769316ffe874909bccdc4b.tar.gz gcc-35771d345fbe800cb3769316ffe874909bccdc4b.tar.bz2 |
tree-flow-inline.h (bsi_after_labels): Rewrite, return what its name says.
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.
From-SVN: r110514
Diffstat (limited to 'gcc/tree-flow-inline.h')
-rw-r--r-- | gcc/tree-flow-inline.h | 30 |
1 files changed, 4 insertions, 26 deletions
diff --git a/gcc/tree-flow-inline.h b/gcc/tree-flow-inline.h index 69bef68..0ae99b9 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; } |