Avoid overlapped memcpy