OSDN Git Service

* cp-tree.h (struct tinst_level): Add chain_next GTY
[pf3gnuchains/gcc-fork.git] / gcc / final.c
index 17393b7..748042a 100644 (file)
@@ -83,6 +83,7 @@ along with GCC; see the file COPYING3.  If not see
 #include "ggc.h"
 #include "cfgloop.h"
 #include "params.h"
+#include "tree-pretty-print.h"
 
 #ifdef XCOFF_DEBUGGING_INFO
 #include "xcoffout.h"          /* Needed for external data
@@ -1691,14 +1692,14 @@ dump_basic_block_info (FILE *file, rtx insn, basic_block *start_to_bb,
       edge e;
       edge_iterator ei;
 
-      fprintf (file, "# BLOCK %d", bb->index);
+      fprintf (file, "%s BLOCK %d", ASM_COMMENT_START, bb->index);
       if (bb->frequency)
         fprintf (file, " freq:%d", bb->frequency);
       if (bb->count)
         fprintf (file, " count:" HOST_WIDEST_INT_PRINT_DEC,
                  bb->count);
       fprintf (file, " seq:%d", (*bb_seqn)++);
-      fprintf (file, "\n# PRED:");
+      fprintf (file, "\n%s PRED:", ASM_COMMENT_START);
       FOR_EACH_EDGE (e, ei, bb->preds)
         {
           dump_edge_info (file, e, 0);
@@ -1711,7 +1712,7 @@ dump_basic_block_info (FILE *file, rtx insn, basic_block *start_to_bb,
       edge e;
       edge_iterator ei;
 
-      fprintf (asm_out_file, "# SUCC:");
+      fprintf (asm_out_file, "%s SUCC:", ASM_COMMENT_START);
       FOR_EACH_EDGE (e, ei, bb->succs)
        {
          dump_edge_info (asm_out_file, e, 1);
@@ -2313,6 +2314,11 @@ final_scan_insn (rtx insn, FILE *file, int optimize_p ATTRIBUTE_UNUSED,
            location_t loc;
            expanded_location expanded;
 
+           /* Make sure we flush any queued register saves in case this
+              clobbers affected registers.  */
+           if (dwarf2out_do_frame ())
+             dwarf2out_frame_debug (insn, false);
+
            /* There's no telling what that did to the condition codes.  */
            CC_STATUS_INIT;
 
@@ -4355,23 +4361,11 @@ rest_of_clean_state (void)
        }
       else
        {
-         const char *aname;
-         struct cgraph_node *node = cgraph_node (current_function_decl);
-
-         aname = (IDENTIFIER_POINTER
-                  (DECL_ASSEMBLER_NAME (current_function_decl)));
-         fprintf (final_output, "\n;; Function (%s) %s\n\n", aname,
-            node->frequency == NODE_FREQUENCY_HOT
-            ? " (hot)"
-            : node->frequency == NODE_FREQUENCY_UNLIKELY_EXECUTED
-            ? " (unlikely executed)"
-            : node->frequency == NODE_FREQUENCY_EXECUTED_ONCE
-            ? " (executed once)"
-            : "");
-
          flag_dump_noaddr = flag_dump_unnumbered = 1;
          if (flag_compare_debug_opt || flag_compare_debug)
            dump_flags |= TDF_NOUID;
+         dump_function_header (final_output, current_function_decl,
+                               dump_flags);
          final_insns_dump_p = true;
 
          for (insn = get_insns (); insn; insn = NEXT_INSN (insn))