
Bit Twiddling Hacks (2005) - kercker
https://graphics.stanford.edu/~seander/bithacks.html
======
jdblair
If you enjoy these bit twiddling hacks, I recommend "Hacker's Delight," by
Henry Warren.

Author's website:
[http://www.hackersdelight.org](http://www.hackersdelight.org)

2nd edition on Amazon: [https://www.amazon.com/Hackers-Delight-2nd-Henry-
Warren/dp/0...](https://www.amazon.com/Hackers-Delight-2nd-Henry-
Warren/dp/0321842685)

------
sctb
A perennial:
[https://hn.algolia.com/?query=Bit%20Twiddling%20Hacks&sort=b...](https://hn.algolia.com/?query=Bit%20Twiddling%20Hacks&sort=byDate&dateRange=all&type=story&storyText=false&prefix&page=0)

------
fanf2
My favourite bit twiddling hacks:

Bitwise parallel "SIMD within a register" Life, by Thomas Rokicki:
[https://fanf.livejournal.com/93032.html](https://fanf.livejournal.com/93032.html)

Popcount for radix trees, as seen in Phil Bagwell's HAMTs and my qp tries:
[https://dotat.at/prog/qp/README.html](https://dotat.at/prog/qp/README.html)

