[dpdk-dev] [PATCH v1] app/testpmd: optimized MAC swap by using neon intrinsics
Honnappa Nagarahalli
Honnappa.Nagarahalli at arm.com
Mon Mar 11 16:33:26 CET 2019
> Improved MAC swap performance for ARM platform.
> The improvement was achieved by using neon intrinsics to save CPU cycles and
> doing swap for four packets at a time.
> The optimization had 15% - 20% throughput boost in testpmd MAC swap mode.
>
> Signed-off-by: Ruifeng Wang <ruifeng.wang at arm.com>
> Reviewed-by: Gavin Hu <gavin.hu at arm.com>
> Reviewed-by: Phil Yang <phil.yang at arm.com>
> ---
> app/test-pmd/macswap.c | 4 +-
> app/test-pmd/macswap_neon.h | 93
> +++++++++++++++++++++++++++++++++++++++++++++
> 2 files changed, 96 insertions(+), 1 deletion(-) create mode 100644 app/test-
> pmd/macswap_neon.h
>
> diff --git a/app/test-pmd/macswap.c b/app/test-pmd/macswap.c index
> cbb41b7..71af916 100644
> --- a/app/test-pmd/macswap.c
> +++ b/app/test-pmd/macswap.c
> @@ -66,8 +66,10 @@
> #include <rte_flow.h>
>
> #include "testpmd.h"
> -#ifdef RTE_ARCH_X86
> +#if defined(RTE_ARCH_X86)
> #include "macswap_sse.h"
> +#elif defined(RTE_MACHINE_CPUFLAG_NEON) #include "macswap_neon.h"
> #else
> #include "macswap.h"
> #endif
> diff --git a/app/test-pmd/macswap_neon.h b/app/test-pmd/macswap_neon.h
> new file mode 100644 index 0000000..bad1b9b
> --- /dev/null
> +++ b/app/test-pmd/macswap_neon.h
> @@ -0,0 +1,93 @@
> +/* SPDX-License-Identifier: BSD-3-Clause
> + * Copyright(c) 2019 Arm Limited
This change is derived from Intel's work in macswap_sse.h. Can you please add a header similar to lib/librte_lpm/rte_lpm_neon.h?
> + */
> +
> +#ifndef _MACSWAP_NEON_H_
> +#define _MACSWAP_NEON_H_
> +
<snip>
More information about the dev
mailing list