ofproto: Reduce taking rule references.
authorJarno Rajahalme <jrajahalme@nicira.com>
Thu, 24 Apr 2014 15:21:49 +0000 (08:21 -0700)
committerJarno Rajahalme <jrajahalme@nicira.com>
Thu, 24 Apr 2014 15:27:58 +0000 (08:27 -0700)
commit83709dfafba5b8b58670cec4a2e95204ef63e6e2
tree4bc298c563b38cc7768197e09d684d699f515e5c
parent1a7c0cd710e19db3ff85606dbfd5fdad964a1eea
ofproto: Reduce taking rule references.

Only take reference to a looked up rule when needed.

This reduces the total CPU utilization of rule_ref/unref calls by 80%,
from 5% of total server CPU capacity to 1% in a netperf TCP_CRR
test stressing the userspace.

Signed-off-by: Jarno Rajahalme <jrajahalme@nicira.com>
Acked-by: Ethan Jackson <ethan@nicira.com>
ofproto/ofproto-dpif-xlate.c