[ovs-git] [openvswitch/ovs] a0f7bf: util: implement count_1bits with Neon intrinsics o...

Ben Pfaff noreply at github.com
Thu Jun 13 17:51:28 UTC 2019

  Branch: refs/heads/master
  Home:   https://github.com/openvswitch/ovs
  Commit: a0f7bf222030f4cdbce0bda66bd9f2bc6983d9db
  Author: Yanqin Wei <Yanqin.Wei at arm.com>
  Date:   2019-06-13 (Thu, 13 Jun 2019)

  Changed paths:
    M lib/util.h

  Log Message:
  util: implement count_1bits with Neon intrinsics or gcc built-in for aarch64.

Userspace datapath needs to traverse through miniflow values many times. In
this process, 'count_1bits' operation for 'Flowmap' significantly impact
performance. On arm, this function was defined by portable implementation
because gcc for arm does not support popcnt feature.
But in the aarch64, VCNT neon instruction can accelerate "count_1bits".
>From Gcc-7, the built-in function is implemented with neon intruction.
In this patch, count_1bits function will be impelmented with gcc built-in
from gcc-7 on, and with neon intrinsics in gcc-6.
Performance test was run in two aarch64 machines. In the NIC2NIC test, one
tuple dpcls lookup case achieves around 4% throughput improvement and
10(average) tuples case achieves around 5% improvement.

Tested-by: Malvika Gupta <malvika.gupta at arm.com>
Signed-off-by: Yanqin Wei <Yanqin.Wei at arm.com>
Signed-off-by: Ben Pfaff <blp at ovn.org>

More information about the git mailing list