Vectorized code on CPU working