prepare for vectorization