Taking another look at the morton order code
@vassvik.bsky.social posted, one can further reduce the amount of instructions required, using one of my favorite bit fudging techniques: Bit cloning using multiplication!
It sometimes lets you replace code like x | (x << a) | (x << b) if a, b are fixed.
add a skeleton here at some point
6 days ago