ARMv8 has an amazingly exotic scheme for encoding bitfields as immediates in logical operations. Copy LLVM's encoder. So far this is unverified because I cannot make sense of
immN:NOT(imms)
in
len = HighestSetBit(immN:NOT(imms));
in DecodeBitMasks on page J1-7389 of the Arm ARM.
If you can make sense of this either consider fully implementing CogARMv8Compiler>>decodeBitMasksN:imms:immr: or explaining to me what is meant by "immN:NOT(imms)" (via email to OpenSMalltalk-VM ?).
AdvThanksance.