]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
Fix minor testsuite scan failures for RISC-V
authorJeff Law <jlaw@ventanamicro.com>
Mon, 20 Oct 2025 11:48:54 +0000 (05:48 -0600)
committerJeff Law <jlaw@ventanamicro.com>
Mon, 20 Oct 2025 11:48:54 +0000 (05:48 -0600)
This fixes minor testsuite fallout after some of Jan's recent changes, nothing
of real significance, just minor changes in codegen causing scan tests to fail.
It's mostly an -O1/-Og problem and we can just skip the tests for those.

gcc/testsuite
* gcc.target/riscv/rvv/vsetvl/imm_switch-6.c: Skip scan-asm test for -O1 too.
* gcc.target/riscv/rvv/vsetvl/imm_switch-7.c: Likewise.
* gcc.target/riscv/shrink-wrap-1.c: Likewise.  Skip for -Og as well.
* gcc.target/riscv/xandes/xandesperf-1.c: Adjust expected output.

gcc/testsuite/gcc.target/riscv/rvv/vsetvl/imm_switch-6.c
gcc/testsuite/gcc.target/riscv/rvv/vsetvl/imm_switch-7.c
gcc/testsuite/gcc.target/riscv/shrink-wrap-1.c
gcc/testsuite/gcc.target/riscv/xandes/xandesperf-1.c

index 32c4f03b6abdfef75cf5cf56903d5757033b8145..4c419b6058896e83c711b8e7216c64987a5d0a93 100644 (file)
@@ -25,6 +25,6 @@ void f (void * restrict in, void * restrict out, int n)
     }
 }
 
-/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*5,\s*e8,\s*mf8,\s*t[au],\s*m[au]} 1 { target { no-opts "-O0" no-opts "-Os" no-opts "-Oz" no-opts "-g" no-opts "-funroll-loops" } } } } */
-/* { dg-final { scan-assembler-times {\.L[0-9]+\:\s+vsetivli\s+zero,\s*5,\s*e16,\s*mf4,\s*t[au],\s*m[au]\s+\.L[0-9]+} 1 { target { no-opts "-O0" no-opts "-Os" no-opts "-Oz" no-opts "-g" no-opts "-funroll-loops" } } } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*5,\s*e8,\s*mf8,\s*t[au],\s*m[au]} 1 { target { no-opts "-O0" no-opts "-Os" no-opts "-Oz" no-opts "-g" no-opts "-funroll-loops" no-opts "-O1" } } } } */
+/* { dg-final { scan-assembler-times {\.L[0-9]+\:\s+vsetivli\s+zero,\s*5,\s*e16,\s*mf4,\s*t[au],\s*m[au]\s+\.L[0-9]+} 1 { target { no-opts "-O0" no-opts "-Os" no-opts "-Oz" no-opts "-g" no-opts "-funroll-loops" no-opts "-O1" } } } } */
 
index 927ea1f156898b0dd3bb346704b7a233e509068f..38d44862573111a19a3bb9e5c020331445ee2f0f 100644 (file)
@@ -24,6 +24,6 @@ void f (void * restrict in, void * restrict out, int n)
     }
 }
 
-/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*5,\s*e8,\s*mf8,\s*t[au],\s*m[au]} 1 { target { no-opts "-O0" no-opts "-Os" no-opts "-Oz" no-opts "-g" no-opts "-funroll-loops" } } } } */
-/* { dg-final { scan-assembler-times {\.L[0-9]+\:\s+vsetivli\s+zero,\s*5,\s*e16,\s*mf4,\s*t[au],\s*m[au]} 1 { target { no-opts "-O0" no-opts "-Os" no-opts "-Oz" no-opts "-g" no-opts "-funroll-loops" } } } } */
-/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*8,\s*e16,\s*mf2,\s*t[au],\s*m[au]} 1 { target { no-opts "-O0" no-opts "-Os" no-opts "-Oz" no-opts "-g" no-opts "-funroll-loops" } } } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*5,\s*e8,\s*mf8,\s*t[au],\s*m[au]} 1 { target { no-opts "-O0" no-opts "-Os" no-opts "-Oz" no-opts "-g" no-opts "-funroll-loops" no-opts "-O1" } } } } */
+/* { dg-final { scan-assembler-times {\.L[0-9]+\:\s+vsetivli\s+zero,\s*5,\s*e16,\s*mf4,\s*t[au],\s*m[au]} 1 { target { no-opts "-O0" no-opts "-Os" no-opts "-Oz" no-opts "-g" no-opts "-funroll-loops" no-opts "-O1" } } } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*8,\s*e16,\s*mf2,\s*t[au],\s*m[au]} 1 { target { no-opts "-O0" no-opts "-Os" no-opts "-Oz" no-opts "-g" no-opts "-funroll-loops" no-opts "-O1" } } } } */
index e1e07c3d4c540cef4b5bc0b32823f85a00491468..4a15983d63ca1bcdb3ad5f42b59aa9394afae2a9 100644 (file)
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-fshrink-wrap" } */
-/* { dg-skip-if "" { *-*-* } { "-O0" "-Os" "-Oz" } } */
+/* { dg-skip-if "" { *-*-* } { "-O0" "-Os" "-Oz" "-O1" "-Og" } } */
 
 void g(void);
 
index b8db0d84614e14544822bcd6a71821cf947f2787..20bdad397127869767961d91bd23fec5c946e2c6 100644 (file)
@@ -10,4 +10,4 @@ long foo (long cond)
   return cond;
 }
 
-/* { dg-final { scan-assembler {\mnds.beqc} } } */
+/* { dg-final { scan-assembler {\mnds.b..c} } } */