Skip to content
Commit 39c0d633 authored by Michael Forney's avatar Michael Forney
Browse files

Use bitwise test instead of __builtin_popcount



__builtin_popcount might not be available on all compilers, so using
it requires a configure check and fallback implementation. In fact
on gcc without an -march flag, it gets compiled to a function call to
libgcc. However, we only need to test whether multiple bits are set,
and this can be done easily with a bitwise and.

Signed-off-by: default avatarMichael Forney <mforney@mforney.org>
parent 7160db05
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment