c++: normalizing ttp constraints [PR115656]
[official-gcc.git] / gcc / testsuite / gcc.target / powerpc / fold-vec-cntlz-short.c
blob23f85a49ac9fc343ca0cea227b3f6ebc68902d75
1 /* Verify that overloaded built-ins for vec_cntlz with int
2 inputs produce the right results. */
4 /* { dg-do compile } */
5 /* { dg-options "-maltivec -mvsx -O2" } */
6 /* { dg-additional-options "-mdejagnu-cpu=power8" { target { ! has_arch_pwr8 } } } */
7 /* { dg-require-effective-target powerpc_vsx } */
9 #include <altivec.h>
11 vector signed short
12 testsi (vector signed short vss2)
14 return vec_cntlz (vss2);
17 vector unsigned short
18 testui (vector unsigned short vus2)
20 return vec_cntlz (vus2);
23 /* { dg-final { scan-assembler-times "vclzh" 2 } } */