Use conditional internal functions in if-conversion
[official-gcc.git] / gcc / testsuite / gcc.target / powerpc / fold-vec-abs-char.c
blob1f303b8d5b757b39ef3a78b66ff44c1516cf23d7
1 /* Verify that overloaded built-ins for vec_abs with char
2 inputs produce the right code. */
4 /* { dg-do compile } */
5 /* { dg-require-effective-target powerpc_altivec_ok } */
6 /* { dg-options "-maltivec -O2" } */
8 #include <altivec.h>
10 vector signed char
11 test2 (vector signed char x)
13 return vec_abs (x);
16 /* { dg-final { scan-assembler-times "vspltisw|vxor|xxspltib" 1 } } */
17 /* { dg-final { scan-assembler-times "vsububm" 1 } } */
18 /* { dg-final { scan-assembler-times "vmaxsb" 1 } } */