toplev.c (rest_of_compilation): Delay sibcall optimization until after emit_eh_context.
authorRichard Henderson <rth@cygnus.com>
Tue, 25 Apr 2000 10:13:17 +0000 (03:13 -0700)
committerRichard Henderson <rth@gcc.gnu.org>
Tue, 25 Apr 2000 10:13:17 +0000 (03:13 -0700)
        * toplev.c (rest_of_compilation): Delay sibcall optimization
        until after emit_eh_context.

From-SVN: r33407

gcc/ChangeLog
gcc/toplev.c

index 52404788b873d1c49c52e9c962e8a107dc119318..8ee7fd29f7a8620622dc490531551d3e27bdb368 100644 (file)
@@ -1,3 +1,8 @@
+2000-04-25  Richard Henderson  <rth@cygnus.com>
+
+       * toplev.c (rest_of_compilation): Delay sibcall optimization
+       until after emit_eh_context.
+
 2000-04-24  Nick Clifton  <nickc@redhat.com>
 
        * combine.c (combine_instructions): Do not try to combine a
index 17e8ebc6849b200bb9d3ae7ab7df0c0ea9087b9c..b479c8443c172c75e951d1ab1e82c5280b45b6f2 100644 (file)
@@ -2897,16 +2897,6 @@ rest_of_compilation (decl)
 
   init_EXPR_INSN_LIST_cache ();
 
-  /* We may have potential sibling or tail recursion sites.  Select one
-     (of possibly multiple) methods of performing the call.  */
-  open_dump_file (DFI_sibling, decl);
-  TIMEVAR (jump_time,
-          {
-            if (flag_optimize_sibling_calls)
-              optimize_sibling_and_tail_recursive_calls ();
-          });
-  close_dump_file (DFI_sibling, print_rtl, get_insns ());
-  
   if (ggc_p)
     ggc_collect ();
 
@@ -2928,6 +2918,17 @@ rest_of_compilation (decl)
   /* Emit code to get eh context, if needed. */
   emit_eh_context ();
 
+  /* We may have potential sibling or tail recursion sites.  Select one
+     (of possibly multiple) methods of performing the call.  */
+  if (flag_optimize_sibling_calls)
+    {
+      open_dump_file (DFI_sibling, decl);
+
+      TIMEVAR (jump_time, optimize_sibling_and_tail_recursive_calls ());
+
+      close_dump_file (DFI_sibling, print_rtl, get_insns ());
+    }
+  
 #ifdef FINALIZE_PIC
   /* If we are doing position-independent code generation, now
      is the time to output special prologues and epilogues.