Default SSE2 off on iX86, since gcc will use it for floating point operations
even if -mfpmath=387 is set. Grr... --HG-- extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/trunk%403317
This commit is contained in:
parent
f9312a8957
commit
d60660c1de
1 changed files with 26 additions and 26 deletions
52
configure.in
52
configure.in
|
@ -285,6 +285,30 @@ AC_HELP_STRING([--enable-assembly], [Enable assembly routines [[default=yes]]]),
|
||||||
if test x$enable_assembly = xyes; then
|
if test x$enable_assembly = xyes; then
|
||||||
AC_DEFINE(SDL_ASSEMBLY_ROUTINES)
|
AC_DEFINE(SDL_ASSEMBLY_ROUTINES)
|
||||||
|
|
||||||
|
# Make sure that we don't generate floating point code that would
|
||||||
|
# cause illegal instruction exceptions on older processors
|
||||||
|
case "$host" in
|
||||||
|
*-*-darwin*)
|
||||||
|
# Don't need to worry about Apple hardware, it's all SSE capable
|
||||||
|
default_ssemath=yes
|
||||||
|
;;
|
||||||
|
*64-*-*)
|
||||||
|
# x86 64-bit architectures all have SSE instructions
|
||||||
|
default_ssemath=yes
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
default_ssemath=no
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
AC_ARG_ENABLE(ssemath,
|
||||||
|
AC_HELP_STRING([--enable-ssemath], [Allow GCC to use SSE floating point math [[default=no]]]),
|
||||||
|
, enable_ssemath=$default_ssemath)
|
||||||
|
if test x$enable_ssemath = xno; then
|
||||||
|
if test x$have_gcc_sse = xyes -o x$have_gcc_sse2 = xyes; then
|
||||||
|
EXTRA_CFLAGS="$EXTRA_CFLAGS -mfpmath=387"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
dnl Check for various instruction support
|
dnl Check for various instruction support
|
||||||
AC_ARG_ENABLE(mmx,
|
AC_ARG_ENABLE(mmx,
|
||||||
AC_HELP_STRING([--enable-mmx], [use MMX assembly routines [[default=yes]]]),
|
AC_HELP_STRING([--enable-mmx], [use MMX assembly routines [[default=yes]]]),
|
||||||
|
@ -368,8 +392,8 @@ AC_HELP_STRING([--enable-sse], [use SSE assembly routines [[default=yes]]]),
|
||||||
fi
|
fi
|
||||||
|
|
||||||
AC_ARG_ENABLE(sse2,
|
AC_ARG_ENABLE(sse2,
|
||||||
AC_HELP_STRING([--enable-sse2], [use SSE2 assembly routines [[default=yes]]]),
|
AC_HELP_STRING([--enable-sse2], [use SSE2 assembly routines [[default=no]]]),
|
||||||
, enable_sse2=yes)
|
, enable_sse2=$default_ssemath)
|
||||||
if test x$enable_sse2 = xyes; then
|
if test x$enable_sse2 = xyes; then
|
||||||
save_CFLAGS="$CFLAGS"
|
save_CFLAGS="$CFLAGS"
|
||||||
have_gcc_sse2=no
|
have_gcc_sse2=no
|
||||||
|
@ -394,30 +418,6 @@ AC_HELP_STRING([--enable-sse2], [use SSE2 assembly routines [[default=yes]]]),
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Make sure that we don't generate floating point code that would
|
|
||||||
# cause illegal instruction exceptions on older processors
|
|
||||||
case "$host" in
|
|
||||||
*-*-darwin*)
|
|
||||||
# Don't need to worry about Apple hardware, it's all SSE capable
|
|
||||||
default_ssemath=yes
|
|
||||||
;;
|
|
||||||
*64-*-*)
|
|
||||||
# x86 64-bit architectures all have SSE instructions
|
|
||||||
default_ssemath=yes
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
default_ssemath=no
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
AC_ARG_ENABLE(ssemath,
|
|
||||||
AC_HELP_STRING([--enable-ssemath], [Allow GCC to use SSE floating point math [[default=no]]]),
|
|
||||||
, enable_ssemath=$default_ssemath)
|
|
||||||
if test x$enable_ssemath = xno; then
|
|
||||||
if test x$have_gcc_sse = xyes -o x$have_gcc_sse2 = xyes; then
|
|
||||||
EXTRA_CFLAGS="$EXTRA_CFLAGS -mfpmath=387"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
AC_ARG_ENABLE(altivec,
|
AC_ARG_ENABLE(altivec,
|
||||||
AC_HELP_STRING([--enable-altivec], [use Altivec assembly routines [[default=yes]]]),
|
AC_HELP_STRING([--enable-altivec], [use Altivec assembly routines [[default=yes]]]),
|
||||||
, enable_altivec=yes)
|
, enable_altivec=yes)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue