[testsuite] require sqrt_insn effective target where needed
[official-gcc.git] / gcc / testsuite / gcc.target / powerpc / pr104015-1.c
blob272499cfa5cbe10534ff538ac7283686dfe82e0d
1 /* { dg-require-effective-target powerpc_vsx_ok } */
2 /* { dg-options "-mdejagnu-cpu=power9 -mvsx -O2 -ftree-vectorize -fno-vect-cost-model -fdump-tree-vect-details" } */
4 /* As PR104015, we don't expect vectorizer will re-try some vector modes
5 for epilogues on Power9, since Power9 doesn't support partial vector
6 by defaut. */
8 #include <stdarg.h>
9 #define N 200
11 void __attribute__((noinline))
12 foo (unsigned short *__restrict__ pInput, unsigned short *__restrict__ pOutput)
14 unsigned short i, a, b, c;
16 for (i = 0; i < N / 3; i++)
18 a = *pInput++;
19 b = *pInput++;
20 c = *pInput++;
22 *pOutput++ = a + b + c + 3;
23 *pOutput++ = a + b + c + 12;
24 *pOutput++ = a + b + c + 1;
28 /* { dg-final { scan-tree-dump-not "Re-trying epilogue analysis with vector mode" "vect" } } */