[testsuite] require sqrt_insn effective target where needed
[official-gcc.git] / gcc / testsuite / gcc.target / powerpc / pr103353.c
blob5d519fb1b7ba3fde934164dffadcc2064fb34ad1
1 /* { dg-require-effective-target powerpc_altivec_ok } */
2 /* If the default cpu type is power10 or later, MMA is enabled by default.
3 To keep the test point available all the time, this case specifies
4 -mdejagnu-cpu=power6 to make it be tested without MMA. */
5 /* { dg-options "-maltivec -mdejagnu-cpu=power6" } */
7 /* Verify there is no ICE and don't check the error messages on MMA
8 requirement since they could be fragile and are not test points
9 of this case. */
10 /* { dg-excess-errors "pr103353" } */
12 void
13 foo (__vector_pair *dst, double *x)
15 dst[0] = __builtin_vsx_lxvp (0, (__vector_pair *)(void *)x);
18 void
19 bar (__vector_pair *src, double *x)
21 __builtin_vsx_stxvp (src[0], 0, (__vector_pair *)(void *)x);