Skip to content

Commit

Permalink
fix SIMD detection script
Browse files Browse the repository at this point in the history
  • Loading branch information
ClementPernet committed Nov 23, 2017
1 parent f9d59c0 commit 31410ae
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 25 deletions.
25 changes: 1 addition & 24 deletions macros/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -18,27 +18,4 @@
# ========LICENCE========
#


EXTRA_DIST=\
aclocal-include.m4 \
ax_cxx_compile_stdcxx_11.m4 \
config-header.m4 \
debug.m4 \
expat-check.m4 \
fflas-ffpack-check.m4 \
iml-check.m4 \
lidia-check.m4 \
linbox-benchmark.m4 \
linbox-doc.m4 \
linbox-misc.m4 \
linbox-opt.m4 \
maple-check-version.mpl \
maple-check.m4 \
ntl-check.m4 \
saclib-check.m4 \
mpfr-check.m4 \
fplll-check.m4 \
m4rie-check.m4 \
m4ri-check.m4 \
tinyxml2-check.m4 \
sage-check.m4
SUBDIRS=CodeChunk
6 changes: 5 additions & 1 deletion macros/instr_set.m4
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,9 @@ AC_DEFUN([INSTR_SET],
AC_ARG_ENABLE(fma,[AC_HELP_STRING([--disable-fma], [ disable FMA instruction set (enabled by default when available)])],[],[])
AC_ARG_ENABLE(fma4,[AC_HELP_STRING([--disable-fma4], [ disable FMA4 instruction set (enabled by default when available)])],[],[])
AC_TRY_RUN([
BACKUP_CPPFLAGS=${CPPFLAGS}
CPPFLAGS=-I${srcdir}
AC_TRY_RUN([
#include "macros/CodeChunk/instrset_detect.cpp"
// increment by one to distinguish from compilation failure error code
int main(){return instrset_detect()+1;}
Expand Down Expand Up @@ -81,4 +83,6 @@ AC_DEFUN([INSTR_SET],
SIMD_CFLAGS="${SIMD_CFLAGS} -mfma4"
],[AS_ECHO("FMA4 disabled")])
],[AS_ECHO("FMA4 disabled")])
CPPFLAGS=${BACKUP_CPPFLAGS}
])

0 comments on commit 31410ae

Please sign in to comment.