2005-04-11 Geoffrey Keating <geoffk@apple.com>
+ * config/i386/i386.h (TARGET_FPMATH_DEFAULT): New.
+ * config/i386/darwin.h (TARGET_FPMATH_DEFAULT): New.
+ * config/i386/i386.c (override_options): Use TARGET_FPMATH_DEFAULT.
+
+ * config/i386/darwin.h (ASM_SPEC): Use -arch i386 not -arch i686.
+ (SUBTARGET_EXTRA_SPECS): Always 'i386'.
+
* dwarf2out.c (output_line_info): Don't try to dereference
a NULL current_function_decl.
/* Target definitions for x86 running Darwin.
- Copyright (C) 2001, 2002, 2004 Free Software Foundation, Inc.
+ Copyright (C) 2001, 2002, 2004, 2005 Free Software Foundation, Inc.
Contributed by Apple Computer Inc.
This file is part of GCC.
#define TARGET_VERSION fprintf (stderr, " (i686 Darwin)");
+#undef TARGET_FPMATH_DEFAULT
+#define TARGET_FPMATH_DEFAULT (TARGET_SSE ? FPMATH_SSE : FPMATH_387)
+
#define TARGET_OS_CPP_BUILTINS() \
do \
{ \
%{g: %{!fno-eliminate-unused-debug-symbols: -feliminate-unused-debug-symbols }}"
#undef ASM_SPEC
-#define ASM_SPEC "-arch i686 -force_cpusubtype_ALL"
+#define ASM_SPEC "-arch i386 -force_cpusubtype_ALL"
#undef SUBTARGET_EXTRA_SPECS
#define SUBTARGET_EXTRA_SPECS \
- { "darwin_arch", "i686" }, \
- { "darwin_subarch", "%{march=pentium3:pentIIm3;:i686}" },
-
+ { "darwin_arch", "i386" }, \
+ { "darwin_subarch", "i386" },
/* Use the following macro for any Darwin/x86-specific command-line option
translation. */
target_flags
|= ((MASK_SSE2 | MASK_SSE | MASK_MMX | MASK_128BIT_LONG_DOUBLE)
& ~target_flags_explicit);
-
- if (TARGET_SSE)
- ix86_fpmath = FPMATH_SSE;
}
else
{
- ix86_fpmath = FPMATH_387;
/* i386 ABI does not specify red zone. It still makes sense to use it
when programmer takes care to stack from being destroyed. */
if (!(target_flags_explicit & MASK_NO_RED_ZONE))
target_flags |= MASK_NO_RED_ZONE;
}
+ ix86_fpmath = TARGET_FPMATH_DEFAULT;
+
if (ix86_fpmath_string != 0)
{
if (! strcmp (ix86_fpmath_string, "387"))
#endif
#endif
+#ifndef TARGET_FPMATH_DEFAULT
+#define TARGET_FPMATH_DEFAULT \
+ (TARGET_64BIT && TARGET_SSE ? FPMATH_SSE : FPMATH_387)
+#endif
+
/* Masks for the -m switches */
#define MASK_80387 0x00000001 /* Hardware floating point */
#define MASK_RTD 0x00000002 /* Use ret that pops args */