aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStan Shebs <shebs@apple.com>2001-07-07 01:07:22 +0000
committerStan Shebs <shebs@apple.com>2001-07-07 01:07:22 +0000
commit02a47b08f81669df346ef06ac5ca3f6231160445 (patch)
treeef8e84e2bb302fc01ff8f0c9701e00ecd440d691
parent8cc8b2291eedc9e12710078481a739226f76e7d4 (diff)
* target.h (targetm): Rename global from "target", so as not to
conflict with local variables. * c-decl.c: Ditto. * c-typeck.c: Ditto. * final.c: Ditto. * tree.c: Ditto. * cp/decl.c: Ditto. * cp/decl2.c: Ditto. * cp/typeck.c: Ditto. * 1750a/1750a.c: Ditto. * a29k/a29k.c: Ditto. * arc/arc.c: Ditto. * arm/arm.c: Ditto. * avr/avr.c: Ditto. * clipper/clipper.c: Ditto. * convex/convex.c: Ditto. * d30v/d30v.c: Ditto. * dsp16xx/dsp16xx.c: Ditto. * elxsi/elxsi.c: Ditto. * fr30/fr30.c: Ditto. * h8300/h8300.c: Ditto. * i370/i370.c: Ditto. * i386/i386.c: Ditto. * i860/i860.c: Ditto. * i960/i960.c: Ditto. * ia64/ia64.c: Ditto. * m32r/m32r.c: Ditto. * m68hc11/m68hc11.c: Ditto. * m68k/m68k.c: Ditto. * m88k/m88k.c: Ditto. * mips/mips.c: Ditto. * ns32k/ns32k.c: Ditto. * pa/pa.c: Ditto. * pdp11/pdp11.c: Ditto. * romp/romp.c: Ditto. * rs6000/rs6000.c: Ditto. * sh/sh.c: Ditto. * sparc/sparc.c: Ditto. * vax/vax.c: Ditto. * we32k/we32k.c: Ditto. * doc/tm.texi: Update the manual to match. git-svn-id: https://gcc.gnu.org/svn/gcc/trunk@43831 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--gcc/ChangeLog44
-rw-r--r--gcc/c-decl.c2
-rw-r--r--gcc/c-typeck.c4
-rw-r--r--gcc/config/1750a/1750a.c2
-rw-r--r--gcc/config/a29k/a29k.c2
-rw-r--r--gcc/config/alpha/alpha.c2
-rw-r--r--gcc/config/arc/arc.c2
-rw-r--r--gcc/config/arm/arm.c2
-rw-r--r--gcc/config/avr/avr.c2
-rw-r--r--gcc/config/c4x/c4x.c2
-rw-r--r--gcc/config/clipper/clipper.c2
-rw-r--r--gcc/config/convex/convex.c2
-rw-r--r--gcc/config/d30v/d30v.c2
-rw-r--r--gcc/config/dsp16xx/dsp16xx.c2
-rw-r--r--gcc/config/elxsi/elxsi.c2
-rw-r--r--gcc/config/fr30/fr30.c2
-rw-r--r--gcc/config/h8300/h8300.c2
-rw-r--r--gcc/config/i370/i370.c2
-rw-r--r--gcc/config/i386/i386.c2
-rw-r--r--gcc/config/i860/i860.c2
-rw-r--r--gcc/config/i960/i960.c2
-rw-r--r--gcc/config/ia64/ia64.c2
-rw-r--r--gcc/config/m32r/m32r.c2
-rw-r--r--gcc/config/m68hc11/m68hc11.c2
-rw-r--r--gcc/config/m68k/m68k.c2
-rw-r--r--gcc/config/m88k/m88k.c2
-rw-r--r--gcc/config/mcore/mcore.c2
-rw-r--r--gcc/config/mips/mips.c2
-rw-r--r--gcc/config/mn10200/mn10200.c2
-rw-r--r--gcc/config/mn10300/mn10300.c2
-rw-r--r--gcc/config/ns32k/ns32k.c2
-rw-r--r--gcc/config/pa/pa.c2
-rw-r--r--gcc/config/pdp11/pdp11.c2
-rw-r--r--gcc/config/pj/pj.c2
-rw-r--r--gcc/config/romp/romp.c2
-rw-r--r--gcc/config/rs6000/rs6000.c2
-rw-r--r--gcc/config/sh/sh.c2
-rw-r--r--gcc/config/sparc/sparc.c2
-rw-r--r--gcc/config/v850/v850.c2
-rw-r--r--gcc/config/vax/vax.c2
-rw-r--r--gcc/config/we32k/we32k.c2
-rw-r--r--gcc/cp/decl.c2
-rw-r--r--gcc/cp/decl2.c16
-rw-r--r--gcc/cp/typeck.c8
-rw-r--r--gcc/doc/tm.texi6
-rw-r--r--gcc/final.c4
-rw-r--r--gcc/target.h6
-rw-r--r--gcc/tree.c14
48 files changed, 113 insertions, 69 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 3d8bc4d749d..933f4b848ad 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,47 @@
+2001-07-06 Stan Shebs <shebs@apple.com>
+
+ * target.h (targetm): Rename global from "target", so as not to
+ conflict with local variables.
+ * c-decl.c: Ditto.
+ * c-typeck.c: Ditto.
+ * final.c: Ditto.
+ * tree.c: Ditto.
+ * cp/decl.c: Ditto.
+ * cp/decl2.c: Ditto.
+ * cp/typeck.c: Ditto.
+ * 1750a/1750a.c: Ditto.
+ * a29k/a29k.c: Ditto.
+ * arc/arc.c: Ditto.
+ * arm/arm.c: Ditto.
+ * avr/avr.c: Ditto.
+ * clipper/clipper.c: Ditto.
+ * convex/convex.c: Ditto.
+ * d30v/d30v.c: Ditto.
+ * dsp16xx/dsp16xx.c: Ditto.
+ * elxsi/elxsi.c: Ditto.
+ * fr30/fr30.c: Ditto.
+ * h8300/h8300.c: Ditto.
+ * i370/i370.c: Ditto.
+ * i386/i386.c: Ditto.
+ * i860/i860.c: Ditto.
+ * i960/i960.c: Ditto.
+ * ia64/ia64.c: Ditto.
+ * m32r/m32r.c: Ditto.
+ * m68hc11/m68hc11.c: Ditto.
+ * m68k/m68k.c: Ditto.
+ * m88k/m88k.c: Ditto.
+ * mips/mips.c: Ditto.
+ * ns32k/ns32k.c: Ditto.
+ * pa/pa.c: Ditto.
+ * pdp11/pdp11.c: Ditto.
+ * romp/romp.c: Ditto.
+ * rs6000/rs6000.c: Ditto.
+ * sh/sh.c: Ditto.
+ * sparc/sparc.c: Ditto.
+ * vax/vax.c: Ditto.
+ * we32k/we32k.c: Ditto.
+ * doc/tm.texi: Update the manual to match.
+
2001-07-06 Richard Henderson <rth@redhat.com>
* except.h (MUST_USE_SJLJ_EXCEPTIONS): Examine the value of
diff --git a/gcc/c-decl.c b/gcc/c-decl.c
index 348701e78ae..deb47d174a6 100644
--- a/gcc/c-decl.c
+++ b/gcc/c-decl.c
@@ -1404,7 +1404,7 @@ duplicate_decls (newdecl, olddecl, different_binding_level)
if (DECL_P (olddecl))
DECL_MACHINE_ATTRIBUTES (newdecl)
- = (*target.merge_decl_attributes) (olddecl, newdecl);
+ = (*targetm.merge_decl_attributes) (olddecl, newdecl);
if (TREE_CODE (newtype) == ERROR_MARK
|| TREE_CODE (oldtype) == ERROR_MARK)
diff --git a/gcc/c-typeck.c b/gcc/c-typeck.c
index bc9de485a3f..9e50c37da69 100644
--- a/gcc/c-typeck.c
+++ b/gcc/c-typeck.c
@@ -206,7 +206,7 @@ common_type (t1, t2)
return t1;
/* Merge the attributes. */
- attributes = (*target.merge_type_attributes) (t1, t2);
+ attributes = (*targetm.merge_type_attributes) (t1, t2);
/* Treat an enum type as the unsigned integer type of the same width. */
@@ -484,7 +484,7 @@ comptypes (type1, type2)
return 1;
/* 1 if no need for warning yet, 2 if warning cause has been seen. */
- if (! (attrval = (*target.comp_type_attributes) (t1, t2)))
+ if (! (attrval = (*targetm.comp_type_attributes) (t1, t2)))
return 0;
/* 1 if no need for warning yet, 2 if warning cause has been seen. */
diff --git a/gcc/config/1750a/1750a.c b/gcc/config/1750a/1750a.c
index 39a0ebb0ba7..c1412bfb034 100644
--- a/gcc/config/1750a/1750a.c
+++ b/gcc/config/1750a/1750a.c
@@ -56,7 +56,7 @@ static void output_function_epilogue PARAMS ((FILE *, HOST_WIDE_INT));
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Generate the assembly code for function entry. FILE is a stdio
stream to output the code to. SIZE is an int: how many units of
diff --git a/gcc/config/a29k/a29k.c b/gcc/config/a29k/a29k.c
index 67c84efb80a..896f162fb7b 100644
--- a/gcc/config/a29k/a29k.c
+++ b/gcc/config/a29k/a29k.c
@@ -100,7 +100,7 @@ int a29k_compare_fp_p;
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Returns 1 if OP is a 8-bit constant. */
diff --git a/gcc/config/alpha/alpha.c b/gcc/config/alpha/alpha.c
index 3ddd7f3d9e1..d90aec9e7fb 100644
--- a/gcc/config/alpha/alpha.c
+++ b/gcc/config/alpha/alpha.c
@@ -148,7 +148,7 @@ static rtx alpha_emit_xfloating_compare
/* Initialize the GCC target structure. */
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Parse target option strings. */
diff --git a/gcc/config/arc/arc.c b/gcc/config/arc/arc.c
index 03e77ae1a0d..7e309f892cc 100644
--- a/gcc/config/arc/arc.c
+++ b/gcc/config/arc/arc.c
@@ -99,7 +99,7 @@ static void arc_output_function_epilogue PARAMS ((FILE *, HOST_WIDE_INT));
#undef TARGET_VALID_DECL_ATTRIBUTE
#define TARGET_VALID_DECL_ATTRIBUTE arc_valid_decl_attribute
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Called by OVERRIDE_OPTIONS to initialize various things. */
diff --git a/gcc/config/arm/arm.c b/gcc/config/arm/arm.c
index 7d18b71ec6f..48f0c5fb33d 100644
--- a/gcc/config/arm/arm.c
+++ b/gcc/config/arm/arm.c
@@ -148,7 +148,7 @@ static void arm_set_default_type_attributes PARAMS ((tree));
#undef TARGET_SET_DEFAULT_TYPE_ATTRIBUTES
#define TARGET_SET_DEFAULT_TYPE_ATTRIBUTES arm_set_default_type_attributes
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Obstack for minipool constant handling. */
static struct obstack minipool_obstack;
diff --git a/gcc/config/avr/avr.c b/gcc/config/avr/avr.c
index f242aa45b2d..303be94a88d 100644
--- a/gcc/config/avr/avr.c
+++ b/gcc/config/avr/avr.c
@@ -183,7 +183,7 @@ int avr_case_values_threshold = 30000;
#undef TARGET_VALID_TYPE_ATTRIBUTE
#define TARGET_VALID_TYPE_ATTRIBUTE avr_valid_type_attribute
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
void
avr_override_options ()
diff --git a/gcc/config/c4x/c4x.c b/gcc/config/c4x/c4x.c
index 458d1bd3376..6f75aa8709b 100644
--- a/gcc/config/c4x/c4x.c
+++ b/gcc/config/c4x/c4x.c
@@ -195,7 +195,7 @@ static int c4x_valid_type_attribute_p PARAMS ((tree, tree, tree, tree));
#undef TARGET_VALID_TYPE_ATTRIBUTE
#define TARGET_VALID_TYPE_ATTRIBUTE c4x_valid_type_attribute_p
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Called to register all of our global variables with the garbage
collector. */
diff --git a/gcc/config/clipper/clipper.c b/gcc/config/clipper/clipper.c
index 3adcff7c6a8..76320ff2076 100644
--- a/gcc/config/clipper/clipper.c
+++ b/gcc/config/clipper/clipper.c
@@ -55,7 +55,7 @@ static int frame_size;
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE clipper_output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Compute size of a clipper stack frame where 'lsize' is the required
space for local variables. */
diff --git a/gcc/config/convex/convex.c b/gcc/config/convex/convex.c
index 6f563e29edc..a0e0987b88e 100644
--- a/gcc/config/convex/convex.c
+++ b/gcc/config/convex/convex.c
@@ -73,7 +73,7 @@ static void convex_output_function_epilogue PARAMS ((FILE *, HOST_WIDE_INT));
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE convex_output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Generate the assembly code for function entry. FILE is a stdio
stream to output the code to. SIZE is an int: how many units of
diff --git a/gcc/config/d30v/d30v.c b/gcc/config/d30v/d30v.c
index e73cad011ff..b0709e82f86 100644
--- a/gcc/config/d30v/d30v.c
+++ b/gcc/config/d30v/d30v.c
@@ -87,7 +87,7 @@ enum reg_class reg_class_from_letter[256];
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE d30v_output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Sometimes certain combinations of command options do not make
sense on a particular target machine. You can define a macro
diff --git a/gcc/config/dsp16xx/dsp16xx.c b/gcc/config/dsp16xx/dsp16xx.c
index f20754fc945..32402623ff4 100644
--- a/gcc/config/dsp16xx/dsp16xx.c
+++ b/gcc/config/dsp16xx/dsp16xx.c
@@ -155,7 +155,7 @@ static void dsp16xx_output_function_epilogue PARAMS ((FILE *, HOST_WIDE_INT));
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE dsp16xx_output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
int
hard_regno_mode_ok (regno, mode)
diff --git a/gcc/config/elxsi/elxsi.c b/gcc/config/elxsi/elxsi.c
index 0939bd1f36b..0a0e77bf6bf 100644
--- a/gcc/config/elxsi/elxsi.c
+++ b/gcc/config/elxsi/elxsi.c
@@ -47,7 +47,7 @@ static void elxsi_output_function_epilogue PARAMS ((FILE *, HOST_WIDE_INT));
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE elxsi_output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Generate the assembly code for function entry. FILE is a stdio
stream to output the code to. SIZE is an int: how many units of
diff --git a/gcc/config/fr30/fr30.c b/gcc/config/fr30/fr30.c
index 3086334b0c7..3adcb09fb7a 100644
--- a/gcc/config/fr30/fr30.c
+++ b/gcc/config/fr30/fr30.c
@@ -139,7 +139,7 @@ static struct fr30_frame_info zero_frame_info;
/* Initialize the GCC target structure. */
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Returns the number of bytes offset between FROM_REG and TO_REG
for the current function. As a side effect it fills in the
diff --git a/gcc/config/h8300/h8300.c b/gcc/config/h8300/h8300.c
index 5fa079fda41..0d22818f2f8 100644
--- a/gcc/config/h8300/h8300.c
+++ b/gcc/config/h8300/h8300.c
@@ -105,7 +105,7 @@ const char *h8_push_op, *h8_pop_op, *h8_mov_op;
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE h8300_output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Initialize various cpu specific globals at start up. */
diff --git a/gcc/config/i370/i370.c b/gcc/config/i370/i370.c
index 43b5929805c..8dd229f268d 100644
--- a/gcc/config/i370/i370.c
+++ b/gcc/config/i370/i370.c
@@ -294,7 +294,7 @@ static const unsigned char ebcasc[256] =
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE i370_output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Map characters from one character set to another.
C is the character to be translated. */
diff --git a/gcc/config/i386/i386.c b/gcc/config/i386/i386.c
index bb337a2537c..69aab1a18fe 100644
--- a/gcc/config/i386/i386.c
+++ b/gcc/config/i386/i386.c
@@ -631,7 +631,7 @@ static int ix86_comp_type_attributes PARAMS ((tree, tree));
# define TARGET_ASM_FUNCTION_PROLOGUE ix86_osf_output_function_prologue
#endif
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Sometimes certain combinations of command options do not make
sense on a particular target machine. You can define a macro
diff --git a/gcc/config/i860/i860.c b/gcc/config/i860/i860.c
index ae72157e774..ead357ac24c 100644
--- a/gcc/config/i860/i860.c
+++ b/gcc/config/i860/i860.c
@@ -70,7 +70,7 @@ rtx i860_compare_op0, i860_compare_op1;
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE i860_output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Return non-zero if this pattern, can be evaluated safely, even if it
was not asked for. */
diff --git a/gcc/config/i960/i960.c b/gcc/config/i960/i960.c
index 264f7ee439f..7cdb5aa41ff 100644
--- a/gcc/config/i960/i960.c
+++ b/gcc/config/i960/i960.c
@@ -98,7 +98,7 @@ static int ret_label = 0;
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE i960_output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Initialize variables before compiling any files. */
diff --git a/gcc/config/ia64/ia64.c b/gcc/config/ia64/ia64.c
index 296306b1f82..2588612ca7e 100644
--- a/gcc/config/ia64/ia64.c
+++ b/gcc/config/ia64/ia64.c
@@ -149,7 +149,7 @@ static void ia64_function_epilogue PARAMS((FILE *, HOST_WIDE_INT));
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE ia64_output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Return 1 if OP is a valid operand for the MEM of a CALL insn. */
diff --git a/gcc/config/m32r/m32r.c b/gcc/config/m32r/m32r.c
index 12dad0d3171..006e7beb127 100644
--- a/gcc/config/m32r/m32r.c
+++ b/gcc/config/m32r/m32r.c
@@ -76,7 +76,7 @@ static void m32r_output_function_epilogue PARAMS ((FILE *, HOST_WIDE_INT));
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE m32r_output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Called by OVERRIDE_OPTIONS to initialize various things. */
diff --git a/gcc/config/m68hc11/m68hc11.c b/gcc/config/m68hc11/m68hc11.c
index a05eae51843..201910956a5 100644
--- a/gcc/config/m68hc11/m68hc11.c
+++ b/gcc/config/m68hc11/m68hc11.c
@@ -213,7 +213,7 @@ static int nb_soft_regs;
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE m68hc11_output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
int
m68hc11_override_options ()
diff --git a/gcc/config/m68k/m68k.c b/gcc/config/m68k/m68k.c
index 5df64bf1503..ffe7ed92263 100644
--- a/gcc/config/m68k/m68k.c
+++ b/gcc/config/m68k/m68k.c
@@ -86,7 +86,7 @@ int m68k_last_compare_had_fp_operands;
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE m68k_output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Sometimes certain combinations of command options do not make
sense on a particular target machine. You can define a macro
diff --git a/gcc/config/m88k/m88k.c b/gcc/config/m88k/m88k.c
index 3cb88902c5e..80867f2df06 100644
--- a/gcc/config/m88k/m88k.c
+++ b/gcc/config/m88k/m88k.c
@@ -72,7 +72,7 @@ static void m88k_output_function_epilogue PARAMS ((FILE *, HOST_WIDE_INT));
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE m88k_output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Determine what instructions are needed to manufacture the integer VALUE
in the given MODE. */
diff --git a/gcc/config/mcore/mcore.c b/gcc/config/mcore/mcore.c
index c5781752e21..e1f0f3382e4 100644
--- a/gcc/config/mcore/mcore.c
+++ b/gcc/config/mcore/mcore.c
@@ -142,7 +142,7 @@ static int mcore_valid_decl_attribute PARAMS ((tree, tree,
#undef TARGET_VALID_DECL_ATTRIBUTE
#define TARGET_VALID_DECL_ATTRIBUTE mcore_valid_decl_attribute
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Adjust the stack and return the number of bytes taken to do it. */
static void
diff --git a/gcc/config/mips/mips.c b/gcc/config/mips/mips.c
index 94308af3a40..e07f246b5cb 100644
--- a/gcc/config/mips/mips.c
+++ b/gcc/config/mips/mips.c
@@ -446,7 +446,7 @@ enum reg_class mips_char_to_class[256] =
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE mips_output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Return truth value of whether OP can be used as an operands
where a register or 16 bit unsigned integer is needed. */
diff --git a/gcc/config/mn10200/mn10200.c b/gcc/config/mn10200/mn10200.c
index 55c9fa5db27..45432ac2a2c 100644
--- a/gcc/config/mn10200/mn10200.c
+++ b/gcc/config/mn10200/mn10200.c
@@ -68,7 +68,7 @@ static int out_of_line_epilogue;
/* Initialize the GCC target structure. */
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Indicate this file was compiled by gcc and what optimization
level was used. */
diff --git a/gcc/config/mn10300/mn10300.c b/gcc/config/mn10300/mn10300.c
index f472867cf28..decbe6d5bf4 100644
--- a/gcc/config/mn10300/mn10300.c
+++ b/gcc/config/mn10300/mn10300.c
@@ -53,7 +53,7 @@ Boston, MA 02111-1307, USA. */
/* Initialize the GCC target structure. */
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
void
asm_file_start (file)
diff --git a/gcc/config/ns32k/ns32k.c b/gcc/config/ns32k/ns32k.c
index ca84f6e3feb..9ad3b0cb495 100644
--- a/gcc/config/ns32k/ns32k.c
+++ b/gcc/config/ns32k/ns32k.c
@@ -77,7 +77,7 @@ static void ns32k_output_function_epilogue PARAMS ((FILE *, HOST_WIDE_INT));
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE ns32k_output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Generate the assembly code for function entry. FILE is a stdio
stream to output the code to. SIZE is an int: how many units of
diff --git a/gcc/config/pa/pa.c b/gcc/config/pa/pa.c
index 04233835cde..36aad1b5b7a 100644
--- a/gcc/config/pa/pa.c
+++ b/gcc/config/pa/pa.c
@@ -116,7 +116,7 @@ int n_deferred_plabels = 0;
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE pa_output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
void
override_options ()
diff --git a/gcc/config/pdp11/pdp11.c b/gcc/config/pdp11/pdp11.c
index 2fdf0b05796..97d23fead5d 100644
--- a/gcc/config/pdp11/pdp11.c
+++ b/gcc/config/pdp11/pdp11.c
@@ -61,7 +61,7 @@ static void pdp11_output_function_epilogue PARAMS ((FILE *, HOST_WIDE_INT));
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE pdp11_output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Nonzero if OP is a valid second operand for an arithmetic insn. */
diff --git a/gcc/config/pj/pj.c b/gcc/config/pj/pj.c
index 1e0d3a828dd..02ef9a25acf 100644
--- a/gcc/config/pj/pj.c
+++ b/gcc/config/pj/pj.c
@@ -127,7 +127,7 @@ int pj_stuff_on_line;
/* Initialize the GCC target structure. */
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* printf to the asm_out_file, with special format control characters
for decoding operands.
diff --git a/gcc/config/romp/romp.c b/gcc/config/romp/romp.c
index 3fd24b5387f..27a17061f98 100644
--- a/gcc/config/romp/romp.c
+++ b/gcc/config/romp/romp.c
@@ -59,7 +59,7 @@ static void romp_output_function_epilogue PARAMS ((FILE *, HOST_WIDE_INT));
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE romp_output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Return 1 if the insn using CC0 set by INSN does not contain
any unsigned tests applied to the condition codes.
diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c
index 9c77e7a3590..21c9f1810e2 100644
--- a/gcc/config/rs6000/rs6000.c
+++ b/gcc/config/rs6000/rs6000.c
@@ -175,7 +175,7 @@ static char alt_reg_names[][8] =
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE rs6000_output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Override command line options. Mostly we process the processor
type and sometimes adjust other TARGET_ options. */
diff --git a/gcc/config/sh/sh.c b/gcc/config/sh/sh.c
index 63c0f166a70..db8de6574cc 100644
--- a/gcc/config/sh/sh.c
+++ b/gcc/config/sh/sh.c
@@ -163,7 +163,7 @@ static void sh_output_function_epilogue PARAMS ((FILE *, HOST_WIDE_INT));
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE sh_output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Print the operand address in x to the stream. */
diff --git a/gcc/config/sparc/sparc.c b/gcc/config/sparc/sparc.c
index ad63e331035..197242d1081 100644
--- a/gcc/config/sparc/sparc.c
+++ b/gcc/config/sparc/sparc.c
@@ -192,7 +192,7 @@ enum processor_type sparc_cpu;
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE sparc_output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Validate and override various options, and do some machine dependent
initialization. */
diff --git a/gcc/config/v850/v850.c b/gcc/config/v850/v850.c
index 88d6f3f909d..10f33e20ece 100644
--- a/gcc/config/v850/v850.c
+++ b/gcc/config/v850/v850.c
@@ -86,7 +86,7 @@ static int v850_interrupt_p = FALSE;
#undef TARGET_VALID_DECL_ATTRIBUTE
#define TARGET_VALID_DECL_ATTRIBUTE v850_valid_decl_attribute
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Sometimes certain combinations of command options do not make
sense on a particular target machine. You can define a macro
diff --git a/gcc/config/vax/vax.c b/gcc/config/vax/vax.c
index 50d9f708b2a..57f14e80a72 100644
--- a/gcc/config/vax/vax.c
+++ b/gcc/config/vax/vax.c
@@ -42,7 +42,7 @@ static void vax_output_function_prologue PARAMS ((FILE *, HOST_WIDE_INT));
#undef TARGET_ASM_FUNCTION_PROLOGUE
#define TARGET_ASM_FUNCTION_PROLOGUE vax_output_function_prologue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Generate the assembly code for function entry. FILE is a stdio
stream to output the code to. SIZE is an int: how many units of
diff --git a/gcc/config/we32k/we32k.c b/gcc/config/we32k/we32k.c
index 1a4fe881735..462b598862d 100644
--- a/gcc/config/we32k/we32k.c
+++ b/gcc/config/we32k/we32k.c
@@ -44,7 +44,7 @@ static void we32k_output_function_epilogue PARAMS ((FILE *, HOST_WIDE_INT));
#undef TARGET_ASM_FUNCTION_EPILOGUE
#define TARGET_ASM_FUNCTION_EPILOGUE we32k_output_function_epilogue
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
/* Generate the assembly code for function entry. FILE is a stdio
stream to output the code to. SIZE is an int: how many units of
diff --git a/gcc/cp/decl.c b/gcc/cp/decl.c
index 350422bcfe6..f6edc2cf3c9 100644
--- a/gcc/cp/decl.c
+++ b/gcc/cp/decl.c
@@ -3484,7 +3484,7 @@ duplicate_decls (newdecl, olddecl)
/* Copy all the DECL_... slots specified in the new decl
except for any that we copy here from the old type. */
DECL_MACHINE_ATTRIBUTES (newdecl)
- = (*target.merge_decl_attributes) (olddecl, newdecl);
+ = (*targetm.merge_decl_attributes) (olddecl, newdecl);
if (TREE_CODE (newdecl) == TEMPLATE_DECL)
{
diff --git a/gcc/cp/decl2.c b/gcc/cp/decl2.c
index 802ad49d867..5b0abfcd738 100644
--- a/gcc/cp/decl2.c
+++ b/gcc/cp/decl2.c
@@ -2456,16 +2456,16 @@ import_export_class (ctype)
if (CLASSTYPE_INTERFACE_ONLY (ctype))
return;
- if ((*target.valid_type_attribute) (ctype,
- TYPE_ATTRIBUTES (ctype),
- get_identifier ("dllimport"),
- NULL_TREE)
+ if ((*targetm.valid_type_attribute) (ctype,
+ TYPE_ATTRIBUTES (ctype),
+ get_identifier ("dllimport"),
+ NULL_TREE)
&& lookup_attribute ("dllimport", TYPE_ATTRIBUTES (ctype)))
import_export = -1;
- else if ((*target.valid_type_attribute) (ctype,
- TYPE_ATTRIBUTES (ctype),
- get_identifier ("dllexport"),
- NULL_TREE)
+ else if ((*targetm.valid_type_attribute) (ctype,
+ TYPE_ATTRIBUTES (ctype),
+ get_identifier ("dllexport"),
+ NULL_TREE)
&& lookup_attribute ("dllexport", TYPE_ATTRIBUTES (ctype)))
import_export = 1;
diff --git a/gcc/cp/typeck.c b/gcc/cp/typeck.c
index 43f38f3e1de..1cf76e5980a 100644
--- a/gcc/cp/typeck.c
+++ b/gcc/cp/typeck.c
@@ -212,7 +212,7 @@ qualify_type_recursive (t1, t2)
tree b1;
int type_quals;
tree tgt;
- tree attributes = (*target.merge_type_attributes) (t1, t2);
+ tree attributes = (*targetm.merge_type_attributes) (t1, t2);
if (TREE_CODE (tt1) == OFFSET_TYPE)
{
@@ -343,7 +343,7 @@ type_after_usual_arithmetic_conversions (t1, t2)
/* In what follows, we slightly generalize the rules given in [expr]
so as to deal with `long long'. First, merge the attributes. */
- attributes = (*target.merge_type_attributes) (t1, t2);
+ attributes = (*targetm.merge_type_attributes) (t1, t2);
/* If only one is real, use it as the result. */
if (code1 == REAL_TYPE && code2 != REAL_TYPE)
@@ -549,7 +549,7 @@ common_type (t1, t2)
return type_after_usual_arithmetic_conversions (t1, t2);
/* Merge the attributes. */
- attributes = (*target.merge_type_attributes) (t1, t2);
+ attributes = (*targetm.merge_type_attributes) (t1, t2);
/* Treat an enum type as the unsigned integer type of the same width. */
@@ -999,7 +999,7 @@ comptypes (t1, t2, strict)
if (strict & COMPARE_NO_ATTRIBUTES)
attrval = 1;
/* 1 if no need for warning yet, 2 if warning cause has been seen. */
- else if (! (attrval = (*target.comp_type_attributes) (t1, t2)))
+ else if (! (attrval = (*targetm.comp_type_attributes) (t1, t2)))
return 0;
/* 1 if no need for warning yet, 2 if warning cause has been seen. */
diff --git a/gcc/doc/tm.texi b/gcc/doc/tm.texi
index 71b5a91666c..b76b040938a 100644
--- a/gcc/doc/tm.texi
+++ b/gcc/doc/tm.texi
@@ -55,8 +55,8 @@ through the macros defined in the @file{.h} file.
@cindex target hooks
@cindex target functions
-@deftypevar {struct gcc_target} target
-The target @file{.c} file must define the global @code{target} variable
+@deftypevar {struct gcc_target} targetm
+The target @file{.c} file must define the global @code{targetm} variable
which contains pointers to functions and data relating to the target
machine. The variable is declared in @file{target.h};
@file{target-def.h} defines the macro @code{TARGET_INITIALIZER} which is
@@ -72,7 +72,7 @@ macros for which the default definition is inappropriate. For example:
#undef TARGET_VALID_TYPE_ATTRIBUTE
#define TARGET_VALID_TYPE_ATTRIBUTE @var{machine}_valid_type_attribute_p
-struct gcc_target target = TARGET_INITIALIZER;
+struct gcc_target targetm = TARGET_INITIALIZER;
@end smallexample
@end deftypevar
diff --git a/gcc/final.c b/gcc/final.c
index f40492b8da0..7509fbe0eff 100644
--- a/gcc/final.c
+++ b/gcc/final.c
@@ -1630,7 +1630,7 @@ final_start_function (first, file, optimize)
}
/* First output the function prologue: code to set up the stack frame. */
- (*target.asm_out.function_prologue) (file, get_frame_size ());
+ (*targetm.asm_out.function_prologue) (file, get_frame_size ());
/* If the machine represents the prologue as RTL, the profiling code must
be emitted when NOTE_INSN_PROLOGUE_END is scanned. */
@@ -1773,7 +1773,7 @@ final_end_function (first, file, optimize)
/* Finally, output the function epilogue:
code to restore the stack frame and return to the caller. */
- (*target.asm_out.function_epilogue) (file, get_frame_size ());
+ (*targetm.asm_out.function_epilogue) (file, get_frame_size ());
#ifdef SDB_DEBUGGING_INFO
if (write_symbols == SDB_DEBUG)
diff --git a/gcc/target.h b/gcc/target.h
index 9515aff31db..11d0a0e08c4 100644
--- a/gcc/target.h
+++ b/gcc/target.h
@@ -33,9 +33,9 @@ Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
includes target.h and target-def.h, and overrides any inappropriate
defaults by undefining the relevant macro and defining a suitable
replacement. That file should then contain the definition of
- "target" like so:
+ "targetm" like so:
- struct gcc_target target = TARGET_INITIALIZER;
+ struct gcc_target targetm = TARGET_INITIALIZER;
Doing things this way allows us to bring together everything that
defines a target to GCC. By supplying a default that is
@@ -83,4 +83,4 @@ struct gcc_target
void (* set_default_type_attributes) PARAMS ((tree type));
};
-extern struct gcc_target target;
+extern struct gcc_target targetm;
diff --git a/gcc/tree.c b/gcc/tree.c
index fdae8512869..a48724b45d8 100644
--- a/gcc/tree.c
+++ b/gcc/tree.c
@@ -435,7 +435,7 @@ make_node (code)
/* Default to no attributes for type, but let target change that. */
TYPE_ATTRIBUTES (t) = NULL_TREE;
- (*target.set_default_type_attributes) (t);
+ (*targetm.set_default_type_attributes) (t);
/* We have not yet computed the alias set for this type. */
TYPE_ALIAS_SET (t) = -1;
@@ -2759,8 +2759,8 @@ valid_machine_attribute (attr_name, attr_args, decl, type)
{
tree decl_attrs = DECL_MACHINE_ATTRIBUTES (decl);
- if ((*target.valid_decl_attribute) (decl, decl_attrs, attr_name,
- attr_args))
+ if ((*targetm.valid_decl_attribute) (decl, decl_attrs, attr_name,
+ attr_args))
{
tree attr = lookup_attribute (IDENTIFIER_POINTER (attr_name),
decl_attrs);
@@ -2783,8 +2783,8 @@ valid_machine_attribute (attr_name, attr_args, decl, type)
}
type_attrs = TYPE_ATTRIBUTES (type);
- if ((*target.valid_type_attribute) (type, type_attrs, attr_name,
- attr_args))
+ if ((*targetm.valid_type_attribute) (type, type_attrs, attr_name,
+ attr_args))
{
tree attr = lookup_attribute (IDENTIFIER_POINTER (attr_name),
type_attrs);
@@ -2818,8 +2818,8 @@ valid_machine_attribute (attr_name, attr_args, decl, type)
by putting the attribute on the function type. */
else if (POINTER_TYPE_P (type)
&& TREE_CODE (TREE_TYPE (type)) == FUNCTION_TYPE
- && (*target.valid_type_attribute) (TREE_TYPE (type), type_attrs,
- attr_name, attr_args))
+ && (*targetm.valid_type_attribute) (TREE_TYPE (type), type_attrs,
+ attr_name, attr_args))
{
tree inner_type = TREE_TYPE (type);
tree inner_attrs = TYPE_ATTRIBUTES (inner_type);