https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110643
--- Comment #17 from Mathieu Malaterre <malat at debian dot org> --- (In reply to Andrew Pinski from comment #15) > That returns a address to a local variable ... Sorry I am having a hard time driving cvise correctly. Here is the latest version: g++-13 -g -o works inf6.cc -O0 -Wall -Wextra -Werror -Wfatal-errors -> no issue valgrind --error-exitcode=1 ./works -> should only report a memleak clang++-16 -fsanitize=undefined -g -o works0 inf6.cc -Wall -Wextra -Werror -Wfatal-errors -> no issue You can reproduce the abort using: g++-13 -g -o fails inf6.cc -O1 -Wall -Wextra -Werror -Wfatal-errors -> abort Please note that my version of g++-11 & g++-12 compile the TU just fine using -O1. Could you please run a regression to identify which commit along GCC-13 branch introduce the change at least to get the ball rolling ? Thanks !