summaryrefslogtreecommitdiff
path: root/gnu
diff options
context:
space:
mode:
authorthorpej <thorpej@NetBSD.org>2003-06-14 16:02:57 +0000
committerthorpej <thorpej@NetBSD.org>2003-06-14 16:02:57 +0000
commit1d99a54efedfa2fbb28bb0f0cd6e051e6e71d51c (patch)
treebf986bf640226000765286f7fe1bacdf137579e5 /gnu
parent17ae4777802f298b818ced1c346a15af6e23bf2a (diff)
Bring in the following patch from FSF binutils mainline:
2003-06-13 Richard Earnshaw <rearnsha@arm.com> * tc-arm.c (FPU_DEFAULT, case TE_LINUX): Default to FPU_ARCH_FPA. (FPU_DEFAULT, case TE_NetBSD): Default to FPU_ARCH_VFP for ELF, FPU_ARCH_FPA for AOUT. (md_begin): Don't try to guess the floating point architecture from the CPU if the OS ABI (Linux, NetBSD) mandates a particular form. ...per Richard's suggestion.
Diffstat (limited to 'gnu')
-rw-r--r--gnu/dist/toolchain/gas/config/tc-arm.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/gnu/dist/toolchain/gas/config/tc-arm.c b/gnu/dist/toolchain/gas/config/tc-arm.c
index 6ce8cfc78c0..9872d2b13ed 100644
--- a/gnu/dist/toolchain/gas/config/tc-arm.c
+++ b/gnu/dist/toolchain/gas/config/tc-arm.c
@@ -132,6 +132,18 @@
#endif
#endif
+#ifdef TE_LINUX
+#define FPU_DEFAULT FPU_ARCH_FPA
+#endif
+
+#ifdef TE_NetBSD
+#ifdef OBJ_ELF
+#define FPU_DEFAULT FPU_ARCH_VFP /* Soft-float, but VFP order. */
+#else
+#define FPU_DEFAULT FPU_ARCH_FPA /* Soft-float, but FPA order. */
+#endif
+#endif
+
/* For backwards compatibility we default to the FPA. */
#ifndef FPU_DEFAULT
#define FPU_DEFAULT FPU_ARCH_FPA
@@ -9253,10 +9265,16 @@ md_begin ()
}
else if (mfpu_opt == -1)
{
+#if !(defined (TE_LINUX) || defined(TE_NetBSD))
+ /* Some environments specify a default FPU. If they don't, infer
+ it from the processor. */
if (mcpu_fpu_opt != -1)
mfpu_opt = mcpu_fpu_opt;
else
mfpu_opt = march_fpu_opt;
+#else
+ mfpu_opt = FPU_DEFAULT;
+#endif
}
if (mfpu_opt == -1)