replace div with shift since idiv takes ~40 cycles and compiler can't do strength reduction w/o knowing ops are non-negative