+ {
+ /* Speed up the removal of blocks that don't
+ dominate others. Walking backwards, this should
+ be the common case. ??? Do we need to recompute
+ dominators because of cfg_altered? */
+ if (!MAY_HAVE_DEBUG_STMTS
+ || !first_dom_son (CDI_DOMINATORS, bb))
+ delete_basic_block (bb);
+ else
+ {
+ h = get_all_dominated_blocks (CDI_DOMINATORS, bb);
+
+ while (VEC_length (basic_block, h))
+ {
+ bb = VEC_pop (basic_block, h);
+ prev_bb = bb->prev_bb;
+ /* Rearrangements to the CFG may have failed
+ to update the dominators tree, so that
+ formerly-dominated blocks are now
+ otherwise reachable. */
+ if (!!(bb->flags & BB_REACHABLE))
+ continue;
+ delete_basic_block (bb);
+ }
+
+ VEC_free (basic_block, heap, h);
+ }
+ }