Optimized modulus that combines the steps of an optimized divide with a multiplication using shifts, adds,
and masking of lower bits can fail to simplify into a modulus expression. An example is given below:
Binaries with examples:
combined_with_mask.zip
u32_mod_4k_x86.so: See 3, 5, 17, 36, and others
u64_mod_4k_arm64.so: See 3, 5, 9, 11, 17, and others
u64_mod_4k_x64.dylib: See 6, 10, 12, 18, 20, and others
u64_mod_4k_x64.so: See 3, 5, 9, 17, 22, and others