https://gcc.gnu.org/g:3ff04507dbd0e567888b1df55381e46bf6d51440

commit r17-993-g3ff04507dbd0e567888b1df55381e46bf6d51440
Author: Andrew Pinski <[email protected]>
Date:   Fri May 29 09:02:10 2026 -0700

    Fix pr125453-1.c at -O2 on some targets
    
    On some targets at -O2, pr125453-1.c testcase produces
    a -Wstringop-overflow warning. Since this testcase is not testing
    the warnings but rather an ICE, we can just add -w to the additional
    options.
    
    Pushed as obvious after testing it on x86_64-linux-gnu.
    
    gcc/testsuite/ChangeLog:
    
            * gcc.dg/torture/pr125453-1.c: Add -w to the options.
    
    Signed-off-by: Andrew Pinski <[email protected]>

Diff:
---
 gcc/testsuite/gcc.dg/torture/pr125453-1.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/gcc/testsuite/gcc.dg/torture/pr125453-1.c 
b/gcc/testsuite/gcc.dg/torture/pr125453-1.c
index d4ee478253de..e3072d6d6b13 100644
--- a/gcc/testsuite/gcc.dg/torture/pr125453-1.c
+++ b/gcc/testsuite/gcc.dg/torture/pr125453-1.c
@@ -1,5 +1,8 @@
 /* { dg-do compile } */
 /* { dg-additional-options "-fgimple" } */
+/* Disable all warnings since the code in h is undefined and could
+   invoke -Wstringop-overflow warnigns and others. */
+/* { dg-additional-options "-w" } */
 /* PR tree-optimization/125453 */
 
 int b[10];

Reply via email to