[Bug sanitizer/120201] [13/14/15 Regression] generates a misaligned vector operation for std::memcpy with -march=znver4 since santizer doesn't allocate properly aligned stack by r6-6813-g63998a6336239d
"cvs-commit at gcc dot gnu.org via Gcc-bugs" <[email protected]> Sat, 01 Aug 2026 10:58:11 +0000
| Newsgroups | gmane.comp.gcc.bugs |
|---|---|
| Message-ID | <[email protected]/bugzilla/> |
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=120201 --- Comment #29 from GCC Commits <cvs-commit at gcc dot gnu.org> --- The releases/gcc-13 branch has been updated by Jakub Jelinek <[email protected]>: https://gcc.gnu.org/g:fcedd47a470df6cff26dabadaaf4fc12e9094dbf commit r13-10442-gfcedd47a470df6cff26dabadaaf4fc12e9094dbf Author: Jakub Jelinek <[email protected]> Date: Tue Jul 14 10:37:03 2026 +0200 cfgexpand: Align the whole asan var block to crtl->stack_alignment_needed [PR120201] If crtl->stack_alignment_needed / BITS_PER_UNIT is larger than data.asan_alignb, we can end up with misaligned stack for further allocations (e.g. to spill SSA_NAMEs with vector modes and large alignment). This patch increments data.asan_alignb in that case. 2026-07-14 Jakub Jelinek <[email protected]> H.J. Lu <[email protected]> PR tree-optimization/120201 * cfgexpand.cc (expand_used_vars): Set data.asan_alignb to maximum of itself and crtl->stack_alignment_needed / BITS_PER_UNIT. * g++.dg/asan/pr120201-1.C: New test. Signed-off-by: H.J. Lu <[email protected]> (cherry picked from commit 0f485cf70171a41ea39deec0a8b65aad0b9d2a9b)