From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from wes1-so1.wedos.net (wes1-so1.wedos.net [46.28.106.15]) by dpdk.org (Postfix) with ESMTP id C4B714A63 for ; Sat, 19 Mar 2016 20:58:10 +0100 (CET) Received: from pcviktorin.fit.vutbr.cz (pcviktorin.fit.vutbr.cz [147.229.13.147]) by wes1-so1.wedos.net (Postfix) with ESMTPSA id 3qSCZB3x22z5Gv; Sat, 19 Mar 2016 20:58:10 +0100 (CET) From: Jan Viktorin To: dev@dpdk.org Cc: Jan Viktorin , thomas.monjalon@6wind.com, jerin.jacob@caviumnetworks.com, tomaszx.kulasek@intel.com, jianbo.liu@linaro.org Date: Sat, 19 Mar 2016 20:58:04 +0100 Message-Id: <1458417485-29436-4-git-send-email-viktorin@rehivetech.com> X-Mailer: git-send-email 2.7.0 In-Reply-To: <1458417485-29436-1-git-send-email-viktorin@rehivetech.com> References: <1458417485-29436-1-git-send-email-viktorin@rehivetech.com> In-Reply-To: <1458379590-18618-1-git-send-email-viktorin@rehivetech.com> References: <1458379590-18618-1-git-send-email-viktorin@rehivetech.com> Subject: [dpdk-dev] [PATCH v3 3/4] arm: detect NEON by checking RTE_MACHINE_CPUFLAG_NEON X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 19 Mar 2016 19:58:10 -0000 User applications and DPDK libraries should detect the NEON by the RTE_MACHINE_CPUFLAG_NEON. It guarantees that the arm_neon.h is present. Signed-off-by: Jan Viktorin --- examples/l3fwd/l3fwd_em.c | 2 +- lib/librte_eal/common/include/arch/arm/rte_memcpy_32.h | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/examples/l3fwd/l3fwd_em.c b/examples/l3fwd/l3fwd_em.c index 0adf8f4..4983eed 100644 --- a/examples/l3fwd/l3fwd_em.c +++ b/examples/l3fwd/l3fwd_em.c @@ -250,7 +250,7 @@ em_mask_key(void *key, xmm_t mask) return _mm_and_si128(data, mask); } -#elif defined(__ARM_NEON) +#elif defined(RTE_MACHINE_CPUFLAG_NEON) static inline xmm_t em_mask_key(void *key, xmm_t mask) { diff --git a/lib/librte_eal/common/include/arch/arm/rte_memcpy_32.h b/lib/librte_eal/common/include/arch/arm/rte_memcpy_32.h index df47c0d..ad8bc65 100644 --- a/lib/librte_eal/common/include/arch/arm/rte_memcpy_32.h +++ b/lib/librte_eal/common/include/arch/arm/rte_memcpy_32.h @@ -42,7 +42,7 @@ extern "C" { #include "generic/rte_memcpy.h" -#ifdef __ARM_NEON_FP +#ifdef RTE_MACHINE_CPUFLAG_NEON /* ARM NEON Intrinsics are used to copy data */ #include @@ -325,7 +325,7 @@ rte_memcpy_func(void *dst, const void *src, size_t n) return memcpy(dst, src, n); } -#endif /* __ARM_NEON_FP */ +#endif /* RTE_MACHINE_CPUFLAG_NEON */ #ifdef __cplusplus } -- 2.7.0