[testsuite] Fix directives order
[official-gcc.git] / gcc / testsuite / gcc.target / powerpc / ppc-fma-7.c
blob57c4b734eb55afbd29bf96377ce020c34e82802e
1 /* { dg-do compile { target { powerpc*-*-* } } } */
2 /* { dg-skip-if "" { powerpc*-*-darwin* } } */
3 /* { dg-require-effective-target powerpc_altivec_ok } */
4 /* { dg-require-effective-target powerpc_fprs } */
5 /* { dg-skip-if "do not override -mcpu" { powerpc*-*-* } { "-mcpu=*" } { "-mcpu=power6" } } */
6 /* { dg-options "-O3 -ftree-vectorize -mcpu=power6 -ffast-math" } */
7 /* { dg-final { scan-assembler-times "fmadd" 1 } } */
8 /* { dg-final { scan-assembler-times "fmsub " 1 } } */
9 /* { dg-final { scan-assembler-not "fmul" } } */
10 /* { dg-final { scan-assembler-not "fadd " } } */
12 /* Check whether the common FFT idiom (a*b)+c and (a*b)-c generates two fma
13 instructions, instead of a multiply, add, and subtract. */
15 void
16 fft (double *result, double a, double b, double c)
18 result[0] = (a*b) + c;
19 result[1] = (a*b) - c;