[ovs-dev] [PATCH] ofproto-dpif-xlate: Don't try to optimize goto table.

Ben Pfaff blp at nicira.com
Thu Aug 1 20:07:28 UTC 2013


On Thu, Aug 01, 2013 at 01:00:11PM -0700, Ethan Jackson wrote:
> > I'm OK with changing the implementation, but I don't like the idea of
> > the externally visible behavior changing.  What if, instead of doing
> > this iteratively, we simply don't penalize goto_table actions with
> > taking up a level of resubmit?  We limit the levels of resubmit to
> > avoid loops, but goto_table can't loop (it can only go to a table with
> > a higher number), so it's not a problem there.
> 
> We definitely can't loop infinitely, but we'd effectively be allowing
> a huge resbumit depth (16k ish).  Consider a flow table that starts at
> 0, does a goto on each table until it hits table 255, and then does a
> resubmit to table 0 again.  I'm worried we'll run out of memory before
> the loop terminates.
> 
> Even if someone is simply doing 255 lookups, that's an awful lot of
> time to be spending on each packet.  The whole thing makes me a bit
> uncomfortable.
> 
> That said, if you feel strongly about it, I can change it.

I did think about that scenario, but I hadn't done the math to realize
that it allowed for 16k lookups.

Let's change it.

Can you leave the test, though, and just crank back the number of
"goto"s it tests to whatever we have as the resubmit limit these days?



More information about the dev mailing list