7 ms·
I believe it is (!i & 32) because the bitwise version is an incorrect rewrite. [1] https://news.ycombinator.com/item?id=41830016 https://news.ycombinator.com/i
by NovaX 2y ago
I believe it is (!i & 32) because the bitwise version is an incorrect rewrite.
[1] https://news.ycombinator.com/item?id=41830016 https://news.ycombinator.com/item?id=41830016
- urcyanide 2y agoSorry for the confusing example. The bitwise one is correct since I store the binary in u64 with a different endian from the C++ version. (this happens because the C++ version is using a numpy script to do the preprocessing) My bad, I should explain it in a better way. Will update the post.