BUG/MEDIUM: tools: fix direction of my_ffsl()
authorWilly Tarreau <w@1wt.eu>
Mon, 29 Oct 2018 15:09:57 +0000 (16:09 +0100)
committerWilly Tarreau <w@1wt.eu>
Mon, 29 Oct 2018 15:09:57 +0000 (16:09 +0100)
commitce487aab46e72641b4fcc3b77c07c7a54c833368
tree076fb0ad7b1467e7ab5c9b2dc3a812e19834c229
parentbddf292cbd7fe8795b03f0e37753c85757b504be
BUG/MEDIUM: tools: fix direction of my_ffsl()

Commit 27346b01a ("OPTIM: tools: optimize my_ffsl() for x86_64") optimized
my_ffsl() for intensive use cases in the scheduler, but as half of the times
I got it wrong so it counted bits the reverse way. It doesn't matter for the
scheduler nor fd cache but it broke cpu-map with threads which heavily relies
on proper ordering.

We should probably consider dropping support for gcc < 3.4 and switching
to builtins for these ones, though often they are as ambiguous.

No backport is needed.
include/common/standard.h