Re:Bit Twiddling Hacks
by DarkShikari on Wednesday January 11, 2012 @08:44PM
(#3454696)
min() is a special case: on most modern architectures (x86, ARM, etc), the naive code will compile optimally. Example on x86:
The compiler will likely not understand the insane bit-hack method, which is much more complicated, and thus not parse it into a simple cmov sequence.
[ Parent
| on HN ]
There are no comments on this comment yet.