From: Jan Viktorin Date: Sat, 19 Mar 2016 19:58:03 +0000 (+0100) Subject: mk: improve ARM NEON detection X-Git-Tag: spdx-start~7228 X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=4475b3babc09f816a51c61acae30b2d61bfb5e71;p=dpdk.git mk: improve ARM NEON detection The __ARM_NEON declares that the arm_neon.h is available which is not always true for the __ARM_NEON_FP. $ arm-linux-gnueabi-gcc -dM -E - < /dev/null | grep "_FP\|_NEON" #define __ARM_FP 12 #define __ARM_NEON_FP 4 #define __VFP_FP__ 1 $ arm-linux-gnueabi-gcc -mfpu=neon -dM -E - < /dev/null | grep "_FP\|_NEON" #define __ARM_FP 12 #define __ARM_NEON_FP 4 #define __ARM_NEON__ 1 #define __VFP_FP__ 1 #define __ARM_NEON 1 $ aarch64-linux-gnu-gcc -dM -E - < /dev/null | grep "NEON\|FP" #define __FP_FAST_FMAF 1 #define __ARM_NEON 1 #define __FP_FAST_FMA 1 $ aarch64-thunderx-linux-gnu-gcc -dM -E - < /dev/null |grep "NEON\|FP" #define __ARM_FP 12 #define __ARM_NEON_FP 12 #define __FP_FAST_FMAF 1 #define __ARM_NEON 1 #define __FP_FAST_FMA 1 Signed-off-by: Jan Viktorin Acked-by: Jerin Jacob --- diff --git a/mk/rte.cpuflags.mk b/mk/rte.cpuflags.mk index c494654271..e634abc38c 100644 --- a/mk/rte.cpuflags.mk +++ b/mk/rte.cpuflags.mk @@ -111,7 +111,7 @@ CPUFLAGS += VSX endif # ARM flags -ifneq ($(filter $(AUTO_CPUFLAGS),__ARM_NEON_FP),) +ifneq ($(filter $(AUTO_CPUFLAGS),__ARM_NEON),) CPUFLAGS += NEON endif