Commit 7d8405cf by Richard Henderson Committed by Richard Henderson

* cfg.c (dump_flow_info): Skip register dump if reg_n_info null.

From-SVN: r71485
parent dc5f3d7c
2003-09-17 Richard Henderson <rth@redhat.com>
* cfg.c (dump_flow_info): Skip register dump if reg_n_info null.
2003-09-17 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE> 2003-09-17 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
* configure.in (gcc_cv_ld_hidden): Don't test gnu_ld_flag. * configure.in (gcc_cv_ld_hidden): Don't test gnu_ld_flag.
......
...@@ -491,48 +491,49 @@ dump_flow_info (FILE *file) ...@@ -491,48 +491,49 @@ dump_flow_info (FILE *file)
static const char * const reg_class_names[] = REG_CLASS_NAMES; static const char * const reg_class_names[] = REG_CLASS_NAMES;
fprintf (file, "%d registers.\n", max_regno); fprintf (file, "%d registers.\n", max_regno);
for (i = FIRST_PSEUDO_REGISTER; i < max_regno; i++) if (reg_n_info)
if (REG_N_REFS (i)) for (i = FIRST_PSEUDO_REGISTER; i < max_regno; i++)
{ if (REG_N_REFS (i))
enum reg_class class, altclass; {
enum reg_class class, altclass;
fprintf (file, "\nRegister %d used %d times across %d insns",
i, REG_N_REFS (i), REG_LIVE_LENGTH (i)); fprintf (file, "\nRegister %d used %d times across %d insns",
if (REG_BASIC_BLOCK (i) >= 0) i, REG_N_REFS (i), REG_LIVE_LENGTH (i));
fprintf (file, " in block %d", REG_BASIC_BLOCK (i)); if (REG_BASIC_BLOCK (i) >= 0)
if (REG_N_SETS (i)) fprintf (file, " in block %d", REG_BASIC_BLOCK (i));
fprintf (file, "; set %d time%s", REG_N_SETS (i), if (REG_N_SETS (i))
(REG_N_SETS (i) == 1) ? "" : "s"); fprintf (file, "; set %d time%s", REG_N_SETS (i),
if (regno_reg_rtx[i] != NULL && REG_USERVAR_P (regno_reg_rtx[i])) (REG_N_SETS (i) == 1) ? "" : "s");
fprintf (file, "; user var"); if (regno_reg_rtx[i] != NULL && REG_USERVAR_P (regno_reg_rtx[i]))
if (REG_N_DEATHS (i) != 1) fprintf (file, "; user var");
fprintf (file, "; dies in %d places", REG_N_DEATHS (i)); if (REG_N_DEATHS (i) != 1)
if (REG_N_CALLS_CROSSED (i) == 1) fprintf (file, "; dies in %d places", REG_N_DEATHS (i));
fprintf (file, "; crosses 1 call"); if (REG_N_CALLS_CROSSED (i) == 1)
else if (REG_N_CALLS_CROSSED (i)) fprintf (file, "; crosses 1 call");
fprintf (file, "; crosses %d calls", REG_N_CALLS_CROSSED (i)); else if (REG_N_CALLS_CROSSED (i))
if (regno_reg_rtx[i] != NULL fprintf (file, "; crosses %d calls", REG_N_CALLS_CROSSED (i));
&& PSEUDO_REGNO_BYTES (i) != UNITS_PER_WORD) if (regno_reg_rtx[i] != NULL
fprintf (file, "; %d bytes", PSEUDO_REGNO_BYTES (i)); && PSEUDO_REGNO_BYTES (i) != UNITS_PER_WORD)
fprintf (file, "; %d bytes", PSEUDO_REGNO_BYTES (i));
class = reg_preferred_class (i);
altclass = reg_alternate_class (i); class = reg_preferred_class (i);
if (class != GENERAL_REGS || altclass != ALL_REGS) altclass = reg_alternate_class (i);
{ if (class != GENERAL_REGS || altclass != ALL_REGS)
if (altclass == ALL_REGS || class == ALL_REGS) {
fprintf (file, "; pref %s", reg_class_names[(int) class]); if (altclass == ALL_REGS || class == ALL_REGS)
else if (altclass == NO_REGS) fprintf (file, "; pref %s", reg_class_names[(int) class]);
fprintf (file, "; %s or none", reg_class_names[(int) class]); else if (altclass == NO_REGS)
else fprintf (file, "; %s or none", reg_class_names[(int) class]);
fprintf (file, "; pref %s, else %s", else
reg_class_names[(int) class], fprintf (file, "; pref %s, else %s",
reg_class_names[(int) altclass]); reg_class_names[(int) class],
} reg_class_names[(int) altclass]);
}
if (regno_reg_rtx[i] != NULL && REG_POINTER (regno_reg_rtx[i])) if (regno_reg_rtx[i] != NULL && REG_POINTER (regno_reg_rtx[i]))
fprintf (file, "; pointer"); fprintf (file, "; pointer");
fprintf (file, ".\n"); fprintf (file, ".\n");
} }
fprintf (file, "\n%d basic blocks, %d edges.\n", n_basic_blocks, n_edges); fprintf (file, "\n%d basic blocks, %d edges.\n", n_basic_blocks, n_edges);
FOR_EACH_BB (bb) FOR_EACH_BB (bb)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment