gcc/testsuite/gcc.target/powerpc/altivec-pr22085.c
raw| 1 | /* { dg-do compile { target powerpc*-*-* } } */ |
| 2 | /* { dg-options "-maltivec -fpreprocessed" } */ |
| 3 | /* { dg-require-effective-target powerpc_altivec } */ |
| 4 | |
| 5 | /* Program to test AltiVec with -fpreprocessed. */ |
| 6 | int foo(__attribute__((altivec(vector__))) float x, |
| 7 | __attribute__((altivec(vector__))) float y) |
| 8 | { |
| 9 | if (__builtin_vec_vcmpeq_p (2, (x), (y))) |
| 10 | return 3245; |
| 11 | else |
| 12 | return 12; |
| 13 | } |