[ovs-git] [openvswitch/ovs] c2c19d: flow: Reduce metadata connection state branches in...

Ben Pfaff noreply at github.com
Wed Aug 28 21:47:35 UTC 2019


  Branch: refs/heads/master
  Home:   https://github.com/openvswitch/ovs
  Commit: c2c19ddd7c51c4221e9bd72908a0494d3e1e3888
      https://github.com/openvswitch/ovs/commit/c2c19ddd7c51c4221e9bd72908a0494d3e1e3888
  Author: Malvika Gupta <malvika.gupta at arm.com>
  Date:   2019-08-28 (Wed, 28 Aug 2019)

  Changed paths:
    M lib/flow.c

  Log Message:
  -----------
  flow: Reduce metadata connection state branches in miniflow_extract

This patch merges two separate if-else branches for metadata connection state
into one if-else branch to improve performance. It gives an average performance
improvement of ~3% on arm platforms and ~4.5% on x86 platforms.

Signed-off-by: Malvika Gupta <malvika.gupta at arm.com>
Reviewed-by: Yanqin Wei <yanqin.wei at arm.com>
Reviewed-by: Gavin Hu <gavin.hu at arm.com>
Signed-off-by: Ben Pfaff <blp at ovn.org>


  Commit: f1dbe3796d332b5e84ac2685187b0f01e2645915
      https://github.com/openvswitch/ovs/commit/f1dbe3796d332b5e84ac2685187b0f01e2645915
  Author: Yanqin Wei <Yanqin.Wei at arm.com>
  Date:   2019-08-28 (Wed, 28 Aug 2019)

  Changed paths:
    M lib/flow.c

  Log Message:
  -----------
  flow: save "vlan_hdrs" memset for untagged traffic

For untagged traffic, it is unnecessary to clear vlan_hdrs as it costs 32B
memset. So the patch improves it by postponing to clear vlan_hdrs until
ethtype check. It can benefit both untagged and single-tagged traffic. From
testing, it does not impact performance of dual-tagged traffic.

Reviewed-by: Gavin Hu <Gavin.Hu at arm.com>
Signed-off-by: Yanqin Wei <Yanqin.Wei at arm.com>
Signed-off-by: Ben Pfaff <blp at ovn.org>


Compare: https://github.com/openvswitch/ovs/compare/8daa479fa678...f1dbe3796d33


More information about the git mailing list