[ovs-dev] [PATCH v7 9/9] mfex-avx512: Add support for tunnel packets in avx512 MFEX.

2022-10-12 Thread Cian Ferriter
From: Kumar Amber This patch adds the necessary support to avx512 mfex to support handling of tunnel packet type. Signed-off-by: Kumar Amber Acked-by: Cian Ferriter Acked-by: Sunil Pai G --- lib/dpif-netdev-avx512.c | 32 ++--- lib/dpif-netdev-extract-avx512.c | 206

[ovs-dev] [PATCH v7 8/9] mfex-study: Modify study func to select outer and inner MFEX funcs.

2022-10-12 Thread Cian Ferriter
From: Kumar Amber The MFEX study function is split into outer and inner to allow for independent selection and studying of packets in outer and inner flows to different ISA optimized miniflow extract implementations. Signed-off-by: Kumar Amber Acked-by: Cian Ferriter Acked-by: Sunil Pai G

[ovs-dev] [PATCH v7 6/9] dpif-mfex: Modify set/get MFEX commands to include inner.

2022-10-12 Thread Cian Ferriter
Signed-off-by: Kumar Amber Signed-off-by: Cian Ferriter Co-authored-by: Cian Ferriter Acked-by: Sunil Pai G --- v7: * Reword bridge.rst documentation to better explain the use of the -recirc option and provide examples. This is all based on feedback from Sunil. --- Documentation/topics

[ovs-dev] [PATCH v7 5/9] dpif-netdev: Add function pointer for dpif re-circulate.

2022-10-12 Thread Cian Ferriter
From: Kumar Amber This patch adds support for selecting the recirculation implementation based on the DPIF implementation. Signed-off-by: Kumar Amber Signed-off-by: Cian Ferriter Co-authored-by: Cian Ferriter Acked-by: Sunil Pai G --- lib/dpif-netdev-private-dpif.c | 73

[ovs-dev] [PATCH v7 7/9] dpif-mfex: Change MFEX fn pointer prototype to include md_is_valid.

2022-10-12 Thread Cian Ferriter
From: Kumar Amber The md_is_valid parameter is passed from DPIF to MFEX to allow MFEX functions to detect the tunneling and decide the processing of Inner packets in static predictable branches. Signed-off-by: Kumar Amber Acked-by: Cian Ferriter Acked-by: Sunil Pai G --- lib/dpif-netdev

[ovs-dev] [PATCH v7 4/9] dpif-netdev-avx512: Add inner packet handling to dpif.

2022-10-12 Thread Cian Ferriter
From: Kumar Amber This patch adds the necessary changes required to support tunnel packet types in avx512 dpif. Signed-off-by: Kumar Amber Signed-off-by: Cian Ferriter Co-authored-by: Cian Ferriter Acked-by: Sunil Pai G --- lib/dpif-netdev-avx512.c | 38

[ovs-dev] [PATCH v7 3/9] dpif-netdev-avx512: Refactor avx512 dpif and create new APIs.

2022-10-12 Thread Cian Ferriter
From: Kumar Amber Create new APIs for the avx512 DPIF, enabling one baseline common code to be specialized into DPIF implementations for "outer" processing, and "recirc" processing. Signed-off-by: Kumar Amber Signed-off-by: Cian Ferriter Co-authored-by: Cian Ferriter A

[ovs-dev] [PATCH v7 1/9] dpif-netdev: Refactor per thread recirc data allocation.

2022-10-12 Thread Cian Ferriter
From: Kumar Amber The refactor allows us to use *recirc_depth_get() to obtain the depth across ovs which was previously limited to only dpif-netdev.c. The patch enables the use of recirc_depth_get() function in avx512 dpif. Signed-off-by: Kumar Amber Signed-off-by: Cian Ferriter Co-authored

[ovs-dev] [PATCH v7 2/9] dpif-netdev: Refactor hash function to own header.

2022-10-12 Thread Cian Ferriter
From: Kumar Amber The refactor allows us to use hash function accross multiple files which was earlier restricted to dpif-netdev.c only. This patch enables the use of the hash function in avx512 dpif. Signed-off-by: Kumar Amber Signed-off-by: Cian Ferriter Co-authored-by: Cian Ferriter Acked

[ovs-dev] [PATCH v7 0/9] DPIF + MFEX Inner AVX512

2022-10-12 Thread Cian Ferriter
This Series of Patchsets introduce the Optimizations for supporting tunneled packets in DPIF and MFEX. Along with the optimization various refactoring of scalar path is done to be used accross without duplication. Over the Tests we have observed a gain of approximate 20~25% gain in performance

[ovs-dev] [PATCH 2/2] dpif-netdev/mfex: Add AVX512 NVGRE traffic profiles.

2022-09-16 Thread Cian Ferriter
A typical NVGRE encapsulated packet starts with the ETH/IP/GRE protocols. Miniflow extract will parse just the ETH and IP headers. The GRE header will be processed later as part of the pop action. Add support for parsing the ETH/IP headers in this scenario. Signed-off-by: Cian Ferriter --- lib

[ovs-dev] [PATCH 1/2] dpif-netdev/dpcls: Specialize 8, 1 and 5, 2 signatures.

2022-09-16 Thread Cian Ferriter
The subtable signatures being specialized here were found in an NVGRE tunnel scenario. Signed-off-by: Cian Ferriter --- v2: * Improve commit title. --- lib/dpif-netdev-lookup-avx512-gather.c | 4 lib/dpif-netdev-lookup-generic.c | 4 2 files changed, 8 insertions(+) diff

[ovs-dev] [PATCH 0/2] Enable AVX512 NVGRE optimizations.

2022-09-16 Thread Cian Ferriter
. Cian Ferriter (2): dpif-netdev/dpcls: Specialize 8,1 and 5,2 signatures. dpif-netdev/mfex: Add AVX512 NVGRE traffic profiles. lib/dp-packet.h| 58 +++--- lib/dpif-netdev-extract-avx512.c | 43 ++- lib/dpif-netdev-lookup-avx512

[ovs-dev] [PATCH 2/2] dpif-netdev/mfex: Add AVX512 NVGRE traffic profiles.

2022-08-25 Thread Cian Ferriter
A typical NVGRE encapsulated packet starts with the ETH/IP/GRE protocols. Miniflow extract will parse just the ETH and IP headers. The GRE header will be processed later as part of the pop action. Add support for parsing the ETH/IP headers in this scenario. Signed-off-by: Cian Ferriter --- lib

[ovs-dev] [PATCH 1/2] dpif-netdev/dpcls: Specialize more subtable signatures.

2022-08-25 Thread Cian Ferriter
The subtable signatures being specialized here were found in an NVGRE tunnel scenario. Signed-off-by: Cian Ferriter --- lib/dpif-netdev-lookup-avx512-gather.c | 4 lib/dpif-netdev-lookup-generic.c | 4 2 files changed, 8 insertions(+) diff --git a/lib/dpif-netdev-lookup-avx512

[ovs-dev] [PATCH 0/2] Enable AVX512 NVGRE optimizations

2022-08-25 Thread Cian Ferriter
This patchset adds AVX512 specialization for the NVGRE tunneling scenario. It adds both an MFEX implementation for parsing the outer header of a typical NVGRE packet and specialized DPCLS subtable signatures for the lookups on both outer and inner headers. Cian Ferriter (2): dpif-netdev/dpcls

[ovs-dev] [PATCH] acinclude: Improve vpopcntdq build check.

2022-08-11 Thread Cian Ferriter
support the instruction. The below OVS_CHECK_AVX512VPOPCNTDQ AC function will check for both compiler and assembler support for the vpopcntdq instruction. Signed-off-by: Cian Ferriter --- acinclude.m4 | 2 +- m4/openvswitch.m4 | 29 + 2 files changed, 30 insertions

[ovs-dev] [PATCH v2 2/2] dpif-avx512: Add support for simple match lookup.

2022-07-07 Thread Cian Ferriter
simple match lookup means an upcall is required because there is no suitable flow in the datapath. Fall back to the scalar DPIF to do this upcall just like we already do later in AVX512 DPIF when we have misses in the DPCLS. Signed-off-by: Cian Ferriter Tested-by: Harry van Haaren --- v2

[ovs-dev] [PATCH v2 0/2] Add simple match lookup to the AVX512 DPIF.

2022-07-07 Thread Cian Ferriter
y scenario. Cian Ferriter (2): dpif-netdev: Refactor simple match lookup functions. dpif-avx512: Add support for simple match lookup. lib/dpif-netdev-avx512.c | 53 -- lib/dpif-netdev-private-dpif.h | 12 lib/dpif-netdev.c | 11 ++

[ovs-dev] [PATCH v2 1/2] dpif-netdev: Refactor simple match lookup functions.

2022-07-07 Thread Cian Ferriter
Make the simple match functions used during lookup non-static to allow reuse of these functions in the AVX512 DPIF. Signed-off-by: Cian Ferriter Tested-by: Harry van Haaren --- v2: * Make the 3 simple match lookup function definitions non-static rather than moving the defitions to the lib

[ovs-dev] [PATCH 1/2] dpif-netdev: Refactor simple match lookup functions.

2022-06-30 Thread Cian Ferriter
Move the simple match functions used during lookup to allow reuse of these functions in the AVX512 DPIF. Signed-off-by: Cian Ferriter --- lib/dpif-netdev-private-dpif.c | 69 +++ lib/dpif-netdev-private-dpif.h | 12 ++ lib/dpif-netdev.c | 74

[ovs-dev] [PATCH 2/2] dpif-avx512: Add support for simple match lookup.

2022-06-30 Thread Cian Ferriter
simple match lookup means an upcall is required because there is no suitable flow in the datapath. Fall back to the scalar DPIF to do this upcall just like we already do later in AVX512 DPIF when we have misses in the DPCLS. Signed-off-by: Cian Ferriter --- lib/dpif-netdev-avx512.c | 52

[ovs-dev] [RFC 1/1] configure: Run AVX512 binutils check only for GCC.

2022-06-22 Thread Cian Ferriter
The bug being checked for by OVS_CHECK_BINUTILS_AVX512 is only present when the compiler is GCC. Add a check for GCC before the other checks. Also only create the directory and variables for the assembler check if gcc and x86_64 are present. Signed-off-by: Cian Ferriter --- m4/openvswitch.m4

[ovs-dev] [RFC 0/1] Enable AVX512 build on Windows.

2022-06-22 Thread Cian Ferriter
s for both Windows and existing Linux builds. Cian Ferriter (1): configure: Run AVX512 binutils check only for GCC. m4/openvswitch.m4 | 33 +++-- 1 file changed, 19 insertions(+), 14 deletions(-) -- 2.25.1 ___ dev mail

[ovs-dev] [PATCH] dpif-netdev-extract-avx512: Protect GCC builtin usage.

2022-06-21 Thread Cian Ferriter
__builtin_constant_p is only available in GCC and only versions >= 4. Use the same "#if __GNUC__ >= 4" check used in other parts of OVS for this builtin. Signed-off-by: Cian Ferriter --- lib/dpif-netdev-extract-avx512.c | 4 1 file changed, 4 insertions(+) diff --git a

[ovs-dev] [PATCH v5 5/5] acinclude: Add seperate checks for AVX512 ISA.

2022-05-17 Thread Cian Ferriter
support for AVX512F, this patch will allow building the AVX512 DPIF. Another example, in GCC 5 and 6, most AVX512 code can be generated, just without AVX512VPOPCNTDQ support. Signed-off-by: Cian Ferriter --- v5: * Create a selector function for the permutexvar implementations based on Sunil's

[ovs-dev] [PATCH v5 3/5] dpif-netdev-extract: Remove unnecessary compiler targets.

2022-05-17 Thread Cian Ferriter
these unnecessary function-level compiler target attributes. Signed-off-by: Cian Ferriter Acked-by: Sunil Pai G --- v5: * Remove an 'avx512bw' target since it's also unnecessary as per Sunil's suggestion. * Add Sunil's Acked-by tag. v4: * Remove the 'avx512f' target since it's also unnecessary

[ovs-dev] [PATCH v5 4/5] automake.mk: Remove -mavx512dq CFLAG from AVX512 library.

2022-05-17 Thread Cian Ferriter
No instructions from the AVX512DQ ISA are used anywhere in OVS. Remove this unnecessary CFLAG. Signed-off-by: Cian Ferriter Acked-by: Sunil Pai G --- v5: * Add Sunil's Acked-by tag. v4: * Add this commit to the series. --- lib/automake.mk | 1 - 1 file changed, 1 deletion(-) diff --git

[ovs-dev] [PATCH v5 2/5] dpif-netdev-lookup: Fix GCC 5 warning.

2022-05-17 Thread Cian Ferriter
dpcls-avx512: Enable 16 block processing.") Signed-off-by: Cian Ferriter Acked-by: Sunil Pai G --- v4: * Added Sunil's Fixes and Acked-by tags. v3: * Add this commit to the series. --- lib/dpif-netdev-lookup-avx512-gather.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[ovs-dev] [PATCH v5 1/5] dpif-netdev-private-extract: Fix typo VMBI -> VBMI.

2022-05-17 Thread Cian Ferriter
Fixes: 250ceddcc2d0 ("dpif-netdev/mfex: Add AVX512 based optimized miniflow extract") Fixes: aa85a25095ae ("dpif-netdev/mfex: Add more AVX512 traffic profiles") Signed-off-by: Cian Ferriter Acked-by: Sunil Pai G --- v4: * Added Sunil's Fixes and Acked-by tags. --- lib

[ovs-dev] [PATCH v5 0/5] Build some AVX512 code on older compilers.

2022-05-17 Thread Cian Ferriter
gister vbmi specialized mfex impls unless VBMI is actually available. * This required some re-ordering of the mfex impl lists. Cian Ferriter (5): dpif-netdev-private-extract: Fix typo VMBI -> VBMI. dpif-netdev-lookup: Fix GCC 5 warning. dpif-netdev-extract: Remove unnecessary compi

[ovs-dev] [PATCH] dpif-netdev: Only hash port number when necessary.

2022-04-29 Thread Cian Ferriter
The hash of the port number is only needed when a DPCLS needs to be created. Move the hash calculation inside the if to accomplish this. Signed-off-by: Cian Ferriter --- lib/dpif-netdev.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/dpif-netdev.c b/lib/dpif-netdev.c

[ovs-dev] [PATCH v4 5/5] acinclude: Add seperate checks for AVX512 ISA.

2022-04-29 Thread Cian Ferriter
support for AVX512F, this patch will allow building the AVX512 DPIF. Another example, in GCC 5 and 6, most AVX512 code can be generated, just without AVX512VPOPCNTDQ support. Signed-off-by: Cian Ferriter --- v4: * Combine the 3 commits which added checks for AVX512 ISA into this single commit

[ovs-dev] [PATCH v4 3/5] dpif-netdev-extract: Remove unnecessary compiler targets.

2022-04-29 Thread Cian Ferriter
of these unnecessary function-level compiler target attributes. Signed-off-by: Cian Ferriter --- v4: * Remove the 'avx512f' target since it's also unnecessary. * Sunil acked the v3 version of this commit, but since it's changed, I'm not carrying the ack over. --- lib/dpif-netdev-extract-avx512.c | 4

[ovs-dev] [PATCH v4 4/5] automake.mk: Remove -mavx512dq CFLAG from AVX512 library.

2022-04-29 Thread Cian Ferriter
No instructions from the AVX512DQ ISA are used anywhere in OVS. Remove this unnecessary CFLAG. Signed-off-by: Cian Ferriter --- v4: * Add this commit to the series. --- lib/automake.mk | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/automake.mk b/lib/automake.mk index a23cdc4ad

[ovs-dev] [PATCH v4 2/5] dpif-netdev-lookup: Fix GCC 5 warning.

2022-04-29 Thread Cian Ferriter
dpcls-avx512: Enable 16 block processing.") Signed-off-by: Cian Ferriter Acked-by: Sunil Pai G --- v4: * Added Sunil's Fixes and Acked-by tags. v3: * Add this commit to the series. --- lib/dpif-netdev-lookup-avx512-gather.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[ovs-dev] [PATCH v4 0/5] Build some AVX512 code on older compilers.

2022-04-29 Thread Cian Ferriter
mfex impls unless VBMI is actually available. * This required some re-ordering of the mfex impl lists. Cian Ferriter (5): dpif-netdev-private-extract: Fix typo VMBI -> VBMI. dpif-netdev-lookup: Fix GCC 5 warning. dpif-netdev-extract: Remove unnecessary compiler targets. automake.mk: Re

[ovs-dev] [PATCH v4 1/5] dpif-netdev-private-extract: Fix typo VMBI -> VBMI.

2022-04-29 Thread Cian Ferriter
Fixes: 250ceddcc2d0 ("dpif-netdev/mfex: Add AVX512 based optimized miniflow extract") Fixes: aa85a25095ae ("dpif-netdev/mfex: Add more AVX512 traffic profiles") Signed-off-by: Cian Ferriter Acked-by: Sunil Pai G --- v4: * Added Sunil's Fixes and Acked-by tags. --- lib

[ovs-dev] [PATCH] dpif-netdev-avx512: Fix overflow of UINT32_C(1).

2022-04-27 Thread Cian Ferriter
UINT64_C(1) is required in this bitshift since batch_size can be 32 and 1 << 32 overflows UINT32_C(1). Fixes: ba0a2619ca0c ("dpif-netdev-avx512: Fix ubsan shift error in bitmasks.") Signed-off-by: Cian Ferriter --- The other uses of UINT32_C(1) in the dpif-netdev-avx512 files

[ovs-dev] [PATCH] faq: Fix features not available in userspace datapath.

2022-04-27 Thread Cian Ferriter
Tunnel virtual ports are supported in the userspace datapath. Update the answer to reflect this. Fixes: a36de779d739 ("openvswitch: Userspace tunneling.") Signed-off-by: Cian Ferriter --- Documentation/faq/releases.rst | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)

[ovs-dev] [PATCH] Documentation: Clarify QEMU version requirement.

2022-04-26 Thread Cian Ferriter
The QEMU version requirement of >= 2.7 is for vhost-user-client ports specifically. Signed-off-by: Cian Ferriter --- Documentation/topics/dpdk/vhost-user.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Documentation/topics/dpdk/vhost-user.rst b/Documentation/topics/d

[ovs-dev] [PATCH v3 6/6] acinclude: Add seperate check for AVX512VPOPCNTDQ ISA.

2022-03-03 Thread Cian Ferriter
Checking for AVX512VPOPCNTDQ separately will allow the compiler to generate other AVX512 ISA code where supported. This is relevant for GCC where AVX512VPOPCNTDQ support is added in GCC 7. In GCC 5 and 6, most AVX512 code can be generated, just without VPOPCNTDQ support. Signed-off-by: Cian

[ovs-dev] [PATCH v3 5/6] acinclude: Add seperate check for AVX512VBMI ISA.

2022-03-03 Thread Cian Ferriter
Only use the "avx512vbmi" compiler target when it is actually supported by the compiler. Signed-off-by: Cian Ferriter --- v3: * Preserve the order of the mfex impl list. v2 changed this order. We want the order to be preserved because VBMI functions should be chosen by the mfex

[ovs-dev] [PATCH v3 3/6] dpif-netdev-extract: Remove ISA compiler target for mfex.

2022-03-03 Thread Cian Ferriter
There are no instructions from this ISA used. The target is not needed. Signed-off-by: Cian Ferriter --- lib/dpif-netdev-extract-avx512.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/lib/dpif-netdev-extract-avx512.c b/lib/dpif-netdev-extract-avx512.c index c1c1fefb6..f36a6eab0 100644

[ovs-dev] [PATCH v3 4/6] acinclude: Add seperate check for AVX512BW and AVX512DQ ISA.

2022-03-03 Thread Cian Ferriter
the -mavx512vpopcntdq check is removed from OVS_CHECK_AVX512. That is done in a later patch. Signed-off-by: Cian Ferriter --- acinclude.m4 | 15 +++ configure.ac | 1 + lib/automake.mk | 12 lib/dpif-netdev-lookup.c

[ovs-dev] [PATCH v3 2/6] dpif-netdev-lookup: Fix GCC 5 warning.

2022-03-03 Thread Cian Ferriter
GCC 5 gave an incompatible pointer type warning for pkt_blocks when it's passed to _mm512_mask_i64gather_epi64(). Follow the same pattern used for tbl_blocks where the 'const uint64_t *' is cast to a 'const void *' when passed in to avx512_blocks_gather(). Signed-off-by: Cian Ferriter --- v3

[ovs-dev] [PATCH v3 0/6] Build some AVX512 code on older compilers.

2022-03-03 Thread Cian Ferriter
cialized mfex impls unless VBMI is actually available. * This required some re-ordering of the mfex impl lists. Cian Ferriter (6): dpif-netdev-private-extract: Fix typo VMBI -> VBMI. dpif-netdev-lookup: Fix GCC 5 warning. dpif-netdev-extract: Remove ISA compiler target for mfex. acinclu

[ovs-dev] [PATCH v3 1/6] dpif-netdev-private-extract: Fix typo VMBI -> VBMI.

2022-03-03 Thread Cian Ferriter
Signed-off-by: Cian Ferriter --- lib/dpif-netdev-private-extract.c | 8 lib/dpif-netdev-private-extract.h | 10 +- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/lib/dpif-netdev-private-extract.c b/lib/dpif-netdev-private-extract.c index a29bdcfa7..d8e2a55f2

[ovs-dev] [PATCH v2 4/5] acinclude: Add seperate check for AVX512VBMI ISA.

2022-03-02 Thread Cian Ferriter
Only use the "avx512vbmi" compiler target when it is actually supported by the compiler. The order of mfex_impls and the 'dpif_miniflow_extract_impl_idx' enum have to be changed to keep the start index and size of the impl list correct in both VBMI and non VBMI cases. Signed-of

[ovs-dev] [PATCH v2 5/5] acinclude: Add seperate check for AVX512VPOPCNTDQ ISA.

2022-03-02 Thread Cian Ferriter
Checking for AVX512VPOPCNTDQ separately will allow the compiler to generate other AVX512 ISA code where supported. This is relevant for GCC where AVX512VPOPCNTDQ support is added in GCC 7. In GCC 5 and 6, most AVX512 code can be generated, just without VPOPCNTDQ support. Signed-off-by: Cian

[ovs-dev] [PATCH v2 3/5] acinclude: Add seperate check for AVX512BW and AVX512DQ ISA.

2022-03-02 Thread Cian Ferriter
the -mavx512vpopcntdq check is removed from OVS_CHECK_AVX512. That is done in a later patch. Signed-off-by: Cian Ferriter --- acinclude.m4 | 15 +++ configure.ac | 1 + lib/automake.mk | 12 lib/dpif-netdev-lookup.c

[ovs-dev] [PATCH v2 2/5] dpif-netdev-extract: Remove ISA compiler target for mfex.

2022-03-02 Thread Cian Ferriter
There are no instructions from this ISA used. The target is not needed. Signed-off-by: Cian Ferriter --- lib/dpif-netdev-extract-avx512.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/lib/dpif-netdev-extract-avx512.c b/lib/dpif-netdev-extract-avx512.c index c1c1fefb6..f36a6eab0 100644

[ovs-dev] [PATCH v2 0/5] Build some AVX512 code on older compilers.

2022-03-02 Thread Cian Ferriter
VBMI. * Don't register vbmi specialized mfex impls unless VBMI is actually available. * This required some re-ordering of the mfex impl lists. Cian Ferriter (5): dpif-netdev-private-extract: Fix typo VMBI -> VBMI. dpif-netdev-extract: Remove ISA compiler target for mfex. acinclude: Ad

[ovs-dev] [PATCH v2 1/5] dpif-netdev-private-extract: Fix typo VMBI -> VBMI.

2022-03-02 Thread Cian Ferriter
--- lib/dpif-netdev-private-extract.c | 8 lib/dpif-netdev-private-extract.h | 10 +- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/lib/dpif-netdev-private-extract.c b/lib/dpif-netdev-private-extract.c index a29bdcfa7..d8e2a55f2 100644 ---

[ovs-dev] [PATCH 4/4] acinclude: Add seperate check for AVX512VPOPCNTDQ ISA.

2022-02-24 Thread Cian Ferriter
Checking for AVX512VPOPCNTDQ separately will allow the compiler to generate other AVX512 ISA code where supported. This is relevant for GCC where AVX512VPOPCNTDQ support is added in GCC 7. In GCC 5 and 6, most AVX512 code can be generated, just without VPOPCNTDQ support. Signed-off-by: Cian

[ovs-dev] [PATCH 2/4] acinclude: Add seperate check for AVX512BW and AVX512DQ ISA.

2022-02-24 Thread Cian Ferriter
the -mavx512vpopcntdq check is removed from OVS_CHECK_AVX512. That is done in a later patch. Signed-off-by: Cian Ferriter --- acinclude.m4 | 15 +++ configure.ac | 1 + lib/automake.mk | 12 lib/dpif-netdev-lookup.c

[ovs-dev] [PATCH 3/4] acinclude: Add seperate check for AVX512VBMI ISA.

2022-02-24 Thread Cian Ferriter
Only use the "avx512vbmi" compiler target when it is actually supported by the compiler. Signed-off-by: Cian Ferriter --- acinclude.m4 | 14 ++ configure.ac | 1 + lib/dpif-netdev-extract-avx512.c | 10 +- 3 files c

[ovs-dev] [PATCH 0/4] Build some AVX512 code on older compilers.

2022-02-24 Thread Cian Ferriter
ase, where currently, we build all or none of the AVX512 code. For my testing on Ubuntu 20.04, the below steps were very helpful for installing and switching between different GCC versions. https://askubuntu.com/a/1313032 Cian Ferriter (4): dpif-netdev-extract: Remove ISA compiler targe

[ovs-dev] [PATCH 1/4] dpif-netdev-extract: Remove ISA compiler target for mfex.

2022-02-24 Thread Cian Ferriter
There are no instructions from this ISA used. The target is not needed. Signed-off-by: Cian Ferriter --- lib/dpif-netdev-extract-avx512.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/lib/dpif-netdev-extract-avx512.c b/lib/dpif-netdev-extract-avx512.c index c1c1fefb6..f36a6eab0 100644

[ovs-dev] [PATCH] dpif-netdev: Simplify atomic function pointer stores

2022-02-21 Thread Cian Ferriter
was a atomic_store_relaxed() with atomic_init(). Signed-off-by: Cian Ferriter --- lib/dpif-netdev-extract-study.c | 12 lib/dpif-netdev-private-extract.c | 8 ++-- lib/dpif-netdev.c | 16 +--- 3 files changed, 11 insertions(+), 25 deletions(-) diff

[ovs-dev] [PATCH v2] dpif-netdev-dpcls: Make subtable reprobe thread-safe.

2022-02-08 Thread Cian Ferriter
rmail/ovs-dev/2022-January/390757.html Signed-off-by: Cian Ferriter --- lib/dpif-netdev-private-dpcls.h | 6 -- lib/dpif-netdev.c | 20 2 files changed, 20 insertions(+), 6 deletions(-) diff --git a/lib/dpif-netdev-private-dpcls.h b/lib/dpif-netdev-private-

[ovs-dev] [PATCH] dpif-netdev-dpcls: Make subtable reprobe thread-safe.

2022-02-02 Thread Cian Ferriter
dev: add subtable lookup prio set command.") Reported-by: Ilya Maximets Reported-at: https://mail.openvswitch.org/pipermail/ovs-dev/2022-January/390757.html Signed-off-by: Cian Ferriter --- lib/dpif-netdev-private-dpcls.h | 2 +- lib/dpif-netdev.c | 23 +++ 2

[ovs-dev] [PATCH v2] docs/userspace-tunneling: Fix IP addresses for host2.

2021-09-22 Thread Cian Ferriter
The IP addresses being recommended for the VM interface and the "remote_ip" on the tunnel port are wrong. The host1 values were being used before. Update to use the host2 values. Signed-off-by: Cian Ferriter --- v2: - Refer directly to the commands that the host2 IP addresses should

[ovs-dev] [PATCH v2] dpif-netdev: Fix pmd thread comments to include SMC.

2021-09-09 Thread Cian Ferriter
These comments are relevant to SMC too. Fixes: 60d8ccae135f ("dpif-netdev: Add SMC cache after EMC cache") Signed-off-by: Cian Ferriter Acked-by: Kevin Traynor --- lib/dpif-netdev-private-dfc.h| 3 ++- lib/dpif-netdev-private-thread.h | 8 2 files changed, 6 insert

[ovs-dev] [PATCH v2 1/3] dpif-netdev: Add a per thread work ring

2021-09-07 Thread Cian Ferriter
structs. I stopped this because I would have to move bigger structs like "struct dp_netdev_rxq" which rely on even more structs all defined in dpif-netdev.c. Signed-off-by: Cian Ferriter Co-authored-by: Harry van Haaren Signed-off-by: Harry van Haaren Co-authored-by: Sunil Pai G

[ovs-dev] [PATCH v2 3/3] dpif-netdev: Add a configurable delay to work deferral

2021-09-07 Thread Cian Ferriter
. ovs-vsctl set Open_vSwitch . other_config:async-iteration-delay=2 Signed-off-by: Cian Ferriter --- v2: - Add this commit. --- lib/dpif-netdev-private-defer.h | 9 +++ lib/dpif-netdev.c | 45 +++-- 2 files changed, 52 insertions(+), 2 deletions

[ovs-dev] [PATCH v2 2/3] dpif-netdev: Count cycles spent doing async work

2021-09-07 Thread Cian Ferriter
This uses a similar method to how cycles are attributed to RXQs in dp_netdev_pmd_flush_output_on_port(). Signed-off-by: Cian Ferriter --- Adding this cycle counting code costs ~2.5% performance (0.975x pre cycle counting performance). This is for a PV scenario with a vhostuser port and no DMA

[ovs-dev] [PATCH v2 0/3] Userspace deferral of work

2021-09-07 Thread Cian Ferriter
ync()" API to implement an attempt limit on the number of times an asynchronous piece of work should be attempted. - Do all outstanding work on a PMD thread before allowing a reload to occur. Cian Ferriter (3): dpif-netdev: Add a per thread work ring dpif-netdev: Count cycles spent doing asy

[ovs-dev] [PATCH] dpif-netdev: Mention SMC in 2 pmd_thread comments

2021-08-27 Thread Cian Ferriter
These comments are relevant to SMC too. Signed-off-by: Cian Ferriter --- lib/dpif-netdev-private-dfc.h| 3 ++- lib/dpif-netdev-private-thread.h | 8 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/lib/dpif-netdev-private-dfc.h b/lib/dpif-netdev-private-dfc.h index

[ovs-dev] [PATCH] docs/userspace-tunneling: Fix IP addresses for host2

2021-08-27 Thread Cian Ferriter
The IP addresses being recommended for the VM interface and the "remote_ip" on the tunnel port are wrong. The host1 values were being used before. Update to use the host2 values. Signed-off-by: Cian Ferriter --- I hope I'm reading the guide correctly here. I'm fairly sure that the VM

[ovs-dev] [PATCH 2/2] docs: Recommend the use of dpdkvhostuserclient ports

2021-08-27 Thread Cian Ferriter
dpdkvhostuser ports are deprecated, but are still being recommended to users through the documentation. Fix this. Signed-off-by: Cian Ferriter --- Documentation/howto/dpdk.rst| 30 +++-- Documentation/howto/userspace-tunneling.rst | 3 ++- Documentation/intro

[ovs-dev] [PATCH 1/2] docs/install/afxdp: Fix wrapping in QEMU CMDs

2021-08-27 Thread Cian Ferriter
Directly copying the CMD from either the .rst file or the docs on the web caused errors in the QEMU command because of how it was wrapped. Signed-off-by: Cian Ferriter --- The CMD could be wrapped, but without the indentation to look like this: qemu-system-x86_64 -hda ubuntu1810.qcow \ -m

[ovs-dev] [PATCH v2 2/3] dpif-netdev-unixctl.man: Document miniflow-parser-* CMDs

2021-08-13 Thread Cian Ferriter
Document the "ovs-appctl dpif-netdev/miniflow-parser-get" and "ovs-appctl dpif-netdev/miniflow-parser-set" commands in the vswitchd manpage. Fixes: 3d8f47bc041a ("dpif-netdev: Add command line and function pointer for miniflow extract") Signed-off-by: Cian Ferr

[ovs-dev] [PATCH v2 3/3] docs/dpdk/bridge: Fix dpif-netdev/miniflow-parser-set formatting

2021-08-13 Thread Cian Ferriter
The "name" parameter isn't optional so don't use brackets around it. Fixes: 5c5c98cec21b ("docs/dpdk/bridge: Add miniflow extract section.") Signed-off-by: Cian Ferriter --- v2: - Change indentation after wrapping shell command. --- Documentation/topics/dpdk/bridge.

[ovs-dev] [PATCH v2 1/3] dpif-netdev-unixctl.man: Document subtable-lookup-* CMDs

2021-08-13 Thread Cian Ferriter
dd subtable lookup prio set command.") Signed-off-by: Cian Ferriter --- v2: - Add one line summary in commit message. - Add that the number of affected dpcls ports and subtables is returned. --- lib/dpif-netdev-unixctl.man | 12 1 file changed, 12 insertions(+) diff --git

[ovs-dev] [PATCH 1/3] dpif-netdev-unixctl.man: Document subtable-lookup-* CMDs

2021-07-28 Thread Cian Ferriter
Fixes: 9ff7cabfd78d ("dpif-netdev: add subtable-lookup-prio-get command.") Fixes: 3d018c3ea79d ("dpif-netdev: add subtable lookup prio set command.") Signed-off-by: Cian Ferriter --- lib/dpif-netdev-unixctl.man | 10 ++ 1 file changed, 10 insertions(+) diff --g

[ovs-dev] [PATCH 3/3] docs/dpdk/bridge: Fix dpif-netdev/miniflow-parser-set formatting

2021-07-28 Thread Cian Ferriter
The "name" parameter isn't optional so don't use brackets around it. Fixes: 5c5c98cec21b ("docs/dpdk/bridge: Add miniflow extract section.") Signed-off-by: Cian Ferriter --- Documentation/topics/dpdk/bridge.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 dele

[ovs-dev] [PATCH 2/3] dpif-netdev-unixctl.man: Document miniflow-parser-* CMDs

2021-07-28 Thread Cian Ferriter
Fixes: 3d8f47bc041a ("dpif-netdev: Add command line and function pointer for miniflow extract") Signed-off-by: Cian Ferriter --- lib/dpif-netdev-unixctl.man | 10 ++ 1 file changed, 10 insertions(+) diff --git a/lib/dpif-netdev-unixctl.man b/lib/dpif-netdev-unixctl.man index

[ovs-dev] [v15 10/10] dpcls-avx512: Enable avx512 vector popcount instruction.

2021-07-08 Thread Cian Ferriter
From: Harry van Haaren This commit enables the AVX512-VPOPCNTDQ Vector Popcount instruction. This instruction is not available on every CPU that supports the AVX512-F Foundation ISA, hence it is enabled only when the additional VPOPCNTDQ ISA check is passed. The vector popcount instruction is

[ovs-dev] [v15 08/10] dpif-netdev/dpcls: Specialize more subtable signatures.

2021-07-08 Thread Cian Ferriter
From: Harry van Haaren This commit adds more subtables to be specialized. The traffic pattern here being matched is VXLAN traffic subtables, which commonly have (5,3), (9,1) and (9,4) subtable fingerprints. Signed-off-by: Harry van Haaren Acked-by: Flavio Leitner --- v14: - Added Flavio's

[ovs-dev] [v15 09/10] dpdk: Cache result of CPU ISA checks.

2021-07-08 Thread Cian Ferriter
/dpdk.c level, the ISA checks remain runtime for the CPU where they are executed, but subsequent checks for the same ISA feature become much cheaper. Signed-off-by: Harry van Haaren Co-authored-by: Cian Ferriter Signed-off-by: Cian Ferriter Acked-by: Flavio Leitner --- v14: - Added Flavio's

[ovs-dev] [v15 07/10] dpif-netdev/dpcls-avx512: Enable 16 block processing.

2021-07-08 Thread Cian Ferriter
From: Harry van Haaren This commit implements larger subtable searches in avx512. A limitation of the previous implementation was that up to 8 blocks of miniflow data could be matched on (so a subtable with 8 blocks was handled in avx, but 9 blocks or more would fall back to scalar/generic).

[ovs-dev] [v15 01/10] dpif-netdev: Refactor to multiple header files.

2021-07-08 Thread Cian Ferriter
ash() when it is moved definition to fix a compiler error. One valid checkpatch issue with the use of the EMC_FOR_EACH_POS_WITH_HASH() macro was fixed. Signed-off-by: Harry van Haaren Co-authored-by: Cian Ferriter Signed-off-by: Cian Ferriter Acked-by: Flavio Leitner --- Cc: Gaetan

[ovs-dev] [v15 04/10] dpif-netdev: Add command to switch dpif implementation.

2021-07-08 Thread Cian Ferriter
inst the unit-tests. Signed-off-by: Harry van Haaren Co-authored-by: Cian Ferriter Signed-off-by: Cian Ferriter --- v15: - Address Flavio's comments from the v14 review. - Move dp_netdev_impl_set_default_by_name() below dp_netdev_impl_get_by_name() since it relies on that func

[ovs-dev] [v15 05/10] dpif-netdev: Add command to get dpif implementations.

2021-07-08 Thread Cian Ferriter
: $ ovs-appctl dpif-netdev/dpif-impl-get Signed-off-by: Harry van Haaren Co-authored-by: Cian Ferriter Signed-off-by: Cian Ferriter --- v15: - Address Flavio's comments from the v14 review. v14: - Rename command to dpif-impl-get. - Hide more of the dpif impl details from lib/dpif-netdev.c. Pass

[ovs-dev] [v15 06/10] dpif-netdev: Add a partial HWOL PMD statistic.

2021-07-08 Thread Cian Ferriter
It is possible for packets traversing the userspace datapath to match a flow before hitting on EMC by using a mark ID provided by a NIC. Add a PMD statistic for this hit. Signed-off-by: Cian Ferriter Acked-by: Flavio Leitner --- Cc: Gaetan Rivet Cc: Sriharsha Basavapatna v14: - Added

[ovs-dev] [v15 03/10] dpif-avx512: Add ISA implementation of dpif.

2021-07-08 Thread Cian Ferriter
is not able to handle the AVX512 intrinsics, causing compile time failures, so it is disabled for this file. Signed-off-by: Harry van Haaren Co-authored-by: Cian Ferriter Signed-off-by: Cian Ferriter Co-authored-by: Kumar Amber Signed-off-by: Kumar Amber Acked-by: Flavio Leitner --- v15: - Added

[ovs-dev] [v15 02/10] dpif-netdev: Add function pointer for netdev input.

2021-07-08 Thread Cian Ferriter
performance. Signed-off-by: Harry van Haaren Co-authored-by: Cian Ferriter Signed-off-by: Cian Ferriter Acked-by: Flavio Leitner --- v15: - Added Flavio's Acked-by tag. v14: - Add ATOMIC macro to netdev_input_func function pointer in struct dp_netdev_pmd_thread. v13: - Minor code refactor

[ovs-dev] [v15 00/10] DPIF Framework + Optimizations

2021-07-08 Thread Cian Ferriter
atterns Add more demo protocols to show usage - Future work --- Documentation/NEWS items --- Statistics for optimized MFEX - Note that this patchset will be discussed/presented at OvsConf soon :) v3 update summary: (Cian Ferriter helping with rebases, review and code cleanups) - Split out

[ovs-dev] [v6 11/11] dpif-netdev/mfex: add more AVX512 traffic profiles

2021-07-06 Thread Cian Ferriter
From: Harry van Haaren This commit adds 3 new traffic profile implementations to the existing avx512 miniflow extract infrastructure. The profiles added are: - Ether()/IP()/TCP() - Ether()/Dot1Q()/IP()/UDP() - Ether()/Dot1Q()/IP()/TCP() The design of the avx512 code here is for scalability to

[ovs-dev] [v6 10/11] dpif-netdev/mfex: Add AVX512 based optimized miniflow extract

2021-07-06 Thread Cian Ferriter
From: Harry van Haaren This commit adds AVX512 implementations of miniflow extract. By using the 64 bytes available in an AVX512 register, it is possible to convert a packet to a miniflow data-structure in a small quantity instructions. The implementation here probes for Ether()/IP()/UDP()

[ovs-dev] [v6 07/11] test/sytem-dpdk: Add unit test for mfex autovalidator

2021-07-06 Thread Cian Ferriter
From: Kumar Amber Tests: 6: OVS-DPDK - MFEX Autovalidator 7: OVS-DPDK - MFEX Autovalidator Fuzzy Added a new directory to store the PCAP file used in the tests and a script to generate the fuzzy traffic type pcap to be used in fuzzy unit test. Signed-off-by: Kumar Amber --- v5: - fix

[ovs-dev] [v6 08/11] dpif/stats: add miniflow extract opt hits counter

2021-07-06 Thread Cian Ferriter
From: Harry van Haaren This commit adds a new counter to be displayed to the user when requesting datapath packet statistics. It counts the number of packets that are parsed and a miniflow built up from it by the optimized miniflow extract parsers. The ovs-appctl command

[ovs-dev] [v6 09/11] dpdk: add additional CPU ISA detection strings

2021-07-06 Thread Cian Ferriter
From: Harry van Haaren This commit enables OVS to at runtime check for more detailed AVX512 capabilities, specifically Byte and Word (BW) extensions, and Vector Bit Manipulation Instructions (VBMI). These instructions will be used in the CPU ISA optimized implementations of traffic profile

[ovs-dev] [v6 06/11] dpif-netdev: Add packet count and core id paramters for study

2021-07-06 Thread Cian Ferriter
From: Kumar Amber This commit introduces additional command line paramter for mfex study function. If user provides additional packet out it is used in study to compare minimum packets which must be processed else a default value is choosen. Also introduces a third paramter for choosing a

[ovs-dev] [v6 05/11] dpif-netdev: Add configure to enable autovalidator at build time.

2021-07-06 Thread Cian Ferriter
From: Kumar Amber This commit adds a new command to allow the user to enable autovalidatior by default at build time thus allowing for runnig unit test by default. $ ./configure --enable-mfex-default-autovalidator Signed-off-by: Kumar Amber Co-authored-by: Harry van Haaren Signed-off-by:

[ovs-dev] [v6 04/11] docs/dpdk/bridge: add miniflow extract section.

2021-07-06 Thread Cian Ferriter
as running fuzzy tests. Signed-off-by: Kumar Amber Co-authored-by: Cian Ferriter Signed-off-by: Cian Ferriter Co-authored-by: Harry van Haaren Signed-off-by: Harry van Haaren --- v5: - fix review comments(Ian, Flavio, Eelco) --- --- Documentation/topics/dpdk/bridge.rst | 49

[ovs-dev] [v6 03/11] dpif-netdev: Add study function to select the best mfex function

2021-07-06 Thread Cian Ferriter
From: Kumar Amber The study function runs all the available implementations of miniflow_extract and makes a choice whose hitmask has maximum hits and sets the mfex to that function. Study can be run at runtime using the following command: $ ovs-appctl dpif-netdev/miniflow-parser-set study

[ovs-dev] [v6 02/11] dpif-netdev: Add auto validation function for miniflow extract

2021-07-06 Thread Cian Ferriter
From: Kumar Amber This patch introduced the auto-validation function which allows users to compare the batch of packets obtained from different miniflow implementations against the linear miniflow extract and return a hitmask. The autovaidator function can be triggered at runtime using the

[ovs-dev] [v6 01/11] dpif-netdev: Add command line and function pointer for miniflow extract

2021-07-06 Thread Cian Ferriter
From: Kumar Amber This patch introduces the mfex function pointers which allows the user to switch between different miniflow extract implementations which are provided by the OVS based on optimized ISA CPU. The user can query for the available minflow extract variants available for that CPU by

  1   2   >