cfgexpand: Expand comment on when non-var clobbers can show up
[official-gcc.git] / gcc / testsuite / gcc.dg / vect / slp-perm-12.c
blob2bd29b8c12f2636428fb08a53dc3ee1f991883db
1 /* { dg-require-effective-target vect_int } */
2 /* { dg-require-effective-target vect_pack_trunc } */
3 /* { dg-additional-options "--param vect-epilogues-nomask=0" } */
4 /* { dg-additional-options "-msse4" { target { i?86-*-* x86_64-*-* } } } */
6 #include "tree-vect.h"
8 extern void abort (void);
10 unsigned char a[64];
11 short b[88];
13 void __attribute__((noinline))
14 test(unsigned char * __restrict__ dst, short * __restrict__ tptr)
16 int i;
17 for (i = 0; i < 8; i++)
19 dst[0] = (tptr[0] - tptr[0 + 3]);
20 dst[1] = (tptr[1] - tptr[1 + 3]);
21 dst[2] = (tptr[2] - tptr[2 + 3]);
22 dst[3] = (tptr[3] - tptr[3 + 3]);
23 dst[4] = (tptr[4] - tptr[4 + 3]);
24 dst[5] = (tptr[5] - tptr[5 + 3]);
25 dst[6] = (tptr[6] - tptr[6 + 3]);
26 dst[7] = (tptr[7] - tptr[7 + 3]);
27 dst += 8;
28 tptr += 11;
32 int main()
34 int i;
36 check_vect ();
38 for (i = 0; i < 88; ++i)
40 b[i] = i;
41 __asm__ volatile ("");
44 test (a, b);
46 #pragma GCC novector
47 for (i = 0; i < 64; ++i)
48 if (a[i] != 253)
49 abort ();
51 return 0;
54 /* { dg-final { scan-tree-dump-times "vectorizing stmts using SLP" 1 "vect" { target { vect_perm && vect_hw_misalign } } } } */