aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xc/common/platform.h4
-rw-r--r--c/dec/decode.c4
2 files changed, 6 insertions, 2 deletions
diff --git a/c/common/platform.h b/c/common/platform.h
index 3945a27..93db089 100755
--- a/c/common/platform.h
+++ b/c/common/platform.h
@@ -203,6 +203,10 @@ OR:
#endif /* ARMv8 */
+#if defined(__ARM_NEON__) || defined(__ARM_NEON)
+#define BROTLI_TARGET_NEON
+#endif
+
#if defined(__i386) || defined(_M_IX86)
#define BROTLI_TARGET_X86
#endif
diff --git a/c/dec/decode.c b/c/dec/decode.c
index 1fde329..8f72e85 100644
--- a/c/dec/decode.c
+++ b/c/dec/decode.c
@@ -6,7 +6,7 @@
#include <brotli/decode.h>
-#if defined(__ARM_NEON__)
+#if defined(BROTLI_TARGET_NEON)
#include <arm_neon.h>
#endif
@@ -167,7 +167,7 @@ static BrotliDecoderErrorCode DecodeWindowBits(BrotliDecoderState* s,
}
static BROTLI_INLINE void memmove16(uint8_t* dst, uint8_t* src) {
-#if defined(__ARM_NEON__)
+#if defined(BROTLI_TARGET_NEON)
vst1q_u8(dst, vld1q_u8(src));
#else
uint32_t buffer[4];