]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
testsuite: vect: Require vect_hw_misalign in gcc.dg/vect/vect-cost-model-1.c etc...
authorRainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
Mon, 11 Mar 2024 14:46:30 +0000 (15:46 +0100)
committerRainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
Mon, 11 Mar 2024 14:46:30 +0000 (15:46 +0100)
Several gcc.dg/vect/vect-cost-model-?.c tests FAIL on 32 and 64-bit
Solaris/SPARC:

FAIL: gcc.dg/vect/vect-cost-model-1.c -flto -ffat-lto-objects
scan-tree-dump vect "LOOP VECTORIZED"
FAIL: gcc.dg/vect/vect-cost-model-1.c scan-tree-dump vect "LOOP VECTORIZED"
FAIL: gcc.dg/vect/vect-cost-model-3.c -flto -ffat-lto-objects
scan-tree-dump vect "LOOP VECTORIZED"
FAIL: gcc.dg/vect/vect-cost-model-3.c scan-tree-dump vect "LOOP VECTORIZED"
FAIL: gcc.dg/vect/vect-cost-model-5.c -flto -ffat-lto-objects
scan-tree-dump vect "LOOP VECTORIZED"
FAIL: gcc.dg/vect/vect-cost-model-5.c scan-tree-dump vect "LOOP VECTORIZED"

The dumps show

/vol/gcc/src/hg/master/local/gcc/testsuite/gcc.dg/vect/vect-cost-model-1.c:7:30:
note: ==> examining statement: _3 = *_2;
/vol/gcc/src/hg/master/local/gcc/testsuite/gcc.dg/vect/vect-cost-model-1.c:7:30:
missed: unsupported unaligned access
/vol/gcc/src/hg/master/local/gcc/testsuite/gcc.dg/vect/vect-cost-model-1.c:8:6:
missed: not vectorized: relevant stmt not supported: _3 = *_2;

so I think the tests need to require vect_hw_misalign.  This is what
this patch does.

Tested on sparc-sun-solaris2.11 and i386-pc-solaris2.11.

2024-02-22  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>

gcc/testsuite:
PR tree-optimization/98238
* gcc.dg/vect/vect-cost-model-1.c (scan-tree-dump): Also require
vect_hw_misalign.
* gcc.dg/vect/vect-cost-model-3.c: Likewise.
* gcc.dg/vect/vect-cost-model-5.c: Likewise.

gcc/testsuite/gcc.dg/vect/vect-cost-model-1.c
gcc/testsuite/gcc.dg/vect/vect-cost-model-3.c
gcc/testsuite/gcc.dg/vect/vect-cost-model-5.c

index 0737da5d67189460f8cf44c20b9cb46819dd0f27..1457e8f3625bfe008ea5fa55c4f47ecc4e5ec555 100644 (file)
@@ -8,4 +8,4 @@ f (int *x, int *y)
     x[i] += y[i];
 }
 
-/* { dg-final { scan-tree-dump {LOOP VECTORIZED} vect { target vect_int } } } */
+/* { dg-final { scan-tree-dump {LOOP VECTORIZED} vect { target { vect_int && vect_hw_misalign } } } } */
index d7c6cfd204909e3ce5f7010edd10ee0f8997ffe9..fba18aae0cfcc4554236631b13ffb03e31f69fdf 100644 (file)
@@ -8,4 +8,4 @@ f (int *restrict x, int *restrict y)
     x[i] += y[i];
 }
 
-/* { dg-final { scan-tree-dump {LOOP VECTORIZED} vect { target vect_int } } } */
+/* { dg-final { scan-tree-dump {LOOP VECTORIZED} vect { target { vect_int && vect_hw_misalign } } } } */
index 536ec0a3cdaa7cf1ef868b1d4b69d026afd3d902..b9d0ca47af253bb02e466109c134d33fb7a30297 100644 (file)
@@ -8,4 +8,4 @@ f (int *restrict x, int *restrict y)
     x[i] += y[i];
 }
 
-/* { dg-final { scan-tree-dump {LOOP VECTORIZED} vect { target vect_int } } } */
+/* { dg-final { scan-tree-dump {LOOP VECTORIZED} vect { target { vect_int && vect_hw_misalign } } } } */