[ovs-dev] Problem : do_xlate_actions() called excessively ?

Jean Tourrilhes jt at hpl.hp.com
Thu Jun 2 20:22:46 UTC 2011


On Thu, Jun 02, 2011 at 12:55:33PM -0700, Ben Pfaff wrote:
> On Thu, Jun 02, 2011 at 11:16:53AM -0700, Jean Tourrilhes wrote:
> > 	I was looking at various things and I found that
> > do_xlate_actions() in ofproto.c was called way more often than I was
> > expecting. I'm using 1.1.0.
> 
> I think the "extra" translations that you are seeing are an effect of
> flow accounting.  Once a second, OVS accounts flow statistics to
> resubmitted flows via flow_push_stats(), which translates the flow.
> It shouldn't be particularly expensive, but if it turns out to be we
> could cache the fact that a given flow doesn't resubmit and skip it.

	I tried to figure out flow_push_stats(), and I must admit it
took me some time to understand what's happening. I must admit it's
not the most obvious way to do things, but I learn something in the
process.
	I guess a few actions may be complex (OFPP_NORMAL, OFPP_ALL),
and you may have a long list of actions. I personally would be more
worried about the memory trashing, as you need to malloc and create
various structs that will be thrown away. First you kill your CPU
cache, and then memory allocator on embedded platforms is usually more
fragile.
	Thanks for the explanation !

	Jean




More information about the dev mailing list