c-parse.in (MODIFIED_WCHAR_TYPE): New macro.
authorZack Weinberg <zack@codesourcery.com>
Wed, 15 May 2002 05:30:01 +0000 (05:30 +0000)
committerZack Weinberg <zack@gcc.gnu.org>
Wed, 15 May 2002 05:30:01 +0000 (05:30 +0000)
* c-parse.in (MODIFIED_WCHAR_TYPE): New macro.
(c_common_nodes_and_builtins): Use it.
(builtin_define_with_value): New function.
(cb_register_builtins): Define __SIZE_TYPE__,
__PTRDIFF_TYPE__, __WCHAR_TYPE__, and __WINT_TYPE__ here,
using builtin_define_with_value.  Use consistent notation when
defining __GXX_WEAK__.
(WCHAR_TYPE_SIZE): Don't redefine.
(combine_strings): Don't use WCHAR_TYPE_SIZE.

* cppdefault.h: Don't provide defaults for SIZE_TYPE,
PTRDIFF_TYPE, WCHAR_TYPE, or WINT_TYPE.
* cppinit.c (builtin_array): Remove entries for __SIZE_TYPE__ etc.
* tradcpp.c (initialize_builtins): Likewise.
* gcc.c (cpp_unique_options): Don't muck with __WCHAR_TYPE__.

* c-lex.h (builtin_define_with_value): Prototype.
* system.h: Poison NO_BUILTIN_SIZE_TYPE, NO_BUILTIN_WCHAR_TYPE,
NO_BUILTIN_PTRDIFF_TYPE, and NO_BUILTIN_WINT_TYPE.
* doc/tm.texi: Remove mention of NO_BUILTIN_SIZE_TYPE etc.

* config/avr/avr.h, config/h8300/h8300.h, config/i386/i386.h,
config/ia64/ia64.h, config/mips/dec-osf1.h, config/mips/iris6.h,
config/mips/linux.h, config/mips/mips.h, config/mips/netbsd.h,
config/mips/osfrose.h, config/mips/sni-svr4.h, config/rs6000/aix51.h,
config/s390/linux.h, config/sh/sh.h, config/sh/sh64.h,
config/sparc/linux64.h, config/sparc/netbsd-elf.h,
config/sparc/sol2-bi.h, config/sparc/sparc.h:
Do not define NO_BUILTIN_SIZE_TYPE etc.  Remove all references
to __SIZE_TYPE__ etc from all spec strings. When this makes
extra specs empty, delete them.

From-SVN: r53472

28 files changed:
gcc/ChangeLog
gcc/c-common.c
gcc/c-lex.h
gcc/config/avr/avr.h
gcc/config/h8300/h8300.h
gcc/config/i386/i386.h
gcc/config/ia64/ia64.h
gcc/config/mips/dec-osf1.h
gcc/config/mips/iris6.h
gcc/config/mips/linux.h
gcc/config/mips/mips.h
gcc/config/mips/netbsd.h
gcc/config/mips/osfrose.h
gcc/config/mips/sni-svr4.h
gcc/config/rs6000/aix51.h
gcc/config/s390/linux.h
gcc/config/sh/sh.h
gcc/config/sh/sh64.h
gcc/config/sparc/linux64.h
gcc/config/sparc/netbsd-elf.h
gcc/config/sparc/sol2-bi.h
gcc/config/sparc/sparc.h
gcc/cppdefault.h
gcc/cppinit.c
gcc/doc/tm.texi
gcc/gcc.c
gcc/system.h
gcc/tradcpp.c

index c7c0dccc9452dec934e40c909a51717495ee215d..8b4a89679c47f6e8d393a911db5f8fdc0b2da1de 100644 (file)
@@ -1,3 +1,37 @@
+2002-05-14  Zack Weinberg  <zack@codesourcery.com>
+
+       * c-parse.in (MODIFIED_WCHAR_TYPE): New macro.
+       (c_common_nodes_and_builtins): Use it.
+       (builtin_define_with_value): New function.
+       (cb_register_builtins): Define __SIZE_TYPE__,
+       __PTRDIFF_TYPE__, __WCHAR_TYPE__, and __WINT_TYPE__ here,
+       using builtin_define_with_value.  Use consistent notation when
+       defining __GXX_WEAK__.
+       (WCHAR_TYPE_SIZE): Don't redefine.
+       (combine_strings): Don't use WCHAR_TYPE_SIZE.
+
+       * cppdefault.h: Don't provide defaults for SIZE_TYPE,
+       PTRDIFF_TYPE, WCHAR_TYPE, or WINT_TYPE.
+       * cppinit.c (builtin_array): Remove entries for __SIZE_TYPE__ etc.
+       * tradcpp.c (initialize_builtins): Likewise.
+       * gcc.c (cpp_unique_options): Don't muck with __WCHAR_TYPE__.
+
+       * c-lex.h (builtin_define_with_value): Prototype.
+       * system.h: Poison NO_BUILTIN_SIZE_TYPE, NO_BUILTIN_WCHAR_TYPE,
+       NO_BUILTIN_PTRDIFF_TYPE, and NO_BUILTIN_WINT_TYPE.
+       * doc/tm.texi: Remove mention of NO_BUILTIN_SIZE_TYPE etc.
+
+       * config/avr/avr.h, config/h8300/h8300.h, config/i386/i386.h,
+       config/ia64/ia64.h, config/mips/dec-osf1.h, config/mips/iris6.h,
+       config/mips/linux.h, config/mips/mips.h, config/mips/netbsd.h,
+       config/mips/osfrose.h, config/mips/sni-svr4.h, config/rs6000/aix51.h,
+       config/s390/linux.h, config/sh/sh.h, config/sh/sh64.h,
+       config/sparc/linux64.h, config/sparc/netbsd-elf.h,
+       config/sparc/sol2-bi.h, config/sparc/sparc.h:
+       Do not define NO_BUILTIN_SIZE_TYPE etc.  Remove all references
+       to __SIZE_TYPE__ etc from all spec strings. When this makes
+       extra specs empty, delete them.
+
 2002-05-14  John David Anglin  <dave@hiauly1.hia.nrc.ca>
 
        * pa.c (override_options): Override TARGET_JUMP_IN_DELAY when scheduling
index 8233187b92a88b1cbcef565b158a78b523888b31..f60a27f864ca545eead9f1a71521a6749842b05e 100644 (file)
@@ -41,9 +41,6 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
 #include "except.h"            /* For USING_SJLJ_EXCEPTIONS.  */
 cpp_reader *parse_in;          /* Declared in c-lex.h.  */
 
-#undef WCHAR_TYPE_SIZE
-#define WCHAR_TYPE_SIZE TYPE_PRECISION (wchar_type_node)
-
 /* We let tm.h override the types used here, to handle trivial differences
    such as the choice of unsigned int or long unsigned int for size_t.
    When machines start needing nontrivial differences in the size type,
@@ -58,6 +55,10 @@ cpp_reader *parse_in;                /* Declared in c-lex.h.  */
 #define WCHAR_TYPE "int"
 #endif
 
+/* WCHAR_TYPE gets overridden by -fshort-wchar.  */
+#define MODIFIED_WCHAR_TYPE \
+       (flag_short_wchar ? "short unsigned int" : WCHAR_TYPE)
+
 #ifndef PTRDIFF_TYPE
 #define PTRDIFF_TYPE "long int"
 #endif
@@ -802,7 +803,8 @@ combine_strings (strings)
        }
       else
        {
-         const int nzeros = (WCHAR_TYPE_SIZE / BITS_PER_UNIT) - 1;
+         const int nzeros = (TYPE_PRECISION (wchar_type_node)
+                             / BITS_PER_UNIT) - 1;
          int j, k;
 
          if (BYTES_BIG_ENDIAN)
@@ -2872,9 +2874,7 @@ c_common_nodes_and_builtins ()
   (*targetm.init_builtins) ();
 
   /* This is special for C++ so functions can be overloaded.  */
-  wchar_type_node = get_identifier (flag_short_wchar
-                                   ? "short unsigned int"
-                                   : WCHAR_TYPE);
+  wchar_type_node = get_identifier (MODIFIED_WCHAR_TYPE);
   wchar_type_node = TREE_TYPE (identifier_global_value (wchar_type_node));
   wchar_type_size = TYPE_PRECISION (wchar_type_node);
   if (c_language == clk_cplusplus)
@@ -4321,7 +4321,7 @@ cb_register_builtins (pfile)
   if (c_language == clk_cplusplus)
     {
       if (SUPPORTS_ONE_ONLY)
-       cpp_define (pfile, "__GXX_WEAK__");
+       cpp_define (pfile, "__GXX_WEAK__=1");
       else
        cpp_define (pfile, "__GXX_WEAK__=0");
     }
@@ -4330,6 +4330,12 @@ cb_register_builtins (pfile)
   if (USING_SJLJ_EXCEPTIONS)
     cpp_define (pfile, "__USING_SJLJ_EXCEPTIONS__");
 
+  /* stddef.h needs to know these.  */
+  builtin_define_with_value ("__SIZE_TYPE__", SIZE_TYPE);
+  builtin_define_with_value ("__PTRDIFF_TYPE__", PTRDIFF_TYPE);
+  builtin_define_with_value ("__WCHAR_TYPE__", MODIFIED_WCHAR_TYPE);
+  builtin_define_with_value ("__WINT_TYPE__", WINT_TYPE);
+
   /* A straightforward target hook doesn't work, because of problems
      linking that hook's body when part of non-C front ends.  */
   TARGET_CPU_CPP_BUILTINS ();
@@ -4379,6 +4385,27 @@ builtin_define_std (macro)
     }
 }
 
+/* Pass an object-like macro and a value to define it to.  */
+void
+builtin_define_with_value (macro, expansion)
+     const char *macro;
+     const char *expansion;
+{
+  char *buf, *q;
+  size_t mlen = strlen (macro);
+  size_t elen = strlen (expansion);
+
+  q = buf = alloca (mlen + elen + 2);
+  memcpy (q, macro, mlen);
+  q += mlen;
+  *q++ = '=';
+  memcpy (q, expansion, elen);
+  q += elen;
+  *q = '\0';
+
+  cpp_define (parse_in, buf);
+}
+
 /* Front end initialization common to C, ObjC and C++.  */
 const char *
 c_common_init (filename)
index 049bf6b36235eadf01be44821b770ac10b53fd4a..c9af00903a60ea7109f5938e967829a32776900b 100644 (file)
@@ -49,4 +49,7 @@ extern struct cpp_reader* parse_in;
    "_mips".  */
 extern void builtin_define_std PARAMS ((const char *));
 
+/* Pass an object-like macro and a value to define it to.  */
+extern void builtin_define_with_value PARAMS ((const char *, const char *));
+
 #endif /* ! GCC_C_LEX_H */
index 949f45f8dedb8911c0955d7c809bf1d8845c29ed..66ca80c663fa1cf0f41d8c7d1879dc2b4b600ff8 100644 (file)
@@ -2653,8 +2653,8 @@ extern int avr_case_values_threshold;
 %{mmcu=attiny15: %(cpp_avr1) -D__AVR_ATtiny15__} \
 %{mmcu=attiny28: %(cpp_avr1) -D__AVR_ATtiny28__} \
 %{mno-interrupts:-D__NO_INTERRUPTS__} \
-%{mint8:-D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long -D__INT_MAX__=127} \
-%{!mint*:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int -D__INT_MAX__=32767} \
+%{mint8:-D__INT_MAX__=127} \
+%{!mint*:-D__INT_MAX__=32767} \
 %{posix:-D_POSIX_SOURCE}"
 /* A C string constant that tells the GNU CC driver program options to
    pass to CPP.  It can also specify how to translate options you
@@ -2662,24 +2662,6 @@ extern int avr_case_values_threshold;
 
    Do not define this macro if it does not need to do anything.  */
 
-#define NO_BUILTIN_SIZE_TYPE
-/* If this macro is defined, the preprocessor will not define the
-   builtin macro `__SIZE_TYPE__'.  The macro `__SIZE_TYPE__' must
-   then be defined by `CPP_SPEC' instead.
-
-   This should be defined if `SIZE_TYPE' depends on target dependent
-   flags which are not accessible to the preprocessor.  Otherwise, it
-   should not be defined.  */
-
-#define NO_BUILTIN_PTRDIFF_TYPE
-/* If this macro is defined, the preprocessor will not define the
-   builtin macro `__PTRDIFF_TYPE__'.  The macro `__PTRDIFF_TYPE__'
-   must then be defined by `CPP_SPEC' instead.
-
-   This should be defined if `PTRDIFF_TYPE' depends on target
-   dependent flags which are not accessible to the preprocessor.
-   Otherwise, it should not be defined.  */
-
 #define CC1_SPEC "%{profile:-p}"
 /* A C string constant that tells the GNU CC driver program options to
    pass to `cc1'.  It can also specify how to translate options you
index 79562fcd6021ecdb62d75de05ff958257f0f6d77..ccf8c461cbcba39d69bd1c351c01c74d9ab85af0 100644 (file)
@@ -44,9 +44,6 @@ extern const char * const *h8_reg_names;
 
 #define CPP_SPEC \
   "%{!mh:%{!ms:-D__H8300__}} %{mh:-D__H8300H__} %{ms:-D__H8300S__} \
-   %{!mh:%{!ms:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int}} \
-   %{mh:-D__SIZE_TYPE__=unsigned\\ long -D__PTRDIFF_TYPE__=long} \
-   %{ms:-D__SIZE_TYPE__=unsigned\\ long -D__PTRDIFF_TYPE__=long} \
    %{!mh:%{!ms:-Acpu=h8300 -Amachine=h8300}} \
    %{mh:-Acpu=h8300h -Amachine=h8300h} \
    %{ms:-Acpu=h8300s -Amachine=h8300s} \
@@ -974,8 +971,6 @@ struct cum_arg
 /* ANSI C types.
    We use longs for the 300H because ints can be 16 or 32.
    GCC requires SIZE_TYPE to be the same size as pointers.  */
-#define NO_BUILTIN_SIZE_TYPE
-#define NO_BUILTIN_PTRDIFF_TYPE
 #define SIZE_TYPE (TARGET_H8300 ? "unsigned int" : "long unsigned int")
 #define PTRDIFF_TYPE (TARGET_H8300 ? "int" : "long int")
 
index 680605b9955df922c089174b67686b750e141fdd..7ed0ddefd592114542cdb8d8afd1deeeeb49dbee 100644 (file)
@@ -554,27 +554,12 @@ extern int ix86_arch;
 #endif
 #endif /* CPP_CPU_DEFAULT_SPEC */
 
-#ifdef TARGET_BI_ARCH
-#define NO_BUILTIN_SIZE_TYPE
-#define NO_BUILTIN_PTRDIFF_TYPE
-#endif
-
-#ifdef NO_BUILTIN_SIZE_TYPE
-#define CPP_CPU32_SIZE_TYPE_SPEC \
-  " -D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int"
-#define CPP_CPU64_SIZE_TYPE_SPEC \
-  " -D__SIZE_TYPE__=unsigned\\ long\\ int -D__PTRDIFF_TYPE__=long\\ int"
-#else
-#define CPP_CPU32_SIZE_TYPE_SPEC ""
-#define CPP_CPU64_SIZE_TYPE_SPEC ""
-#endif
-
 #define CPP_CPU32_SPEC \
   "-Acpu=i386 -Amachine=i386 %{!ansi:%{!std=c*:%{!std=i*:-Di386}}} -D__i386 \
--D__i386__ %(cpp_cpu32sizet)"
+-D__i386__"
 
 #define CPP_CPU64_SPEC \
-  "-Acpu=x86_64 -Amachine=x86_64 -D__x86_64 -D__x86_64__ %(cpp_cpu64sizet)"
+  "-Acpu=x86_64 -Amachine=x86_64 -D__x86_64 -D__x86_64__"
 
 #define CPP_CPUCOMMON_SPEC "\
 %{march=i386:%{!mcpu*:-D__tune_i386__ }}\
@@ -662,8 +647,6 @@ extern int ix86_arch;
   { "cpp_cpu", CPP_CPU_SPEC },                                         \
   { "cpp_cpu32", CPP_CPU32_SPEC },                                     \
   { "cpp_cpu64", CPP_CPU64_SPEC },                                     \
-  { "cpp_cpu32sizet", CPP_CPU32_SIZE_TYPE_SPEC },                      \
-  { "cpp_cpu64sizet", CPP_CPU64_SIZE_TYPE_SPEC },                      \
   { "cpp_cpucommon", CPP_CPUCOMMON_SPEC },                             \
   { "cc1_cpu",  CC1_CPU_SPEC },                                                \
   SUBTARGET_EXTRA_SPECS
index fd880facde995afab0372dffaa912ac515b50624..0b2aea59efd5ce7f6c0948e36dfa1897111c302c 100644 (file)
@@ -213,12 +213,6 @@ extern const char *ia64_fixed_range_string;
    %(cpp_cpu)  \
    -D__LONG_MAX__=9223372036854775807L"
 
-/* This is always "long" so it doesn't "change" in ILP32 vs. LP64.  */
-/* #define NO_BUILTIN_SIZE_TYPE */
-
-/* This is always "long" so it doesn't "change" in ILP32 vs. LP64.  */
-/* #define NO_BUILTIN_PTRDIFF_TYPE */
-
 /* A C string constant that tells the GNU CC driver program options to pass to
    `cc1'.  It can also specify how to translate options you give to GNU CC into
    options for GNU CC to pass to the `cc1'.  */
index 2501cad45a9037ced1e33e0b267ce55cd4293282..3f54d14c3b4a45d03db1c52cc1cbca7f48e43386 100644 (file)
@@ -43,11 +43,6 @@ Boston, MA 02111-1307, USA.  */
 #define WCHAR_TYPE     "short unsigned int"
 #define WCHAR_TYPE_SIZE SHORT_TYPE_SIZE
 
-#undef SUBTARGET_CPP_SIZE_SPEC
-#define SUBTARGET_CPP_SIZE_SPEC "\
-%{mlong64:-D__PTRDIFF_TYPE__=long\\ int} \
-%{!mlong64:-D__PTRDIFF_TYPE__=int}"
-
 /* turn off collect2 COFF support, since ldfcn now has elf declaration */
 #undef OBJECT_FORMAT_COFF
 
index 56ea80753b7773a9ae27fa0c2200c4ac68e5b82c..71a18e83a16b3f6bb222597bbda0e311a401ce97 100644 (file)
@@ -44,8 +44,6 @@ Boston, MA 02111-1307, USA.  */
 
 /* wchar_t is defined differently with and without -mabi=64.  */
 
-#define NO_BUILTIN_WCHAR_TYPE
-
 #undef WCHAR_TYPE
 #define WCHAR_TYPE (Pmode == DImode ? "int" : "long int")
 
@@ -54,8 +52,6 @@ Boston, MA 02111-1307, USA.  */
 
 /* Same for wint_t.  */
 
-#define NO_BUILTIN_WINT_TYPE
-
 #undef WINT_TYPE
 #define WINT_TYPE (Pmode == DImode ? "int" : "long int")
 
@@ -78,15 +74,6 @@ Boston, MA 02111-1307, USA.  */
   -D_LONGLONG -D_SVR4_SOURCE -D_MODERN_C -D__DSO__ \
   -Asystem=unix -Asystem=svr4 -Acpu=mips -Amachine=sgi"
 
-#undef SUBTARGET_CPP_SIZE_SPEC
-#define SUBTARGET_CPP_SIZE_SPEC "\
-%{mabi=32|mabi=n32: -D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int \
--D__WCHAR_TYPE__=long\\ int -D__WINT_TYPE__=long\\ int} \
-%{mabi=64: -D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int \
--D__WCHAR_TYPE__=int -D__WINT_TYPE__=int} \
-%{!mabi*: -D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int \
--D__WCHAR_TYPE__=long\\ int -D__WINT_TYPE__=long\\ int}"
-
 /* We must make -mips3 do what -mlong64 used to do.  */
 /* ??? If no mipsX option given, but a mabi=X option is, then should set
    _MIPS_ISA based on the mabi=X option.  */
@@ -94,7 +81,6 @@ Boston, MA 02111-1307, USA.  */
    _MIPS_SIM based on the mipsX option.  */
 /* ??? Same for _MIPS_SZINT.  */
 /* ??? Same for _MIPS_SZPTR.  */
-/* ??? Same for __SIZE_TYPE and __PTRDIFF_TYPE.  */
 #undef SUBTARGET_CPP_SPEC
 #define SUBTARGET_CPP_SPEC "\
 %{!ansi:-D__EXTENSIONS__ -D_SGI_SOURCE} \
index f1ff69e05046be2652c6ba1831ea7ecc8134af2b..7e2b9ea671ea69fdb511e3bbf961e416c001f792 100644 (file)
@@ -142,13 +142,6 @@ void FN ()                                                 \
 -Amachine=mips -D__ELF__ -D__PIC__ -D__pic__"
 #endif
 
-#undef SUBTARGET_CPP_SIZE_SPEC
-#define SUBTARGET_CPP_SIZE_SPEC "\
-%{mabi=32: -D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-%{mabi=n32: -D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-%{mabi=64: -D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int} \
-%{!mabi*: -D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int}"
-
 /* We must make -mips3 do what -mlong64 used to do.  */
 /* ??? If no mipsX option given, but a mabi=X option is, then should set
    _MIPS_ISA based on the mabi=X option.  */
@@ -156,7 +149,6 @@ void FN ()                                                  \
    _MIPS_SIM based on the mipsX option.  */
 /* ??? Same for _MIPS_SZINT.  */
 /* ??? Same for _MIPS_SZPTR.  */
-/* ??? Same for __SIZE_TYPE and __PTRDIFF_TYPE.  */
 #undef SUBTARGET_CPP_SPEC
 #define SUBTARGET_CPP_SPEC "\
 %{mfp32: -D_MIPS_FPSET=16} \
index 670b4137a467a0d5277ea2aa6b97c730047c1cda..a6467c066ddcb87675ed114fc539fef30f0363b3 100644 (file)
@@ -1013,11 +1013,6 @@ extern int mips_abi;
 
 /* Preprocessor specs.  */
 
-/* SUBTARGET_CPP_SIZE_SPEC defines SIZE_TYPE and PTRDIFF_TYPE.  It may
-   be overridden by subtargets.  */
-
-#ifndef SUBTARGET_CPP_SIZE_SPEC
-
 /* Rules for SIZE_TYPE and PTRDIFF_TYPE are:
 
    both gp64 and long64 (not the options, but the corresponding flags,
@@ -1043,20 +1038,6 @@ extern int mips_abi;
 /* 32-bit cases first.  */
 
 #if MIPS_ABI_DEFAULT == ABI_EABI
-#define SUBTARGET_CPP_SIZE_SPEC "\
-%{mabi=eabi|!mabi=*:\
-  %{mips1|mips2|mips32|mgp32|mlong32: \
-    -D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-  %{!mips1:%{!mips2:%{!mips32:%{!mgp32:%{!mlong32: \
-    %{mips3|mips4|mips5|mips64|mgp64: \
-      -D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int} \
-    %{!mips3:%{!mips4:%{!mips5:%{!mips64:%{!mgp64: \
-      -D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int}}}}}}}}}}} \
-%{mabi=o64:\
- %{!mgp64|!-mlong64:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
- %{mgp64:%{mlong64:-D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int}}} \
-%{mabi=32:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-"
 #define LONG_MAX_SPEC "\
 %{mlong64:-D__LONG_MAX__=9223372036854775807L}\
 %{!mlong64:\
@@ -1076,76 +1057,10 @@ extern int mips_abi;
 "
 #endif
 
-#if MIPS_ABI_DEFAULT == ABI_O64
-#define SUBTARGET_CPP_SIZE_SPEC "\
-%{mabi=eabi:\
-  %{mips1|mips2|mips32|mgp32|mlong32: \
-    -D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-  %{!mips1:%{!mips2:%{!mips32:%{!mgp32:%{!mlong32: \
-    %{mips3|mips4|mips5|mips64|mgp64: \
-      -D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int} \
-    %{!mips3:%{!mips4:%{!mips5:%{!mips64:%{!mgp64: \
-      -D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int}}}}}}}}}}} \
-%{mabi=o64|!mabi=*:\
- %{!mgp64|!-mlong64:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
- %{mgp64:%{mlong64:-D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int}}} \
-%{mabi=32:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-%{mabi=meabi:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-"
-#endif
-
-#if MIPS_ABI_DEFAULT == ABI_32
-#define SUBTARGET_CPP_SIZE_SPEC "\
-%{mabi=eabi:\
-  %{mips1|mips2|mips32|mgp32|mlong32: \
-    -D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-  %{!mips1:%{!mips2:%{!mips32:%{!mgp32:%{!mlong32: \
-    %{mips3|mips4|mips5|mips64|mgp64: \
-      -D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int} \
-    %{!mips3:%{!mips4:%{!mips5:%{!mips64:%{!mgp64: \
-      -D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int}}}}}}}}}}} \
-%{mabi=o64:\
- %{!mgp64|!-mlong64:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
- %{mgp64:%{mlong64:-D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int}}} \
-%{mabi=32|!mabi=*:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-%{mabi=meabi:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-"
-#endif
-
-#if MIPS_ABI_DEFAULT == ABI_MEABI
-#define SUBTARGET_CPP_SIZE_SPEC "\
-%{mabi=eabi:\
-  %{mips1|mips2|mips32|mgp32|mlong32: \
-    -D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-  %{!mips1:%{!mips2:%{!mips32:%{!mgp32:%{!mlong32: \
-    %{mips3|mips4|mips5|mips64|mgp64: \
-      -D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int} \
-    %{!mips3:%{!mips4:%{!mips5:%{!mips64:%{!mgp64: \
-      -D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int}}}}}}}}}}} \
-%{mabi=o64:\
- %{!mgp64|!-mlong64:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
- %{mgp64:%{mlong64:-D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int}}} \
-%{mabi=32:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-%{mabi=meabi|!mabi=*:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-"
-#endif
-
 #else
 
 /* 64-bit default ISA.  */
 #if MIPS_ABI_DEFAULT == ABI_EABI
-#define SUBTARGET_CPP_SIZE_SPEC "\
-%{mabi=eabi|!mabi=*: \
-  %{mips1|mips2|mips32|mgp32|mlong32: \
-    -D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-  %{!mips1:%{!mips2:%{!mips32:%{!mgp32:%{!mlong32: \
-    -D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int}}}}}} \
-%{mabi=o64:\
- %{mgp32|!-mlong64:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
- %{!mgp32:%{mlong64:-D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int}}} \
-%{mabi=32:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-%{mabi=meabi:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-"
 #define LONG_MAX_SPEC "\
 %{mlong64:-D__LONG_MAX__=9223372036854775807L}\
 %{!mlong64:\
@@ -1163,53 +1078,6 @@ extern int mips_abi;
 "
 #endif
 
-#if MIPS_ABI_DEFAULT == ABI_O64
-#define SUBTARGET_CPP_SIZE_SPEC "\
-%{mabi=eabi: \
-  %{mips1|mips2|mips32|mgp32|mlong32: \
-    -D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-  %{!mips1:%{!mips2:%{!mips32:%{!mgp32:%{!mlong32: \
-    -D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int}}}}}} \
-%{mabi=o64|!mabi=*:\
- %{mgp32|!-mlong64:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
- %{!mgp32:%{mlong64:-D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int}}} \
-%{mabi=32:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-%{mabi=meabi:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-"
-#endif
-
-#if MIPS_ABI_DEFAULT == ABI_32
-#define SUBTARGET_CPP_SIZE_SPEC "\
-%{mabi=eabi:\
-  %{mips1|mips2|mips32|mgp32|mlong32: \
-    -D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-  %{!mips1:%{!mips2:%{!mips32:%{!mgp32:%{!mlong32: \
-    -D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int}}}}}} \
-%{mabi=o64:\
- %{mgp32|!-mlong64:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
- %{!mgp32:%{mlong64:-D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int}}} \
-%{mabi=32|!mabi=*:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-%{mabi=meabi:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-"
-#endif
-
-#if MIPS_ABI_DEFAULT == ABI_MEABI
-#define SUBTARGET_CPP_SIZE_SPEC "\
-%{mabi=eabi:\
-  %{mips1|mips2|mips32|mgp32|mlong32: \
-    -D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-  %{!mips1:%{!mips2:%{!mips32:%{!mgp32:%{!mlong32: \
-    -D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int}}}}}} \
-%{mabi=o64:\
- %{mgp32|!-mlong64:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
- %{!mgp32:%{mlong64:-D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int}}} \
-%{mabi=32:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-%{mabi=meabi|!mabi=*:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-"
-#endif
-
-#endif
-
 #endif
 
 /* SUBTARGET_CPP_SPEC is passed to the preprocessor.  It may be
@@ -1273,7 +1141,6 @@ extern int mips_abi;
   { "subtarget_cc1_spec", SUBTARGET_CC1_SPEC },                                \
   { "cc1_cpu_spec", CC1_CPU_SPEC},                                      \
   { "subtarget_cpp_spec", SUBTARGET_CPP_SPEC },                                \
-  { "subtarget_cpp_size_spec", SUBTARGET_CPP_SIZE_SPEC },              \
   { "long_max_spec", LONG_MAX_SPEC },                                  \
   { "cpp_fpr_spec", CPP_FPR_SPEC },                                    \
   { "mips_as_asm_spec", MIPS_AS_ASM_SPEC },                            \
@@ -4940,12 +4807,10 @@ while (0)
 /* Default definitions for size_t and ptrdiff_t.  */
 
 #ifndef SIZE_TYPE
-#define NO_BUILTIN_SIZE_TYPE
 #define SIZE_TYPE (Pmode == DImode ? "long unsigned int" : "unsigned int")
 #endif
 
 #ifndef PTRDIFF_TYPE
-#define NO_BUILTIN_PTRDIFF_TYPE
 #define PTRDIFF_TYPE (Pmode == DImode ? "long int" : "int")
 #endif
 
index c625b9d2cdb58904b57bae0837f2df80c250d08b..f3f9094f7d055a8e43a47f50134e22d040b5a768 100644 (file)
@@ -109,26 +109,14 @@ Boston, MA 02111-1307, USA.  */
    %{EL:-U__MIPSEB__ -D__MIPSEL__}                                     \
    %(subtarget_cpp_spec) "
 
-
-/* Provide a SUBTARGET_CPP_SIZE_SPEC appropriate for NetBSD.  In
-   addition to the normal work done by this spec, we also define
-   __LONG64 or not (so that <machine/ansi.h> can tell).  */
-
-#undef SUBTARGET_CPP_SIZE_SPEC
-#define SUBTARGET_CPP_SIZE_SPEC                                                \
-  "%{mlong64:                                                          \
-     %{!mips1:                                                         \
-       %{!mips2:                                                       \
-        %{!mips32:-D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int -D__LONG64}}}} \
-   %{!mlong64:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int -U__LONG64}"
-
-
 /* Provide a SUBTARGET_CPP_SPEC appropriate for NetBSD.  Currently,
-   we just deal with the GCC option '-posix'.  */
+   we just deal with the GCC option '-posix', and define __LONG64
+   as appropriate for <machine/ansi.h>.  */
 
 #undef SUBTARGET_CPP_SPEC
-#define SUBTARGET_CPP_SPEC "%{posix:-D_POSIX_SOURCE}"
-
+#define SUBTARGET_CPP_SPEC "%{posix:-D_POSIX_SOURCE}    \
+   %{mlong64:%{!mips1:%{!mips2:%{!mips32:-D__LONG64}}}} \
+   %{!mlong64:-U__LONG64}"
 
 /* Provide a LINK_SPEC appropriate for a NetBSD/mips target.
    This is a copy of LINK_SPEC from <netbsd-elf.h> tweaked for
index aa9a585d2b87616ca1e4e5b68d9bf8a46f61d019..62d61e6dffdbfac5fd049f1fcbd8a72de3032896 100644 (file)
@@ -34,10 +34,6 @@ Boston, MA 02111-1307, USA.  */
 -DOSF -DOSF1 -Dbsd4_2 -DMIPSEL -Dhost_mips -Dmips -Dunix -DR3000 -DSYSTYPE_BSD \
 -Asystem=unix -Asystem=xpg4 -Acpu=mips -Amachine=mips"
 
-#define SUBTARGET_CPP_SIZE_SPEC "\
-%{mlong64:-D__PTRDIFF_TYPE__=long\\ int} \
-%{!mlong64:-D__PTRDIFF_TYPE__=int}"
-
 #define SUBTARGET_CPP_SPEC "\
 %{.S:  %{!ansi:%{!traditional-cpp: -traditional}}}"
 
index e178355649005461c38ad545c754a036ac91a0c6..f4f772f94eb05a591dfaebb574a4238d91ca74dc 100644 (file)
@@ -26,9 +26,6 @@ Boston, MA 02111-1307, USA.  */
 -D_mips -D_unix -D_host_mips -D_MIPSEB -D_R3000 -D_SYSTYPE_SVR4 \
 -Asystem=unix -Asystem=svr4 -Acpu=mips -Amachine=mips"
 
-#define SUBTARGET_CPP_SIZE_SPEC "\
--D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int"
-
 #define LINK_SPEC "\
 %{G*} \
 %{!mgas: \
index 121c7ba5caf87db0ee888fbf65a1c271b5383dca..96a6a631852a1eade1fb340bef55eba332285fe1 100644 (file)
@@ -105,9 +105,7 @@ do {                                                                        \
 #undef CPP_SPEC
 #define CPP_SPEC "%{posix: -D_POSIX_SOURCE}\
   %{ansi: -D_ANSI_C_SOURCE}\
-  %{!maix64: -D__WCHAR_TYPE__=short\\ unsigned\\ int}\
-  %{maix64: -D__64BIT__ -D_ARCH_PPC -D__LONG_MAX__=9223372036854775807L \
-    -D__WCHAR_TYPE__=unsigned\\ int}\
+  %{maix64: -D__64BIT__ -D_ARCH_PPC -D__LONG_MAX__=9223372036854775807L}
   %{mpe: -I/usr/lpp/ppe.poe/include}\
   %{pthread: -D_THREAD_SAFE}\
   %(cpp_cpu)"
@@ -120,9 +118,7 @@ do {                                                                        \
    -D_XOPEN_SOURCE_EXTENDED=1                   \
    -D_LARGE_FILE_API                            \
    -D_ALL_SOURCE                                \
-   %{!maix64: -D__WCHAR_TYPE__=short\\ unsigned\\ int}\
-   %{maix64: -D__64BIT__ -D_ARCH_PPC -D__LONG_MAX__=9223372036854775807L \
-     -D__WCHAR_TYPE__=unsigned\\ int}\
+   %{maix64: -D__64BIT__ -D_ARCH_PPC -D__LONG_MAX__=9223372036854775807L}
    %{mpe: -I/usr/lpp/ppe.poe/include}\
    %{pthread: -D_THREAD_SAFE}\
    %(cpp_cpu)"
@@ -207,9 +203,6 @@ do {                                                                        \
 #undef PTRDIFF_TYPE
 #define PTRDIFF_TYPE "long int"
 
-/* __WCHAR_TYPE__ is dynamic, so do not define it statically.  */
-#define NO_BUILTIN_WCHAR_TYPE
-
 /* Type used for wchar_t, as a string used in a declaration.  */
 #undef  WCHAR_TYPE
 #define WCHAR_TYPE (!TARGET_64BIT ? "short unsigned int" : "unsigned int")
index a0336bfecd8596d71d93047577f82d7da415641b..b19561c35ab4ce2c24c050b0574a2a8c1c5a2771 100644 (file)
@@ -50,28 +50,20 @@ Boston, MA 02111-1307, USA.  */
 
 /* Target specific preprocessor settings.  */
 
-#define NO_BUILTIN_SIZE_TYPE
-#define NO_BUILTIN_PTRDIFF_TYPE
-
 #define CPP_PREDEFINES \
   "-Dunix -Asystem(unix) -D__gnu_linux__ -Dlinux -Asystem(linux) -D__ELF__ \
    -Acpu(s390) -Amachine(s390) -D__s390__"
 
-#define CPP_ARCH31_SPEC \
-  "-D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=int"
-#define CPP_ARCH64_SPEC \
-  "-D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int \
-   -D__s390x__ -D__LONG_MAX__=9223372036854775807L"
+#define CPP_ARCH31_SPEC ""
+#define CPP_ARCH64_SPEC "-D__s390x__ -D__LONG_MAX__=9223372036854775807L"
 
-#ifdef DEFAULT_TARGET_64BIT
 #undef  CPP_SPEC
-#define CPP_SPEC "%{m31:%(cpp_arch31)} %{!m31:%(cpp_arch64)}"
+#ifdef DEFAULT_TARGET_64BIT
+#define CPP_SPEC "%{!m31:%(cpp_arch64)}"
 #else
-#undef  CPP_SPEC
-#define CPP_SPEC "%{m64:%(cpp_arch64)} %{!m64:%(cpp_arch31)}"
+#define CPP_SPEC "%{m64:%(cpp_arch64)}"
 #endif
 
-
 /* Target specific compiler settings.  */
 
 /* ??? -fcaller-saves sometimes doesn't work.  Fix this! */
index 5a5094e1c9d9b6cd2d9cfc448ccde44b33ae52bd..18c3b48d0f4cba98300363e5858274bb415f8085 100644 (file)
@@ -56,8 +56,6 @@ extern int code_for_indirect_jump_scratch;
 %{m4-single:-D__SH4_SINGLE__} \
 %{m4-nofpu:-D__sh3__ -D__SH4_NOFPU__} \
 %{m4:-D__SH4__} \
-%{m1|m2|m3*|m4*:-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int} \
-%{m5*:-D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int} \
 %{!m1:%{!m2:%{!m3*:%{!m4*:%{!m5*:%(cpp_default_cpu_spec)}}}}} \
 %{mhitachi:-D__HITACHI__} \
 %(subtarget_cpp_spec) \
@@ -72,8 +70,7 @@ extern int code_for_indirect_jump_scratch;
 #endif
 
 #ifndef CPP_DEFAULT_CPU_SPEC
-#define CPP_DEFAULT_CPU_SPEC \
-  "-D__sh1__ -D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int"
+#define CPP_DEFAULT_CPU_SPEC "-D__sh1__"
 #endif
 
 
@@ -2509,14 +2506,9 @@ while (0)
 /* 'char' is signed by default.  */
 #define DEFAULT_SIGNED_CHAR  1
 
-/* We -Define SIZE_TYPE in CPP_SPEC.  */
-#define NO_BUILTIN_SIZE_TYPE 1
-
 /* The type of size_t unsigned int.  */
 #define SIZE_TYPE (TARGET_SH5 ? "long unsigned int" : "unsigned int")
 
-#define NO_BUILTIN_PTRDIFF_TYPE 1
-
 #undef  PTRDIFF_TYPE
 #define PTRDIFF_TYPE (TARGET_SH5 ? "long int" : "int")
 
index a2e225d841ba737c6efa1e9ee8f5a833f82acc8c..1797cd77f241e54388e13781335986eaf6f88cb1 100644 (file)
@@ -24,8 +24,7 @@ Boston, MA 02111-1307, USA.  */
   fputs (" (SuperH SH)", stderr);
 
 #undef CPP_DEFAULT_CPU_SPEC
-#define CPP_DEFAULT_CPU_SPEC "-D__SH5__=32 -D__SHMEDIA__ \
--D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int"
+#define CPP_DEFAULT_CPU_SPEC "-D__SH5__=32 -D__SHMEDIA__"
 
 #undef ASM_SPEC
 #define ASM_SPEC  "%(subtarget_asm_endian_spec) %{mrelax:-relax} \
index 105f95496d87578e090acc20189ff9f0474170f4..d29f6aa597df5c06b486cece1d6583ff83a2ac0c 100644 (file)
@@ -44,7 +44,6 @@ Boston, MA 02111-1307, USA.  */
 
 #undef CPP_ARCH32_SPEC
 #define CPP_ARCH32_SPEC "%{mlong-double-128:-D__LONG_DOUBLE_128__} \
--D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int \
 -D__GCC_NEW_VARARGS__ -Acpu=sparc -Amachine=sparc"
 
 #endif
index 43b3e5063efc900259ac4ac3129a870b05f19ea3..f4ffb68c49efac98ba797e9b7786bd2a803fda3d 100644 (file)
@@ -37,22 +37,6 @@ Boston, MA 02111-1307, USA.  */
 #undef CPP_SUBTARGET_SPEC32
 #define CPP_SUBTARGET_SPEC32 "-D__sparc %{posix:-D_POSIX_SOURCE}"
 
-/* CPP_ARCH32_SPEC and CPP_ARCH64_SPEC are wrong from sparc/sparc.h; we
-   always want the non-SPARC_BI_ARCH versions, since the SPARC_BI_ARCH
-   versions define __SIZE_TYPE__ and __PTRDIFF_TYPE__ incorrectly for
-   NetBSD.  */
-#undef CPP_ARCH32_SPEC
-#define CPP_ARCH32_SPEC "-D__GCC_NEW_VARARGS__ -Acpu=sparc -Amachine=sparc"
-
-#undef CPP_ARCH64_SPEC
-#define CPP_ARCH64_SPEC "-D__arch64__ -Acpu=sparc64 -Amachine=sparc64"
-
-/* sparc/sparc.h defines NO_BUILTIN_SIZE_TYPE and NO_BUILTIN_PTRDIFF_TYPE
-   if SPARC_BI_ARCH is defined.  This is wrong for NetBSD; size_t and
-   ptrdiff_t do not change for 32-bit vs. 64-bit.  */
-#undef NO_BUILTIN_PTRDIFF_TYPE
-#undef NO_BUILTIN_SIZE_TYPE
-
 /* SIZE_TYPE and PTRDIFF_TYPE are wrong from sparc/sparc.h.  */
 #undef SIZE_TYPE
 #define SIZE_TYPE "long unsigned int"
index d097a20db94eddb618fa74274dac2734a0a6f426..fcb65dab31ae731cdaa1a82beae086add2671b4e 100644 (file)
 /* wchar_t is called differently in <wchar.h> for 32 and 64-bit
    compilations.  This is called for by SCD 2.4.1, p. 6-83, Figure 6-65
    (32-bit) and p. 6P-10, Figure 6.38 (64-bit).  */
-#define NO_BUILTIN_WCHAR_TYPE
 
 #undef WCHAR_TYPE
 #define WCHAR_TYPE (TARGET_ARCH64 ? "int" : "long int")
 /* Same for wint_t.  See SCD 2.4.1, p. 6-83, Figure 6-66 (32-bit).  There's
    no corresponding 64-bit definition, but this is what Solaris 8
    <iso/wchar_iso.h> uses.  */
-#define NO_BUILTIN_WINT_TYPE
 
 #undef WINT_TYPE
 #define WINT_TYPE (TARGET_ARCH64 ? "int" : "long int")
 #define WINT_TYPE_SIZE 32
 
 #undef CPP_ARCH32_SPEC
-#define CPP_ARCH32_SPEC "-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int \
--D__WCHAR_TYPE__=long\\ int -D__WINT_TYPE__=long\\ int \
+#define CPP_ARCH32_SPEC "\
 -D__GCC_NEW_VARARGS__ -Acpu=sparc -Amachine=sparc"
 #undef CPP_ARCH64_SPEC
-#define CPP_ARCH64_SPEC "-D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int \
--D__WCHAR_TYPE__=int -D__WINT_TYPE__=int \
+#define CPP_ARCH64_SPEC "\
 -D__arch64__ -Acpu=sparc64 -Amachine=sparcv9 -D__sparcv9"
 
 #undef CPP_ARCH_SPEC
index 1b3b2ead507a12a672bebb51724a2e52c4657eb4..8429a7f554b17e48618713f587a982caec8573a8 100644 (file)
@@ -246,20 +246,9 @@ Unrecognized value in TARGET_CPU_DEFAULT.
    sparc64 in 32 bit environments, so for now we only use `sparc64' in
    64 bit environments.  */
 
-#ifdef SPARC_BI_ARCH
-
-#define CPP_ARCH32_SPEC "-D__SIZE_TYPE__=unsigned\\ int -D__PTRDIFF_TYPE__=int \
--D__GCC_NEW_VARARGS__ -Acpu=sparc -Amachine=sparc"
-#define CPP_ARCH64_SPEC "-D__SIZE_TYPE__=long\\ unsigned\\ int -D__PTRDIFF_TYPE__=long\\ int \
--D__arch64__ -Acpu=sparc64 -Amachine=sparc64"
-
-#else
-
 #define CPP_ARCH32_SPEC "-D__GCC_NEW_VARARGS__ -Acpu=sparc -Amachine=sparc"
 #define CPP_ARCH64_SPEC "-D__arch64__ -Acpu=sparc64 -Amachine=sparc64"
 
-#endif
-
 #define CPP_ARCH_DEFAULT_SPEC \
 (DEFAULT_ARCH32_P ? CPP_ARCH32_SPEC : CPP_ARCH64_SPEC)
 
@@ -372,10 +361,6 @@ Unrecognized value in TARGET_CPU_DEFAULT.
 #define LINK_GCC_C_SEQUENCE_SPEC "%G %L %G %L"
 
 \f
-#ifdef SPARC_BI_ARCH
-#define NO_BUILTIN_PTRDIFF_TYPE
-#define NO_BUILTIN_SIZE_TYPE
-#endif
 #define PTRDIFF_TYPE (TARGET_ARCH64 ? "long int" : "int")
 #define SIZE_TYPE (TARGET_ARCH64 ? "long unsigned int" : "unsigned int")
 
index cda691d59567c90cff80df08a24ffbdea1d3f634..5d5d74aadf6a9ae5a7b053fa19463422e4b60346 100644 (file)
@@ -48,30 +48,6 @@ Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
    it would be best to do something here to figure out automatically
    from other information what type to use.  */
 
-/* The string value for __SIZE_TYPE__.  */
-
-#ifndef SIZE_TYPE
-#define SIZE_TYPE "long unsigned int"
-#endif
-
-/* The string value for __PTRDIFF_TYPE__.  */
-
-#ifndef PTRDIFF_TYPE
-#define PTRDIFF_TYPE "long int"
-#endif
-
-/* The string value for __WCHAR_TYPE__.  */
-
-#ifndef WCHAR_TYPE
-#define WCHAR_TYPE "int"
-#endif
-
-/* The string value for __WINT_TYPE__.  */
-
-#ifndef WINT_TYPE
-#define WINT_TYPE "unsigned int"
-#endif
-
 /* The string value for __USER_LABEL_PREFIX__ */
 
 #ifndef USER_LABEL_PREFIX
index 7042cd27988582baa4d5a736eebad9edc1507a39..57fa4c0fa1b8718a55adf266d4dbd65536726dd1 100644 (file)
@@ -662,18 +662,6 @@ static const struct builtin builtin_array[] =
   X("__USER_LABEL_PREFIX__",   ULP),
   C("__REGISTER_PREFIX__",     REGISTER_PREFIX),
   C("__HAVE_BUILTIN_SETJMP__", "1"),
-#ifndef NO_BUILTIN_SIZE_TYPE
-  C("__SIZE_TYPE__",           SIZE_TYPE),
-#endif
-#ifndef NO_BUILTIN_PTRDIFF_TYPE
-  C("__PTRDIFF_TYPE__",                PTRDIFF_TYPE),
-#endif
-#ifndef NO_BUILTIN_WCHAR_TYPE
-  C("__WCHAR_TYPE__",          WCHAR_TYPE),
-#endif
-#ifndef NO_BUILTIN_WINT_TYPE
-  C("__WINT_TYPE__",           WINT_TYPE),
-#endif
 #ifdef STDC_0_IN_SYSTEM_HEADERS
   B("__STDC__",                 BT_STDC),
 #else
index 36ccaebcd3508233a576a63457332999a28978b4..8d4e92522c53909aabaf17bde72feb27e06c9fb3 100644 (file)
@@ -177,46 +177,6 @@ This macro is just like @code{CPP_SPEC}, but is used for C++, rather
 than C@.  If you do not define this macro, then the value of
 @code{CPP_SPEC} (if any) will be used instead.
 
-@findex NO_BUILTIN_SIZE_TYPE
-@item NO_BUILTIN_SIZE_TYPE
-If this macro is defined, the preprocessor will not define the built-in macro
-@code{__SIZE_TYPE__}.  The macro @code{__SIZE_TYPE__} must then be defined
-by @code{CPP_SPEC} instead.
-
-This should be defined if @code{SIZE_TYPE} depends on target dependent flags
-which are not accessible to the preprocessor.  Otherwise, it should not
-be defined.
-
-@findex NO_BUILTIN_PTRDIFF_TYPE
-@item NO_BUILTIN_PTRDIFF_TYPE
-If this macro is defined, the preprocessor will not define the built-in macro
-@code{__PTRDIFF_TYPE__}.  The macro @code{__PTRDIFF_TYPE__} must then be
-defined by @code{CPP_SPEC} instead.
-
-This should be defined if @code{PTRDIFF_TYPE} depends on target dependent flags
-which are not accessible to the preprocessor.  Otherwise, it should not
-be defined.
-
-@findex NO_BUILTIN_WCHAR_TYPE
-@item NO_BUILTIN_WCHAR_TYPE
-If this macro is defined, the preprocessor will not define the built-in macro
-@code{__WCHAR_TYPE__}.  The macro @code{__WCHAR_TYPE__} must then be
-defined by @code{CPP_SPEC} instead.
-
-This should be defined if @code{WCHAR_TYPE} depends on target dependent flags
-which are not accessible to the preprocessor.  Otherwise, it should not
-be defined.
-
-@findex NO_BUILTIN_WINT_TYPE
-@item NO_BUILTIN_WINT_TYPE
-If this macro is defined, the preprocessor will not define the built-in macro
-@code{__WINT_TYPE__}.  The macro @code{__WINT_TYPE__} must then be
-defined by @code{CPP_SPEC} instead.
-
-This should be defined if @code{WINT_TYPE} depends on target dependent flags
-which are not accessible to the preprocessor.  Otherwise, it should not
-be defined.
-
 @findex CC1_SPEC
 @item CC1_SPEC
 A C string constant that tells the GCC driver program options to
index b9672721efa269b56e46d60f55f805528f451ceb..0b8e36365e5089d3aac4f833c803d6e139ac41bc 100644 (file)
--- a/gcc/gcc.c
+++ b/gcc/gcc.c
@@ -684,7 +684,6 @@ static const char *cpp_unique_options =
  %{!undef:%{!ansi:%{!std=*:%p}%{std=gnu*:%p}} %P} %{trigraphs}\
  %{Os:-D__OPTIMIZE_SIZE__} %{O*:%{!O0:-D__OPTIMIZE__}}\
  %{fno-inline|O0|!O*:-D__NO_INLINE__} %{ffast-math:-D__FAST_MATH__}\
- %{fshort-wchar:-U__WCHAR_TYPE__ -D__WCHAR_TYPE__=short\\ unsigned\\ int}\
  %{ffreestanding:-D__STDC_HOSTED__=0} %{fno-hosted:-D__STDC_HOSTED__=0}\
  %{!ffreestanding:%{!fno-hosted:-D__STDC_HOSTED__=1}} %{remap}\
  %{g3:-dD} %{H} %C %{D*&U*&A*} %{i*} %Z %i\
index e12585b3fb0bc6cd126933953a59bde45476c505..0a4c0c6b20383022edd40f3d7463b27fab02f242 100644 (file)
@@ -607,7 +607,8 @@ typedef char _Bool;
        LONGJMP_RESTORE_FROM_STACK MAX_INT_TYPE_SIZE ASM_IDENTIFY_GCC      \
        STDC_VALUE TRAMPOLINE_ALIGN ASM_IDENTIFY_GCC_AFTER_SOURCE          \
        SLOW_ZERO_EXTEND SUBREG_REGNO_OFFSET DWARF_LINE_MIN_INSTR_LENGTH   \
-       TRADITIONAL_RETURN_FLOAT
+       TRADITIONAL_RETURN_FLOAT NO_BUILTIN_SIZE_TYPE                      \
+       NO_BUILTIN_PTRDIFF_TYPE NO_BUILTIN_WCHAR_TYPE NO_BUILTIN_WINT_TYPE
 
 #endif /* IN_GCC */
 
index 203b8cc7b3940a3c87e11ec515e8ccfa232ecbbc..9caf45e6bc0f177450650b4883247cfaa5e9211b 100644 (file)
@@ -5149,18 +5149,6 @@ initialize_builtins ()
   install_spec ("__INCLUDE_LEVEL__", T_INCLUDE_LEVEL);
   install_spec ("__LINE__",          T_SPECLINE);
 
-#ifndef NO_BUILTIN_SIZE_TYPE
-  install_value ("__SIZE_TYPE__",         SIZE_TYPE);
-#endif
-#ifndef NO_BUILTIN_PTRDIFF_TYPE
-  install_value ("__PTRDIFF_TYPE__",      PTRDIFF_TYPE);
-#endif
-#ifndef NO_BUILTIN_WCHAR_TYPE
-  install_value ("__WCHAR_TYPE__",        WCHAR_TYPE);
-#endif
-#ifndef NO_BUILTIN_WINT_TYPE
-  install_value ("__WINT_TYPE__",         WINT_TYPE);
-#endif
   install_value ("__REGISTER_PREFIX__",   REGISTER_PREFIX);
   install_value ("__USER_LABEL_PREFIX__", user_label_prefix);