This is an automated email from the ASF dual-hosted git repository.
yiguolei pushed a commit to branch branch-2.1
in repository https://gitbox.apache.org/repos/asf/doris.git
The following commit(s) were added to refs/heads/branch-2.1 by this push:
new 2e79612320f [env](compile) compile failed caused by <immintrin.h>
(#37068) (#38130)
2e79612320f is described below
commit 2e79612320f2608ad15b704439fcee0bd0f3f2bf
Author: Jensen <[email protected]>
AuthorDate: Sat Jul 20 14:10:31 2024 +0800
[env](compile) compile failed caused by <immintrin.h> (#37068) (#38130)
pick from master #37068
---
be/src/util/simd/vstring_function.h | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/be/src/util/simd/vstring_function.h
b/be/src/util/simd/vstring_function.h
index 4fff59a01df..579da50d2df 100644
--- a/be/src/util/simd/vstring_function.h
+++ b/be/src/util/simd/vstring_function.h
@@ -17,7 +17,11 @@
#pragma once
+#ifdef __AVX2__
#include <immintrin.h>
+
+#include "gutil/macros.h"
+#endif
#include <unistd.h>
#include <array>
@@ -112,7 +116,7 @@ public:
if constexpr (trim_single) {
const auto ch = remove_str.data[0];
-#if defined(__AVX2__) || defined(__aarch64__)
+#if defined(__AVX2__)
constexpr auto AVX2_BYTES = sizeof(__m256i);
const auto size = end - begin;
const auto* const avx2_begin = end - size / AVX2_BYTES *
AVX2_BYTES;
@@ -153,7 +157,7 @@ public:
if constexpr (trim_single) {
const auto ch = remove_str.data[0];
-#if defined(__AVX2__) || defined(__aarch64__)
+#if defined(__AVX2__)
constexpr auto AVX2_BYTES = sizeof(__m256i);
const auto size = end - begin;
const auto* const avx2_end = begin + size / AVX2_BYTES *
AVX2_BYTES;
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]