3 ms·
Bitwise operators are the beginners introduction to SIMD programming. A 64 bit register doing XOR is really 64x parallel XOR happening in parallel each of size
by dragontamer 3y ago
Bitwise operators are the beginners introduction to SIMD programming.
A 64 bit register doing XOR is really 64x parallel XOR happening in parallel each of size 1 bit.
A shift, rotate are just fancy movement operators and exist in the SIMD space.
Good bitwise programming IMO requires a full embrace of this parallel mindset. See the Chess Programming Wiki for all sorts of things that 64x parallel bits can represent.
In particular, a 8x8 chessboard maps well to 64 bits.
-------
No really. Do remember that one of the OG SIMD computers, the CM2 (connection machine 2) was a 1-bit core but SIMD across thousands of cores (bits). And a lot of research and understanding of modern parallel concepts comes from the Connection Machine.