OSDN Git Service

* config/i386/i386.c (legitimate_constant_p): Handle UNSPEC_NTPOFF
[pf3gnuchains/gcc-fork.git] / gcc / ra-debug.c
index 8daa63d..17d89b4 100644 (file)
@@ -20,6 +20,8 @@
 
 #include "config.h"
 #include "system.h"
+#include "coretypes.h"
+#include "tm.h"
 #include "rtl.h"
 #include "insn-config.h"
 #include "recog.h"
@@ -46,14 +48,14 @@ static const char *const reg_class_names[] = REG_CLASS_NAMES;
    have any bits in common.  */
 
 void
-ra_debug_msg VPARAMS ((unsigned int level, const char *format, ...))
+ra_debug_msg (unsigned int level, const char *format, ...)
 {
-  VA_OPEN (ap, format);
-  VA_FIXEDARG (ap, unsigned int, level);
-  VA_FIXEDARG (ap, const char *, format);
+  va_list ap;
+  
+  va_start (ap, format);
   if ((debug_new_regalloc & level) != 0 && rtl_dump_file != NULL)
     vfprintf (rtl_dump_file, format, ap);
-  VA_CLOSE (ap);
+  va_end (ap);
 }
 
 
@@ -666,7 +668,8 @@ dump_igraph (df)
   for (def1 = 0; def1 < num_webs; def1++)
     {
       int num1 = num;
-      for (num2=0, def2 = 0; def2 < num_webs; def2++)
+      num2 = 0;
+      for (def2 = 0; def2 < num_webs; def2++)
         if (def1 != def2 && TEST_BIT (igraph, igraph_index (def1, def2)))
          {
            if (num1 == num)
@@ -711,10 +714,10 @@ dump_igraph (df)
          ra_debug_msg (DUMP_WEBS, " sub %d", SUBREG_BYTE (web->orig_x));
          ra_debug_msg (DUMP_WEBS, " par %d", find_web_for_subweb (web)->id);
        }
-      ra_debug_msg (DUMP_WEBS, " +%d (span %d, cost ",
-                   web->add_hardregs, web->span_deaths);
-      ra_debug_msg (DUMP_WEBS, HOST_WIDE_INT_PRINT_DEC, web->spill_cost);
-      ra_debug_msg (DUMP_WEBS, ") (%s)", reg_class_names[web->regclass]);
+      ra_debug_msg (DUMP_WEBS, " +%d (span %d, cost "
+                   HOST_WIDE_INT_PRINT_DEC ") (%s)",
+                   web->add_hardregs, web->span_deaths, web->spill_cost,
+                   reg_class_names[web->regclass]);
       if (web->spill_temp == 1)
        ra_debug_msg (DUMP_WEBS, " (spilltemp)");
       else if (web->spill_temp == 2)
@@ -815,7 +818,7 @@ dump_constraints ()
        int uid = INSN_UID (insn);
        int o;
        /* Don't simply force rerecognition, as combine might left us
-          with some unrecongnizable ones, which later leads to aborts
+          with some unrecognizable ones, which later leads to aborts
           in regclass, if we now destroy the remembered INSN_CODE().  */
        /*INSN_CODE (insn) = -1;*/
        code = recog_memoized (insn);
@@ -867,9 +870,9 @@ dump_graph_cost (level, msg)
       if (alias (web)->type == SPILLED)
        cost += web->orig_spill_cost;
     }
-  ra_debug_msg (level, " spill cost of graph (%s) = ", msg ? msg : "");
-  ra_debug_msg (level, HOST_WIDE_INT_PRINT_UNSIGNED, cost);
-  ra_debug_msg (level, "\n");
+  ra_debug_msg (level, " spill cost of graph (%s) = "
+               HOST_WIDE_INT_PRINT_UNSIGNED "\n",
+               msg ? msg : "", cost);
 }
 
 /* Dump the color assignment per web, the coalesced and spilled webs.  */
@@ -982,21 +985,21 @@ dump_static_insn_cost (file, message, prefix)
   if (!prefix)
     prefix = "";
   fprintf (file, "static insn cost %s\n", message ? message : "");
-  fprintf (file, "  %soverall:\tnum=%6d\tcost=", prefix, overall.count);
-  fprintf (file, HOST_WIDE_INT_PRINT_DEC_SPACE, 8, overall.cost);
-  fprintf (file, "\n");
-  fprintf (file, "  %sloads:\tnum=%6d\tcost=", prefix, load.count);
-  fprintf (file, HOST_WIDE_INT_PRINT_DEC_SPACE, 8, load.cost);
-  fprintf (file, "\n");
-  fprintf (file, "  %sstores:\tnum=%6d\tcost=", prefix, store.count);
-  fprintf (file, HOST_WIDE_INT_PRINT_DEC_SPACE, 8, store.cost);
-  fprintf (file, "\n");
-  fprintf (file, "  %sregcopy:\tnum=%6d\tcost=", prefix, regcopy.count);
-  fprintf (file, HOST_WIDE_INT_PRINT_DEC_SPACE, 8, regcopy.cost);
-  fprintf (file, "\n");
-  fprintf (file, "  %sselfcpy:\tnum=%6d\tcost=", prefix, selfcopy.count);
-  fprintf (file, HOST_WIDE_INT_PRINT_DEC_SPACE, 8, selfcopy.cost);
-  fprintf (file, "\n");
+  fprintf (file, "  %soverall:\tnum=%6d\tcost="
+          HOST_WIDE_INT_PRINT_DEC_SPACE "\n",
+          prefix, overall.count, 8, overall.cost);
+  fprintf (file, "  %sloads:\tnum=%6d\tcost="
+          HOST_WIDE_INT_PRINT_DEC_SPACE "\n",
+          prefix, load.count, 8, load.cost);
+  fprintf (file, "  %sstores:\tnum=%6d\tcost="
+          HOST_WIDE_INT_PRINT_DEC_SPACE "\n",
+          prefix, store.count, 8, store.cost);
+  fprintf (file, "  %sregcopy:\tnum=%6d\tcost="
+          HOST_WIDE_INT_PRINT_DEC_SPACE "\n",
+          prefix, regcopy.count, 8, regcopy.cost);
+  fprintf (file, "  %sselfcpy:\tnum=%6d\tcost="
+          HOST_WIDE_INT_PRINT_DEC_SPACE "\n",
+          prefix, selfcopy.count, 8, selfcopy.cost);
 }
 
 /* Returns nonzero, if WEB1 and WEB2 have some possible
@@ -1105,7 +1108,7 @@ debug_hard_reg_set (set)
      HARD_REG_SET set;
 {
   int i;
-  for (i=0; i < FIRST_PSEUDO_REGISTER; ++i)
+  for (i = 0; i < FIRST_PSEUDO_REGISTER; ++i)
     {
       if (TEST_HARD_REG_BIT (set, i))
        {