OSDN Git Service

gcc/fortran:
[pf3gnuchains/gcc-fork.git] / gcc / tree-optimize.c
index 06adb45..c9f24cb 100644 (file)
@@ -208,13 +208,10 @@ struct tree_opt_pass pass_cleanup_cfg_post_optimizing =
 static unsigned int
 execute_free_datastructures (void)
 {
-  /* ??? This isn't the right place for this.  Worse, it got computed
-     more or less at random in various passes.  */
   free_dominance_info (CDI_DOMINATORS);
   free_dominance_info (CDI_POST_DOMINATORS);
 
-  /* Remove the ssa structures.  Do it here since this includes statement
-     annotations that need to be intact during disband_implicit_edges.  */
+  /* Remove the ssa structures.  */
   if (cfun->gimple_df)
     delete_tree_ssa ();
   return 0;
@@ -241,9 +238,6 @@ struct tree_opt_pass pass_free_datastructures =
 static unsigned int
 execute_free_cfg_annotations (void)
 {
-  /* Emit gotos for implicit jumps.  */
-  disband_implicit_edges ();
-
   /* And get rid of annotations we no longer need.  */
   delete_tree_cfg_annotations ();
 
@@ -267,25 +261,9 @@ struct tree_opt_pass pass_free_cfg_annotations =
   0                                    /* letter */
 };
 
-/* Return true if BB has at least one abnormal outgoing edge.  */
-
-static inline bool
-has_abnormal_outgoing_edge_p (basic_block bb)
-{
-  edge e;
-  edge_iterator ei;
-
-  FOR_EACH_EDGE (e, ei, bb->succs)
-    if (e->flags & EDGE_ABNORMAL)
-      return true;
-
-  return false;
-}
-
 /* Pass: fixup_cfg.  IPA passes, compilation of earlier functions or inlining
-   might have changed some properties, such as marked functions nothrow or
-   added calls that can potentially go to non-local labels.  Remove redundant
-   edges and basic blocks, and create new ones if necessary.
+   might have changed some properties, such as marked functions nothrow.
+   Remove redundant edges and basic blocks, and create new ones if necessary.
 
    This pass can't be executed as stand alone pass from pass manager, because
    in between inlining and this fixup the verify_flow_info would fail.  */
@@ -327,53 +305,6 @@ execute_fixup_cfg (void)
           todo |= TODO_cleanup_cfg;
       }
 
-  if (current_function_has_nonlocal_label)
-    {
-      FOR_EACH_BB (bb)
-       {
-         for (bsi = bsi_start (bb); !bsi_end_p (bsi); bsi_next (&bsi))
-           {
-             tree stmt = bsi_stmt (bsi);
-             if (tree_can_make_abnormal_goto (stmt))
-               {
-                 if (stmt == bsi_stmt (bsi_last (bb)))
-                   {
-                     if (!has_abnormal_outgoing_edge_p (bb))
-                       make_abnormal_goto_edges (bb, true);
-                   }
-                 else
-                   {
-                     edge e = split_block (bb, stmt);
-                     bb = e->src;
-                     make_abnormal_goto_edges (bb, true);
-                   }
-                 break;
-               }
-
-             /* Update PHIs on nonlocal goto receivers we (possibly)
-                just created new edges into.  */
-             if (TREE_CODE (stmt) == LABEL_EXPR
-                 && gimple_in_ssa_p (cfun))
-               {
-                 tree target = LABEL_EXPR_LABEL (stmt);
-                 if (DECL_NONLOCAL (target))
-                   {
-                     tree phi;
-
-                     for (phi = phi_nodes (bb); phi; phi = PHI_CHAIN (phi))
-                       {
-                         todo |= TODO_update_ssa | TODO_cleanup_cfg;
-                         gcc_assert (SSA_NAME_OCCURS_IN_ABNORMAL_PHI
-                                     (PHI_RESULT (phi)));
-                         mark_sym_for_renaming
-                           (SSA_NAME_VAR (PHI_RESULT (phi)));
-                       }
-                   }
-               }
-           }
-       }
-    }
-
   /* Dump a textual representation of the flowgraph.  */
   if (dump_file)
     dump_tree_cfg (dump_file, dump_flags);