normalize rshl/rshr code, make it work with simd/scalar