libcvd-members
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Libcvd-members] libcvd configure configure.in


From: Ethan Eade
Subject: [Libcvd-members] libcvd configure configure.in
Date: Tue, 16 May 2006 13:34:23 +0000

CVSROOT:        /cvsroot/libcvd
Module name:    libcvd
Branch:         
Changes by:     Ethan Eade <address@hidden>     06/05/16 13:34:23

Modified files:
        .              : configure configure.in 

Log message:
        Added checks to configure.in so that configure checks for:
        
        <mmintrin.h> -- MMX compiler intrinsics, defines CVD_HAVE_MMINTRIN
        <xmmintrin.h> -- SSE compiler intrinsics, defines CVD_HAVE_XMMINTRIN
        <emmintrin.h> -- SSE2 compiler intrinsics, defines CVD_HAVE_EMMINTRIN
        
        These are common to gcc and Intel compilers, and allow for more 
portable use
        of SIMD.

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/libcvd/libcvd/configure.diff?tr1=1.66&tr2=1.67&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/libcvd/libcvd/configure.in.diff?tr1=1.64&tr2=1.65&r1=text&r2=text

Patches:
Index: libcvd/configure
diff -u libcvd/configure:1.66 libcvd/configure:1.67
--- libcvd/configure:1.66       Mon May  8 17:13:37 2006
+++ libcvd/configure    Tue May 16 13:34:22 2006
@@ -3304,6 +3304,89 @@
                                fi
 
 
+cat >conftest.$ac_ext <<_ACEOF
+#include <mmintrin.h>
+ int main(){ __m64 a,b,c; a = _m_punpckhbw(b,c); }
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+  (eval $ac_compile) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+        { ac_try='test -z "$ac_cxx_werror_flag"
+                        || test ! -s conftest.err'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; } &&
+        { ac_try='test -s conftest.$ac_objext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  a=1
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+a=0
+fi
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+                               if test $a = 1
+                               then
+                                       cat >>confdefs.h <<\_ACEOF
+#define CVD_HAVE_MMINTRIN 1
+_ACEOF
+
+                               fi
+                               cat >conftest.$ac_ext <<_ACEOF
+#include <xmmintrin.h>
+ int main(){ __m128 a,b,c; a = _mm_add_ps(b,c); }
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+  (eval $ac_compile) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+        { ac_try='test -z "$ac_cxx_werror_flag"
+                        || test ! -s conftest.err'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; } &&
+        { ac_try='test -s conftest.$ac_objext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  a=1
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+a=0
+fi
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+                               if test $a = 1
+                               then
+                                       cat >>confdefs.h <<\_ACEOF
+#define CVD_HAVE_XMMINTRIN 1
+_ACEOF
+
+                               fi
+
                        else
                                echo "$as_me:$LINENO: result: no" >&5
 echo "${ECHO_T}no" >&6
@@ -3326,6 +3409,47 @@
                                then
                                        CXXFLAGS="$CXXFLAGS -mmmx -m3dnow"
                                fi
+                               cat >conftest.$ac_ext <<_ACEOF
+#include <mmintrin.h>
+ int main(){ __m64 a,b,c; a = _m_punpckhbw(b,c); }
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+  (eval $ac_compile) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+        { ac_try='test -z "$ac_cxx_werror_flag"
+                        || test ! -s conftest.err'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; } &&
+        { ac_try='test -s conftest.$ac_objext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  a=1
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+a=0
+fi
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+                               if test $a = 1
+                               then
+                                       cat >>confdefs.h <<\_ACEOF
+#define CVD_HAVE_MMINTRIN 1
+_ACEOF
+
+                               fi
 
                        else
                                echo "$as_me:$LINENO: result: no" >&5
@@ -3349,6 +3473,47 @@
                                then
                                        CXXFLAGS="$CXXFLAGS -msse2"
                                fi
+                               cat >conftest.$ac_ext <<_ACEOF
+#include <emmintrin.h>
+ int main(){ __m128d a,b,c; a = _mm_add_pd(b,c); }
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+  (eval $ac_compile) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+        { ac_try='test -z "$ac_cxx_werror_flag"
+                        || test ! -s conftest.err'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; } &&
+        { ac_try='test -s conftest.$ac_objext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  a=1
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+a=0
+fi
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+                               if test $a = 1
+                               then
+                                       cat >>confdefs.h <<\_ACEOF
+#define CVD_HAVE_EMMINTRIN 1
+_ACEOF
+
+                               fi
                        else
                                echo "$as_me:$LINENO: result: no" >&5
 echo "${ECHO_T}no" >&6
@@ -3428,8 +3593,7 @@
 echo $ECHO_N "checking $CXX supports $i... $ECHO_C" >&6
 
                                CXXFLAGS="$save_CXXFLAGS $i"
-
-cat >conftest.$ac_ext <<_ACEOF
+                               cat >conftest.$ac_ext <<_ACEOF
 int main(){}
 _ACEOF
 rm -f conftest.$ac_objext
Index: libcvd/configure.in
diff -u libcvd/configure.in:1.64 libcvd/configure.in:1.65
--- libcvd/configure.in:1.64    Mon May  8 17:13:38 2006
+++ libcvd/configure.in Tue May 16 13:34:23 2006
@@ -162,6 +162,18 @@
                                        CXXFLAGS="$CXXFLAGS -mmmx -msse"
                                fi
 
+                               AC_COMPILE_IFELSE([#include <mmintrin.h>
+ int main(){ __m64 a,b,c; a = _m_punpckhbw(b,c); }], [a=1], [a=0])
+                               if test $a = 1
+                               then
+                                       AC_DEFINE(CVD_HAVE_MMINTRIN)
+                               fi
+                               AC_COMPILE_IFELSE([#include <xmmintrin.h>
+ int main(){ __m128 a,b,c; a = _mm_add_ps(b,c); }], [a=1], [a=0])
+                               if test $a = 1
+                               then
+                                       AC_DEFINE(CVD_HAVE_XMMINTRIN)
+                               fi
 
                        else
                                AC_MSG_RESULT(no)
@@ -178,6 +190,12 @@
                                then
                                        CXXFLAGS="$CXXFLAGS -mmmx -m3dnow"
                                fi
+                               AC_COMPILE_IFELSE([#include <mmintrin.h>
+ int main(){ __m64 a,b,c; a = _m_punpckhbw(b,c); }], [a=1], [a=0])
+                               if test $a = 1
+                               then
+                                       AC_DEFINE(CVD_HAVE_MMINTRIN)
+                               fi
 
                        else
                                AC_MSG_RESULT(no)
@@ -194,6 +212,12 @@
                                then
                                        CXXFLAGS="$CXXFLAGS -msse2"
                                fi
+                               AC_COMPILE_IFELSE([#include <emmintrin.h>       
+ int main(){ __m128d a,b,c; a = _mm_add_pd(b,c); }], [a=1], [a=0])
+                               if test $a = 1
+                               then
+                                       AC_DEFINE(CVD_HAVE_EMMINTRIN)
+                               fi
                        else
                                AC_MSG_RESULT(no)
                        fi




reply via email to

[Prev in Thread] Current Thread [Next in Thread]