[x264-devel] commit: compile x86 with fpmath=sse by default (Loren Merritt )

git version control git at videolan.org
Thu Aug 27 08:24:09 CEST 2009


x264 | branch: master | Loren Merritt <pengvado at akuvian.org> | Thu Aug 27 06:05:57 2009 +0000| [ee95ca7970140e8b99af233b03828feb250f0af0] | committer: Loren Merritt 

compile x86 with fpmath=sse by default

> http://git.videolan.org/gitweb.cgi/x264.git/?a=commit;h=ee95ca7970140e8b99af233b03828feb250f0af0
---

 configure         |    3 +++
 encoder/encoder.c |    4 ++--
 2 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/configure b/configure
index ac07a01..767570a 100755
--- a/configure
+++ b/configure
@@ -239,6 +239,9 @@ case $host_cpu in
     if [[ "$asm" == yes && "$CFLAGS" != *-march* ]]; then
       CFLAGS="$CFLAGS -march=i686"
     fi
+    if [[ "$asm" == yes && "$CFLAGS" != *-mfpmath* ]]; then
+      CFLAGS="$CFLAGS -mfpmath=sse -msse"
+    fi
     if [ "$SYS" = MACOSX ]; then
       ASFLAGS="$ASFLAGS -f macho -DPREFIX"
     elif [ "$SYS" = MINGW ]; then
diff --git a/encoder/encoder.c b/encoder/encoder.c
index 22828af..a7c2f7f 100644
--- a/encoder/encoder.c
+++ b/encoder/encoder.c
@@ -338,9 +338,9 @@ fail:
 static int x264_validate_parameters( x264_t *h )
 {
 #ifdef HAVE_MMX
-    if( !(x264_cpu_detect() & X264_CPU_MMXEXT) )
+    if( !(x264_cpu_detect() & X264_CPU_SSE) )
     {
-        x264_log( h, X264_LOG_ERROR, "your cpu does not support MMXEXT, but x264 was compiled with asm support\n");
+        x264_log( h, X264_LOG_ERROR, "your cpu does not support SSE1, but x264 was compiled with asm support\n");
         x264_log( h, X264_LOG_ERROR, "to run x264, recompile without asm support (configure --disable-asm)\n");
         return -1;
     }



More information about the x264-devel mailing list