-
Notifications
You must be signed in to change notification settings - Fork 87
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Lzcnt/popcnt functions? #35
Comments
Hi @touisteur, At this time this feature does not exist. Maybe you can use Hope it helps. |
a look at https://github.com/kimwalisch/libpopcnt might be interesting - although i would think, there are different goals:
@kouchy : don't see how |
@hayguen I guess, you would use LUT to convert each byte/nibble to a number of set bits in it, then shuffle/permute and sum till you reach your lane width. Some libraries even do it recursively and optimizer unwinds it quite nicely. |
@yzazik i had found my non-simd solution at https://graphics.stanford.edu/~seander/bithacks.html |
Hi,
Unless I haven't looked in the right places, there doesn't seem to be any support lane-wise lzcnt or popcount. Is it foreseen in the future or out of scope of this library?
Thanks in advance
The text was updated successfully, but these errors were encountered: