Commit 778f72f2 by Roger Sayle Committed by Roger Sayle

harg-reg-set.h (reg_class_names): Prototype global array.


	* harg-reg-set.h (reg_class_names): Prototype global array.
	* regclass.c (reg_class_names): Declare here and initialize to
	REG_CLASS_NAMES.
	(dump_regclass): Remove local declaration of reg_class_names.
	(regclass): Likewise.
	* cfg.c (dump_flow_info): Likewise.
	* ra-debug.c (reg_class_names): Likewise.
	* regrename.c (reg_class_names): Likewise.
	* reload.c (reg_class_names): Likewise.
	* reload1.c (spill_failure): Likewise.
	* config/m68hc11/m68hc11.c (reg_class_names): Likewise.

From-SVN: r93696
parent 9c3c3dcc
2004-01-15 Roger Sayle <roger@eyesopen.com>
* harg-reg-set.h (reg_class_names): Prototype global array.
* regclass.c (reg_class_names): Declare here and initialize to
REG_CLASS_NAMES.
(dump_regclass): Remove local declaration of reg_class_names.
(regclass): Likewise.
* cfg.c (dump_flow_info): Likewise.
* ra-debug.c (reg_class_names): Likewise.
* regrename.c (reg_class_names): Likewise.
* reload.c (reg_class_names): Likewise.
* reload1.c (spill_failure): Likewise.
* config/m68hc11/m68hc11.c (reg_class_names): Likewise.
2005-01-15 Ulrich Weigand <uweigand@de.ibm.com> 2005-01-15 Ulrich Weigand <uweigand@de.ibm.com>
* config/s390/s390.md ("reload_outti"): Remove predicate for * config/s390/s390.md ("reload_outti"): Remove predicate for
......
/* Control flow graph manipulation code for GNU compiler. /* Control flow graph manipulation code for GNU compiler.
Copyright (C) 1987, 1988, 1992, 1993, 1994, 1995, 1996, 1997, 1998, Copyright (C) 1987, 1988, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc. 1999, 2000, 2001, 2002, 2003, 2004, 2005
Free Software Foundation, Inc.
This file is part of GCC. This file is part of GCC.
...@@ -515,7 +516,6 @@ dump_flow_info (FILE *file) ...@@ -515,7 +516,6 @@ dump_flow_info (FILE *file)
{ {
int i; int i;
basic_block bb; basic_block bb;
static const char * const reg_class_names[] = REG_CLASS_NAMES;
/* There are no pseudo registers after reload. Don't dump them. */ /* There are no pseudo registers after reload. Don't dump them. */
if (reg_n_info && !reload_completed) if (reg_n_info && !reload_completed)
......
/* Subroutines for code generation on Motorola 68HC11 and 68HC12. /* Subroutines for code generation on Motorola 68HC11 and 68HC12.
Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004 Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005
Free Software Foundation, Inc. Free Software Foundation, Inc.
Contributed by Stephane Carrez (stcarrez@nerim.fr) Contributed by Stephane Carrez (stcarrez@nerim.fr)
...@@ -387,8 +387,6 @@ m68hc11_conditional_register_usage (void) ...@@ -387,8 +387,6 @@ m68hc11_conditional_register_usage (void)
/* Reload and register operations. */ /* Reload and register operations. */
static const char *const reg_class_names[] = REG_CLASS_NAMES;
void void
create_regs_rtx (void) create_regs_rtx (void)
......
/* Sets (bit vectors) of hard registers, and operations on them. /* Sets (bit vectors) of hard registers, and operations on them.
Copyright (C) 1987, 1992, 1994, 2000, 2003, 2004 Copyright (C) 1987, 1992, 1994, 2000, 2003, 2004, 2005
Free Software Foundation, Inc. Free Software Foundation, Inc.
This file is part of GCC This file is part of GCC
...@@ -490,6 +490,10 @@ extern int n_non_fixed_regs; ...@@ -490,6 +490,10 @@ extern int n_non_fixed_regs;
extern const char * reg_names[FIRST_PSEUDO_REGISTER]; extern const char * reg_names[FIRST_PSEUDO_REGISTER];
/* Vector indexed by reg class giving its name. */
extern const char * reg_class_names[];
/* Given a hard REGN a FROM mode and a TO mode, return nonzero if /* Given a hard REGN a FROM mode and a TO mode, return nonzero if
REGN cannot change modes between the specified modes. */ REGN cannot change modes between the specified modes. */
#define REG_CANNOT_CHANGE_MODE_P(REGN, FROM, TO) \ #define REG_CANNOT_CHANGE_MODE_P(REGN, FROM, TO) \
......
/* Graph coloring register allocator /* Graph coloring register allocator
Copyright (C) 2001, 2002, 2004 Free Software Foundation, Inc. Copyright (C) 2001, 2002, 2004, 2005 Free Software Foundation, Inc.
Contributed by Michael Matz <matz@suse.de> Contributed by Michael Matz <matz@suse.de>
and Daniel Berlin <dan@cgsoftware.com>. and Daniel Berlin <dan@cgsoftware.com>.
...@@ -41,9 +41,6 @@ static void ra_print_rtx_2op (FILE *, rtx); ...@@ -41,9 +41,6 @@ static void ra_print_rtx_2op (FILE *, rtx);
static void ra_print_rtx_3op (FILE *, rtx); static void ra_print_rtx_3op (FILE *, rtx);
static void ra_print_rtx_object (FILE *, rtx); static void ra_print_rtx_object (FILE *, rtx);
/* The hardregs as names, for debugging. */
static const char *const reg_class_names[] = REG_CLASS_NAMES;
/* Print a message to the dump file, if debug_new_regalloc and LEVEL /* Print a message to the dump file, if debug_new_regalloc and LEVEL
have any bits in common. */ have any bits in common. */
......
/* Compute register class preferences for pseudo-registers. /* Compute register class preferences for pseudo-registers.
Copyright (C) 1987, 1988, 1991, 1992, 1993, 1994, 1995, 1996 Copyright (C) 1987, 1988, 1991, 1992, 1993, 1994, 1995, 1996
1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005
Free Software Foundation, Inc. Free Software Foundation, Inc.
This file is part of GCC. This file is part of GCC.
...@@ -192,6 +192,10 @@ enum reg_class reg_class_superunion[N_REG_CLASSES][N_REG_CLASSES]; ...@@ -192,6 +192,10 @@ enum reg_class reg_class_superunion[N_REG_CLASSES][N_REG_CLASSES];
const char * reg_names[] = REGISTER_NAMES; const char * reg_names[] = REGISTER_NAMES;
/* Array containing all of the register class names. */
const char * reg_class_names[] = REG_CLASS_NAMES;
/* For each hard register, the widest mode object that it can contain. /* For each hard register, the widest mode object that it can contain.
This will be a MODE_INT mode if the register can hold integers. Otherwise This will be a MODE_INT mode if the register can hold integers. Otherwise
it will be a MODE_FLOAT or a MODE_CC mode, whichever is valid for the it will be a MODE_FLOAT or a MODE_CC mode, whichever is valid for the
...@@ -925,7 +929,6 @@ regclass_init (void) ...@@ -925,7 +929,6 @@ regclass_init (void)
static void static void
dump_regclass (FILE *dump) dump_regclass (FILE *dump)
{ {
static const char *const reg_class_names[] = REG_CLASS_NAMES;
int i; int i;
for (i = FIRST_PSEUDO_REGISTER; i < max_regno; i++) for (i = FIRST_PSEUDO_REGISTER; i < max_regno; i++)
{ {
...@@ -1348,7 +1351,6 @@ regclass (rtx f, int nregs, FILE *dump) ...@@ -1348,7 +1351,6 @@ regclass (rtx f, int nregs, FILE *dump)
&& (reg_pref[i].prefclass != (int) best && (reg_pref[i].prefclass != (int) best
|| reg_pref[i].altclass != (int) alt)) || reg_pref[i].altclass != (int) alt))
{ {
static const char *const reg_class_names[] = REG_CLASS_NAMES;
fprintf (dump, " Register %i", i); fprintf (dump, " Register %i", i);
if (alt == ALL_REGS || best == ALL_REGS) if (alt == ALL_REGS || best == ALL_REGS)
fprintf (dump, " pref %s\n", reg_class_names[(int) best]); fprintf (dump, " pref %s\n", reg_class_names[(int) best]);
......
/* Register renaming for the GNU compiler. /* Register renaming for the GNU compiler.
Copyright (C) 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc. Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005
Free Software Foundation, Inc.
This file is part of GCC. This file is part of GCC.
...@@ -36,8 +37,6 @@ ...@@ -36,8 +37,6 @@
#include "toplev.h" #include "toplev.h"
#include "obstack.h" #include "obstack.h"
static const char *const reg_class_names[] = REG_CLASS_NAMES;
struct du_chain struct du_chain
{ {
struct du_chain *next_chain; struct du_chain *next_chain;
......
/* Search an insn for pseudo regs that must be in hard regs and are not. /* Search an insn for pseudo regs that must be in hard regs and are not.
Copyright (C) 1987, 1988, 1989, 1992, 1993, 1994, 1995, 1996, 1997, 1998, Copyright (C) 1987, 1988, 1989, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc. 1999, 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
This file is part of GCC. This file is part of GCC.
...@@ -7017,8 +7017,6 @@ static const char *const reload_when_needed_name[] = ...@@ -7017,8 +7017,6 @@ static const char *const reload_when_needed_name[] =
"RELOAD_FOR_OTHER_ADDRESS" "RELOAD_FOR_OTHER_ADDRESS"
}; };
static const char * const reg_class_names[] = REG_CLASS_NAMES;
/* These functions are used to print the variables set by 'find_reloads' */ /* These functions are used to print the variables set by 'find_reloads' */
void void
......
...@@ -1861,7 +1861,6 @@ delete_caller_save_insns (void) ...@@ -1861,7 +1861,6 @@ delete_caller_save_insns (void)
static void static void
spill_failure (rtx insn, enum reg_class class) spill_failure (rtx insn, enum reg_class class)
{ {
static const char *const reg_class_names[] = REG_CLASS_NAMES;
if (asm_noperands (PATTERN (insn)) >= 0) if (asm_noperands (PATTERN (insn)) >= 0)
error_for_asm (insn, "can't find a register in class %qs while " error_for_asm (insn, "can't find a register in class %qs while "
"reloading %<asm%>", "reloading %<asm%>",
......
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