An existing, previously xfailed test that I recently removed the xfail from made me realize that -Wstringop-overflow doesn't properly detect buffer overflow resulting from vectorized stores. Because of a difference in the IL the test passes on x86_64 but fails on targets like aarch64. Other examples can be constructed that -Wstringop-overflow fails to diagnose even on x86_64. For INSTANCE, the overflow in the following function isn't diagnosed when the loop is vectorized: void* f (void) { char *p = __builtin_malloc (8); for (int i = 0; i != 16; ++i) p[i] = 1 << i; return p; } The attached change enhances the warning to detect those as well. It found a few bugs in vectorizer tests that the patch corrects. Tested on x86_64-linux and with an aarch64 cross. Martin