News for hackers. Stuff that matters.
Re:The Weird Concept of Branchless Programming by secondcoming on Sunday September 28, 2025 @05:46PM (#45408378)
Compilers would turn that into a jump table:

https://godbolt.org/z/14h5djYe8

Although this looks branchless if you don't care about divide-by-zero. The ALU might not be too happy:

https://godbolt.org/z/9nqG3xMPY

There are no comments on this comment yet.