aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJim Wilson <wilson@cygnus.com>1998-04-18 18:36:11 +0000
committerJim Wilson <wilson@gcc.gnu.org>1998-04-18 11:36:11 -0700
commit84b77fbac21bc09d4ed02a35547b1a72e60aacfb (patch)
tree67a8826d6d883ca86b2beafd5b72348e6d5fd4a8
parentdb72d7a1d62b2034c01d0ac725a27e887957486d (diff)
downloadgcc-84b77fbac21bc09d4ed02a35547b1a72e60aacfb.zip
gcc-84b77fbac21bc09d4ed02a35547b1a72e60aacfb.tar.gz
gcc-84b77fbac21bc09d4ed02a35547b1a72e60aacfb.tar.bz2
Patch from Ulrich to fix problems with default CPU defines.
* i386.h (CPP_CPU_DEFAULT): Renamed to CPP_CPU_DEFAULT_SPEC. Add missing -Dpentium* options. (CPP_CPU_SPEC): Delete redundant definition. Include cpp_cpu_default instead of CPP_CPU_DEFAULT. (EXTRA_SPECS): Add entry for cpp_cpu_default. From-SVN: r19284
-rw-r--r--gcc/ChangeLog8
-rw-r--r--gcc/config/i386/i386.h29
2 files changed, 20 insertions, 17 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 8a8b192..37aed52 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,11 @@
+Sat Apr 18 18:30:22 1998 Jim Wilson <wilson@cygnus.com>
+
+ * i386.h (CPP_CPU_DEFAULT): Renamed to CPP_CPU_DEFAULT_SPEC.
+ Add missing -Dpentium* options.
+ (CPP_CPU_SPEC): Delete redundant definition. Include cpp_cpu_default
+ instead of CPP_CPU_DEFAULT.
+ (EXTRA_SPECS): Add entry for cpp_cpu_default.
+
Sat Apr 18 19:06:59 1998 David Edelsohn <edelsohn@mhpcc.edu>
* rs6000.md (floatsidf2_loadaddr): rs6000_fpmem_offset will be
diff --git a/gcc/config/i386/i386.h b/gcc/config/i386/i386.h
index 8775a5b..00ae6bb 100644
--- a/gcc/config/i386/i386.h
+++ b/gcc/config/i386/i386.h
@@ -304,36 +304,30 @@ extern int ix86_arch;
%{mpentiumpro:-mcpu=pentiumpro}}"
#endif
-#ifndef CPP_CPU_SPEC
-#ifdef __STDC__
+#ifndef CPP_CPU_DEFAULT_SPEC
#if TARGET_CPU_DEFAULT == 1
-#define CPP_CPU_DEFAULT "-Di486"
+#define CPP_CPU_DEFAULT_SPEC "-Di486"
#else
#if TARGET_CPU_DEFAULT == 2
-#define CPP_CPU_DEFAULT "-Di586"
+#define CPP_CPU_DEFAULT_SPEC "-Dpentium -Di586"
#else
#if TARGET_CPU_DEFAULT == 3
-#define CPP_CPU_DEFAULT "-Di686"
+#define CPP_CPU_DEFAULT_SPEC "-Dpentiumpro -Di686"
#else
-#define CPP_CPU_DEFAULT ""
+#define CPP_CPU_DEFAULT_SPEC ""
#endif
#endif
-#endif /* TARGET_CPU_DEFAULT */
-
-#define CPP_CPU_SPEC "\
--Di386 " CPP_CPU_DEFAULT " -Asystem(unix) -Acpu(i386) -Amachine(i386) \
-%{mcpu=i486:-Di486} %{m486:-Di486} \
-%{mpentium:-Dpentium -Di586} %{mcpu=pentium:-Dpentium -Di586} \
-%{mpentiumpro:-Dpentiumpro -Di686} %{mcpu=pentiumpro:-Dpentiumpro -Di686}"
+#endif
+#endif /* CPP_CPU_DEFAULT_SPEC */
-#else
+#ifndef CPP_CPU_SPEC
#define CPP_CPU_SPEC "\
-Di386 -Asystem(unix) -Acpu(i386) -Amachine(i386) \
%{mcpu=i486:-Di486} %{m486:-Di486} \
%{mpentium:-Dpentium -Di586} %{mcpu=pentium:-Dpentium -Di586} \
-%{mpentiumpro:-Dpentiumpro -Di686} %{mcpu=pentiumpro:-Dpentiumpro -Di686}"
-#endif /* __STDC__ */
-#endif /* CPP_CPU_SPEC */
+%{mpentiumpro:-Dpentiumpro -Di686} %{mcpu=pentiumpro:-Dpentiumpro -Di686} \
+%{!mcpu*:%{!m486:%{!mpentium*: %[cpp_cpu_default]}}}"
+#endif
#ifndef CC1_SPEC
#define CC1_SPEC "%(cc1_spec) "
@@ -354,6 +348,7 @@ extern int ix86_arch;
#endif
#define EXTRA_SPECS \
+ { "cpp_cpu_default", CPP_CPU_DEFAULT_SPEC }, \
{ "cpp_cpu", CPP_CPU_SPEC }, \
{ "cc1_cpu", CC1_CPU_SPEC }, \
SUBTARGET_EXTRA_SPECS