From 37f2dccc96bde82cd5d9086a62ac64f66d47bba7 Mon Sep 17 00:00:00 2001 From: ZHAO Chun Date: Wed, 25 Dec 2019 22:21:46 +0800 Subject: [PATCH] Support bitshuffle on aarch64 (#2574) --- thirdparty/build-thirdparty.sh | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/thirdparty/build-thirdparty.sh b/thirdparty/build-thirdparty.sh index b77e7afd0e..e7156ad3b6 100755 --- a/thirdparty/build-thirdparty.sh +++ b/thirdparty/build-thirdparty.sh @@ -596,7 +596,18 @@ build_bitshuffle() { check_if_source_exist $BITSHUFFLE_SOURCE cd $TP_SOURCE_DIR/$BITSHUFFLE_SOURCE PREFIX=$TP_INSTALL_DIR + + # This library has significant optimizations when built with -mavx2. However, + # we still need to support non-AVX2-capable hardware. So, we build it twice, + # once with the flag and once without, and use some linker tricks to + # suffix the AVX2 symbols with '_avx2'. arches="default avx2" + MACHINE_TYPE=$(uname -m) + # Becuase aarch64 don't support avx2, disable it. + if [[ "${MACHINE_TYPE}" == "aarch64" ]]; then + arches="default" + fi + to_link="" for arch in $arches ; do arch_flag=""