diff options
author | Ilya Maximets <i.maximets@ovn.org> | 2021-08-03 19:36:39 +0200 |
---|---|---|
committer | Ilya Maximets <i.maximets@ovn.org> | 2021-08-05 11:46:33 +0200 |
commit | a3bd383e94a9ecfeeeed7b1b09cd5fee2328bf9c (patch) | |
tree | 60009994222e11e178c356a003ce24ca2a2ba3aa /m4 | |
parent | e21e9dcec24101648918e49e0b609106048e0850 (diff) | |
download | openvswitch-a3bd383e94a9ecfeeeed7b1b09cd5fee2328bf9c.tar.gz |
acinclude: Don't set AVX512-related configuration via CFLAGS.
The correct way to pass configuration options is to define them
inside the config.h. Additionally, few long lines wrapped and
fixed the unnecessary double check for -mavx512f.
Fixes: abb807e27dd4 ("dpif-netdev: Add command to switch dpif implementation.")
Fixes: 5324b54e606a ("dpif-netdev: Add configure to enable autovalidator at build time.")
Fixes: e90e115a01af ("dpif-netdev: implement subtable lookup validation.")
Fixes: 352b6c7116cd ("dpif-lookup: add avx512 gather implementation.")
Signed-off-by: Ilya Maximets <i.maximets@ovn.org>
Acked-by: Cian Ferriter <cian.ferriter@intel.com>
Diffstat (limited to 'm4')
-rw-r--r-- | m4/openvswitch.m4 | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/m4/openvswitch.m4 b/m4/openvswitch.m4 index 244ea0fba..772825a71 100644 --- a/m4/openvswitch.m4 +++ b/m4/openvswitch.m4 @@ -412,7 +412,6 @@ AC_DEFUN([OVS_CHECK_BINUTILS_AVX512], if ($CC -dumpmachine | grep x86_64) >/dev/null 2>&1; then if (objdump -d --no-show-raw-insn $OBJFILE | grep -q $GATHER_PARAMS) >/dev/null 2>&1; then ovs_cv_binutils_avx512_good=yes - CFLAGS="$CFLAGS -DHAVE_LD_AVX512_GOOD" else ovs_cv_binutils_avx512_good=no dnl Explicitly disallow avx512f to stop compiler auto-vectorizing @@ -424,6 +423,10 @@ AC_DEFUN([OVS_CHECK_BINUTILS_AVX512], ovs_cv_binutils_avx512_good=no fi]) rm $OBJFILE + if test "$ovs_cv_binutils_avx512_good" = yes; then + AC_DEFINE([HAVE_LD_AVX512_GOOD], [1], + [Define to 1 if binutils correctly supports AVX512.]) + fi AM_CONDITIONAL([HAVE_LD_AVX512_GOOD], [test "$ovs_cv_binutils_avx512_good" = yes])]) |