]> git.proxmox.com Git - ovs.git/commit
dpif-netdev: Refactor generic implementation
authorHarry van Haaren <harry.van.haaren@intel.com>
Thu, 18 Jul 2019 13:03:05 +0000 (14:03 +0100)
committerIan Stokes <ian.stokes@intel.com>
Fri, 19 Jul 2019 11:22:23 +0000 (12:22 +0100)
commita0b36b3924c7c7033ebecc2ad79f6fcee2b2e66d
tree42ed0953a36b479fdf161114d9d9a13f8a0fe355
parent92c7c870d69a1c433768fc7746c573bc0c4bd5fa
dpif-netdev: Refactor generic implementation

This commit refactors the generic implementation. The
goal of this refactor is to simplify the code to enable
"specialization" of the functions at compile time.

Given compile-time optimizations, the compiler is able
to unroll loops, and create optimized code sequences due
to compile time knowledge of loop-trip counts.

In order to enable these compiler optimizations, we must
refactor the code to pass the loop-trip counts to functions
as compile time constants.

This patch allows the number of miniflow-bits set per "unit"
in the miniflow to be passed around as a function argument.

Note that this patch does NOT yet take advantage of doing so,
this is only a refactor to enable it in the next patches.

Signed-off-by: Harry van Haaren <harry.van.haaren@intel.com>
Tested-by: Malvika Gupta <malvika.gupta@arm.com>
Acked-by: Ilya Maximets <i.maximets@samsung.com>
Signed-off-by: Ian Stokes <ian.stokes@intel.com>
lib/dpif-netdev-lookup-generic.c
lib/dpif-netdev-private.h
lib/dpif-netdev.c