diff options
| author | Andrew MacLeod <amacleod@redhat.com> | 2004-11-03 18:56:35 +0000 | 
|---|---|---|
| committer | Andrew Macleod <amacleod@gcc.gnu.org> | 2004-11-03 18:56:35 +0000 | 
| commit | b00e4c238b56689ec1e81a647a0147bf9ff79306 (patch) | |
| tree | d5b2ead3bc25a2263a17eef69ace1e75f2503ab5 /gcc/tree-outof-ssa.c | |
| parent | a85a902471ec546f41cd2774c2a339354cc40a50 (diff) | |
| download | gcc-b00e4c238b56689ec1e81a647a0147bf9ff79306.zip gcc-b00e4c238b56689ec1e81a647a0147bf9ff79306.tar.gz gcc-b00e4c238b56689ec1e81a647a0147bf9ff79306.tar.bz2 | |
re PR tree-optimization/18270 (internal compiler error: in tree_redirect_edge_and_branch, at tree-cfg.c:4146)
2004-11-03  Andrew MacLeod  <amacleod@redhat.com>
	PR tree-optimization/18270
	* tree-outof-ssa.c (analyze_edges_for_bb): If a block has any incoming
	abnormal edges, simply commit any pending stmts on all incoming edges.
From-SVN: r90031
Diffstat (limited to 'gcc/tree-outof-ssa.c')
| -rw-r--r-- | gcc/tree-outof-ssa.c | 19 | 
1 files changed, 19 insertions, 0 deletions
| diff --git a/gcc/tree-outof-ssa.c b/gcc/tree-outof-ssa.c index 6d33c47..074ca5b 100644 --- a/gcc/tree-outof-ssa.c +++ b/gcc/tree-outof-ssa.c @@ -2024,6 +2024,25 @@ analyze_edges_for_bb (basic_block bb, FILE *debug_file)    bool is_label;    count = 0; + +  /* Blocks which contain at least one abnormal edge cannot use  +     make_forwarder_block.  Look for these blocks, and commit any PENDING_STMTs +     found on edges in these block.  */ +  have_opportunity = true; +  FOR_EACH_EDGE (e, ei, bb->preds) +    if (e->flags & EDGE_ABNORMAL) +      { +        have_opportunity = false; +	break; +      } + +  if (!have_opportunity) +    { +      FOR_EACH_EDGE (e, ei, bb->preds) +	if (PENDING_STMT (e)) +	  bsi_commit_one_edge_insert (e, NULL); +      return false; +    }    /* Find out how many edges there are with interesting pending stmts on them.         Commit the stmts on edges we are not interested in.  */    FOR_EACH_EDGE (e, ei, bb->preds) | 
