Hi,
consider this functions intended for vectorization:
void AddSqr(float* restrict dst, float* restrict src, int cnt) { for (int i=0; i<cnt; i++) dst[i] = src[i] * src[i]; };
This would work if the src & dst are not aliased of course. But what if src == dst? Extreme cases such as src == dst+1 are not allowed of course. But if the pointers are the same, there shouldn't be a problem, or am I missing something?