+2015-12-09 Aurelien Jarno <aurelien@aurel32.net>
+
+ * sysdeps/unix/sysv/linux/mips/configure.ac (has-mpf64): Define to
+ record the current if the current ABI and CPU support the FP64
+ extension.
+ (has-modd-spreg): Define to record the current if the current ABI and
+ CPU support 32-bit floating point values in odd FPU registers.
+ * sysdeps/unix/sysv/linux/mips/configure: Regenerate.
+ * sysdeps/mips/Makefile (tst-abi-fpxxomod): Only build when
+ $(has-modd-spreg) equals yes.
+ (tst-abi-fp64amod): Only build when $(has-mpf64) equals yes.
+ (tst-abi-fp64mod): Only build when both $(has-mpf64) and
+ $(has-modd-spreg) equal yes.
+
2015-12-09 Aurelien Jarno <aurelien@aurel32.net>
* sysdeps/unix/grantpt.c (grantpt): Call__basename instead of
CFLAGS-tst-abi-fpxxmod.c += -mfpxx -mno-odd-spreg
endif
ifneq (,$(filter $(o32-fpabi),xx xxo))
+ifeq ($(has-modd-spreg),yes)
fpabi-modules-names += tst-abi-fpxxomod
CFLAGS-tst-abi-fpxxomod.c += -mfpxx -modd-spreg
endif
+endif
ifneq (,$(filter $(o32-fpabi),xx 64a))
+ifeq ($(has-mpf64),yes)
fpabi-modules-names += tst-abi-fp64amod
CFLAGS-tst-abi-fp64amod.c += -mfp64 -mno-odd-spreg
endif
+endif
ifneq (,$(filter $(o32-fpabi),xx xxo 64a 64))
+ifeq ($(has-mpf64)-$(has-modd-spreg),yes-yes)
fpabi-modules-names += tst-abi-fp64mod
CFLAGS-tst-abi-fp64mod.c += -mfp64 -modd-spreg
endif
+endif
modules-names += $(fpabi-modules-names)
comma:=,
fi
libc_mips_o32_fp=
+libc_cv_mips_fp64=
+libc_cv_mips_modd_spreg=
if test x"$libc_mips_abi" = xo32 -a x"$libc_mips_float" = xhard; then
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+ if { ac_try='${CC-cc} -mfp64 -xc /dev/null -S -o /dev/null'
+ { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; }; then :
+ libc_cv_mips_fp64=yes
+else
+ libc_cv_mips_fp64=no
+fi
+ if { ac_try='${CC-cc} -Werror -modd-spreg -xc /dev/null -S -o /dev/null'
+ { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; }; then :
+ libc_cv_mips_modd_spreg=yes
+else
+ libc_cv_mips_modd_spreg=no
+fi
fi
config_vars="$config_vars
o32-fpabi = ${libc_mips_o32_fp}"
+config_vars="$config_vars
+has-mpf64 = ${libc_cv_mips_fp64}"
+config_vars="$config_vars
+has-modd-spreg = ${libc_cv_mips_modd_spreg}"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
fi
libc_mips_o32_fp=
+libc_cv_mips_fp64=
+libc_cv_mips_modd_spreg=
if test x"$libc_mips_abi" = xo32 -a x"$libc_mips_float" = xhard; then
AC_COMPILE_IFELSE(
[libc_mips_o32_fp=64],
[])])])])])],
[])
+
+ LIBC_TRY_CC_OPTION([-mfp64], [libc_cv_mips_fp64=yes], [libc_cv_mips_fp64=no])
+ LIBC_TRY_CC_OPTION([-Werror -modd-spreg], [libc_cv_mips_modd_spreg=yes], [libc_cv_mips_modd_spreg=no])
fi
LIBC_CONFIG_VAR([o32-fpabi],[${libc_mips_o32_fp}])
+LIBC_CONFIG_VAR([has-mpf64],[${libc_cv_mips_fp64}])
+LIBC_CONFIG_VAR([has-modd-spreg],[${libc_cv_mips_modd_spreg}])
AC_COMPILE_IFELSE(
[AC_LANG_PROGRAM([