]> git.ipfire.org Git - thirdparty/haproxy.git/commit
MINOR: tools: implement my_flsl()
authorWilly Tarreau <w@1wt.eu>
Tue, 5 Mar 2019 11:04:55 +0000 (12:04 +0100)
committerWilly Tarreau <w@1wt.eu>
Thu, 7 Mar 2019 12:48:04 +0000 (13:48 +0100)
commitd87a67f9bc422bf41b6b81c1e99d9aebbbc18d8e
treef58226481015c874ac88ddf3a41009972299fac8
parentfc630bd3735f6d0f0a30de4b1fa8fb192d2b186d
MINOR: tools: implement my_flsl()

We already have my_ffsl() to find the lowest bit set in a word, and
this patch implements the search for the highest bit set in a word.
On x86 it uses the bsr instruction and on other architectures it
uses an efficient implementation.
include/common/standard.h