4 ms·
I haven't tested this, but on Arm32 platforms, this isn't a bad way to do it n some 32-bit machines. If the compiler recognizes the 32-bit approach and rbit is
by rsaxvc 4y ago
I haven't tested this, but on Arm32 platforms, this isn't a bad way to do it n some 32-bit machines.
If the compiler recognizes the 32-bit approach and rbit is available, the 64-bit variant is usually 2 rbits with the registers swapped.
- thomasahle 4y agoIf the compiler can recognize the 32-bit version, it really should be able to recognize the 64-bit version too, no?
- rsaxvc 4y agoIdeally yes. Only last year did Clang 13 learn the 32-bit one. GCC doesn't understand either. I haven't checked clang for the 64-bit one.