===================================================================
@@ -1813,7 +1813,6 @@ mips*-mti-linux*)
tm_defines="${tm_defines} MIPS_ISA_DEFAULT=33 MIPS_ABI_DEFAULT=ABI_32"
gnu_ld=yes
gas=yes
- test x$with_llsc != x || with_llsc=yes
;;
mips64*-*-linux* | mipsisa64*-*-linux*)
tm_file="dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h ${tm_file} mips/gnu-user.h mips/gnu-user64.h mips/linux64.h mips/linux-common.h"
@@ -1834,7 +1833,6 @@ mips64*-*-linux* | mipsisa64*-*-linux*)
esac
gnu_ld=yes
gas=yes
- test x$with_llsc != x || with_llsc=yes
;;
mips*-*-linux*) # Linux MIPS, either endian.
tm_file="dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h ${tm_file} mips/gnu-user.h mips/linux.h"
@@ -1850,7 +1848,6 @@ mips*-*-linux*) # Linux MIPS, either
mipsisa32*)
tm_defines="${tm_defines} MIPS_ISA_DEFAULT=32"
esac
- test x$with_llsc != x || with_llsc=yes
;;
mips*-mti-elf*)
tm_file="elfos.h newlib-stdint.h ${tm_file} mips/elf.h mips/sde.h mips/mti-elf.h"
@@ -2982,22 +2979,6 @@ if test x$with_cpu = x ; then
;;
esac
;;
- mips64r5900-*-* | mips64r5900el-*-* | mipsr5900-*-* | mipsr5900el-*-*)
- with_arch=r5900
- with_tune=r5900
- if test x$with_llsc = x; then
- # r5900 doesn't support ll, sc, lld and scd instructions:
- with_llsc=no
- fi
- if test x$with_float = x; then
- # r5900 doesn't support 64 bit float:
- # 32 bit float doesn't comply with IEEE 754.
- with_float=soft
- fi
- ;;
- mips*-*-vxworks)
- with_arch=mips2
- ;;
powerpc*-*-*spe*)
if test x$enable_e500_double = xyes; then
with_cpu=8548
@@ -3058,6 +3039,12 @@ if test x$with_arch = x ; then
x86_64-*-*)
with_arch=$arch
;;
+ mips64r5900-*-* | mips64r5900el-*-* | mipsr5900-*-* | mipsr5900el-*-*)
+ with_arch=r5900
+ ;;
+ mips*-*-vxworks)
+ with_arch=mips2
+ ;;
esac
# Avoid overriding --with-arch-32 and --with-arch-64 values.
@@ -3092,6 +3079,17 @@ if test x$with_arch = x ; then
esac
fi
+# Infer a default setting for --with-float.
+if test x$with_float = x; then
+ case ${target} in
+ mips64r5900-*-* | mips64r5900el-*-* | mipsr5900-*-* | mipsr5900el-*-*)
+ # The R5900 doesn't support 64-bit float. 32-bit float doesn't
+ # comply with IEEE 754.
+ with_float=soft
+ ;;
+ esac
+fi
+
# Support --with-fpmath.
if test x$with_fpmath != x; then
case ${target} in
@@ -3126,6 +3124,20 @@ if test x$with_schedule = x; then
esac
fi
+# Infer a default setting for --with-llsc.
+if test x$with_llsc = x; then
+ case ${target} in
+ mips64r5900-*-* | mips64r5900el-*-* | mipsr5900-*-* | mipsr5900el-*-*)
+ # The R5900 doesn't support LL(D) and SC(D).
+ with_llsc=no
+ ;;
+ mips*-*-linux*)
+ # The kernel emulates LL and SC where necessary.
+ with_llsc=yes
+ ;;
+ esac
+fi
+
# Validate and mark as valid any --with options supported
# by this target. In order to use a particular --with option
# you must list it in supported_defaults; validating the value