Hi,

this short series of patches aims to increase the rate at which
ovs-vswtichd can receive frames. It targets sset creation and deletion
which showed up when using perf for profiling.

For a configuration with a single match-all flow with actions=drop this
patchset improves the rate at which frames may be received from ~23kkps to
~27kpps (~17%).

sset creation and deletion, seems expensive for three reasons:

1. Malloc and free used for each (small) block of data (perf analysis)
2. Hash calculation (perf analysis)
3. The use of a non-cache-friendly data structure (guess)

With this series applied there still seems to be noticeable overhead
in reading sset. And I wonder if in some cases an alternate data structure
may be useful. For instance in my configuration the result of
ofproto_enumerate_types() seems to be an sset containing only two elements.
I suspect a simple array traversal would be faster than the hash and
cache-miss overhead of sset.

Git and diffstat information provided to aid review.

----------------------------------------------------------------
The following changes since commit 2c11563ad2967db7e5131f763c4d1107919b901e:

  debian: Change openvswitch restart logic for kernel package. (2013-01-17 
13:34:39 -0800)

are available in the git repository at:

  git://github.com/horms/openvswitch.git devel/sset

for you to fetch changes up to d40f93e9000b1c789c51fa9cf521f04871f99286:

  ofproto: Cache result in ofproto_enumerate_types (2013-01-21 14:58:59 +0900)

----------------------------------------------------------------
Simon Horman (3):
      netdev-linux: Cache result in netdev_linux_miimon_run()
      ofproto: Cache result in dp_enumerate_type
      ofproto: Cache result in ofproto_enumerate_types

 lib/dpif-netdev.c          |    7 ++-----
 lib/dpif.c                 |   16 ++++++++++------
 lib/dpif.h                 |    2 +-
 lib/netdev-linux.c         |   25 +++++++++----------------
 lib/netdev-provider.h      |    3 +--
 lib/netdev.c               |   22 ++++++++++++++++++----
 ofproto/ofproto-dpif.c     |    6 +++---
 ofproto/ofproto-provider.h |    6 ++----
 ofproto/ofproto.c          |   31 +++++++++++++++++++++----------
 ofproto/ofproto.h          |    3 ++-
 utilities/ovs-dpctl.c      |   25 ++++++++-----------------
 vswitchd/bridge.c          |   32 ++++++++++++--------------------
 12 files changed, 89 insertions(+), 89 deletions(-)
_______________________________________________
dev mailing list
dev@openvswitch.org
http://openvswitch.org/mailman/listinfo/dev

Reply via email to