https://gcc.gnu.org/bugzilla/show_bug.cgi?id=91258
Bug ID: 91258 Summary: [10 regression] g++.dg/ubsan/vla-1.C and gcc.dg/strlenopt-70.c fail starting with r273783 Product: gcc Version: 10.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: testsuite Assignee: unassigned at gcc dot gnu.org Reporter: seurer at gcc dot gnu.org Target Milestone: --- r273783 causes a new warning in one of the ubsan tests: spawn -ignore SIGHUP /home/seurer/gcc/build/gcc-test2/gcc/testsuite/g++/../../xg++ -B/home/seurer/gcc/build/gcc-test2/gcc/testsuite/g++/../../ /home/seurer/gcc/gcc-test2/gcc/testsuite/g++.dg/ubsan/vla-1.C -fno-diagnostics-show-caret -fno-diagnostics-show-line-numbers -fdiagnostics-color=never -nostdinc++ -I/home/seurer/gcc/build/gcc-test2/powerpc64-unknown-linux-gnu/libstdc++-v3/include/powerpc64-unknown-linux-gnu -I/home/seurer/gcc/build/gcc-test2/powerpc64-unknown-linux-gnu/libstdc++-v3/include -I/home/seurer/gcc/gcc-test2/libstdc++-v3/libsupc++ -I/home/seurer/gcc/gcc-test2/libstdc++-v3/include/backward -I/home/seurer/gcc/gcc-test2/libstdc++-v3/testsuite/util -fmessage-length=0 -O2 -flto -fuse-linker-plugin -fno-fat-lto-objects -Wno-vla -fsanitize=undefined -B/home/seurer/gcc/build/gcc-test2/powerpc64-unknown-linux-gnu/./libsanitizer/ -B/home/seurer/gcc/build/gcc-test2/powerpc64-unknown-linux-gnu/./libsanitizer/ubsan/ -L/home/seurer/gcc/build/gcc-test2/powerpc64-unknown-linux-gnu/./libsanitizer/ubsan/.libs -L/home/seurer/gcc/build/gcc-test2/powerpc64-unknown-linux-gnu/./libstdc++-v3/src/.libs -B/home/seurer/gcc/build/gcc-test2/powerpc64-unknown-linux-gnu/./libstdc++-v3/src/.libs -L/home/seurer/gcc/build/gcc-test2/powerpc64-unknown-linux-gnu/./libstdc++-v3/src/.libs -B/home/seurer/gcc/build/gcc-test2/powerpc64-unknown-linux-gnu/./libitm/ -L/home/seurer/gcc/build/gcc-test2/powerpc64-unknown-linux-gnu/./libitm/.libs -lm -o ./vla-1.exe In function 'f', inlined from 'main' at /home/seurer/gcc/gcc-test2/gcc/testsuite/g++.dg/ubsan/vla-1.C:11:4: /home/seurer/gcc/gcc-test2/gcc/testsuite/g++.dg/ubsan/vla-1.C:6:24: warning: writing 4 bytes into a region of size 0 [-Wstringop-overflow=] FAIL: g++.dg/ubsan/vla-1.C -O2 -flto -fuse-linker-plugin -fno-fat-lto-objects (test for excess errors) Excess errors: /home/seurer/gcc/gcc-test2/gcc/testsuite/g++.dg/ubsan/vla-1.C:6:24: warning: writing 4 bytes into a region of size 0 [-Wstringop-overflow=] Also, the new test case gcc.dg/strlenopt-70.c introduced in r273783 fails. spawn -ignore SIGHUP /home/seurer/gcc/build/gcc-test/gcc/xgcc -B/home/seurer/gcc/build/gcc-test/gcc/ /home/seurer/gcc/gcc-test/gcc/testsuite/gcc.dg/strlenopt-70.c -fno-diagnostics-show-caret -fno-diagnostics-show-line-numbers -fdiagnostics-color=never -O2 -fdump-tree-optimized -S -o strlenopt-70.s PASS: gcc.dg/strlenopt-70.c (test for excess errors) gcc.dg/strlenopt-70.c: pattern found 4 times FAIL: gcc.dg/strlenopt-70.c scan-tree-dump-times optimized "strlen" 0 gcc.dg/strlenopt-70.c: pattern found 8 times FAIL: gcc.dg/strlenopt-70.c scan-tree-dump-times optimized "_not_eliminated_" 0 testcase /home/seurer/gcc/gcc-test/gcc/testsuite/gcc.dg/dg.exp completed in 0 seconds === gcc Summary === # of expected passes 1 # of unexpected failures 2