Hi Alex,

Alex Wang <alexw@...> writes:

> 
> This commit changes the per dpif-netdev datapath flow-table/
> classifier to per pmd-thread.  As direct benefit, datapath
> and flow statistics no longer need to be protected by mutex
> or be declared as per-thread variable, since they are only
> written by the owning pmd thread.
> 
> As side effects, the flow-dump output of userspace datapath
> can contain overlapping flows.  To reduce confusion, the dump
> from different pmd thread will be separated by a title line.
> In addition, the flow operations via 'ovs-appctl dpctl/*'
> are modified so that if the given flow in_port corresponds
> to a dpdk interface, the operation will be conducted to all
> pmd threads recv from that interface.
> 
> Signed-off-by: Alex Wang <alexw <at> nicira.com>
> ---

Thanks for this patch. It's good that some of these locks are
being removed from the datapath. I reviewed the dpif-netdev.c
file. There is an XXX in fast_path_processing() - Can that be
resolved now as you have a per-core classifier or do I 
misunderstand? Other than that the code is clean and I didn't
see any major issues.

I did some tests with just single pmd and 30,000 
flows to see what kind of performance bump I could get with these
patches and I saw about a 30% increase in throughput (i didn't look
at latency). I guess even if there wasn't any contention on the stats
mutexes there should be a bump in performance because of the 
overhead of locking the mute but I checked vtune and there was less
contention on mutexes.

The flow_mutex is another one that I have seen cause contention, I
think this might be a bit trickier to remove. The way we did it in
OVDK was to queue up requests to alter the flow table and then
execute them when we had time (which was just intermittently). Have
you thought about how to resolve this?

Mark

_______________________________________________
dev mailing list
dev@openvswitch.org
http://openvswitch.org/mailman/listinfo/dev

Reply via email to