1 /* Verify that overloaded built-ins for vec_cntlz with char
2    inputs produce the right results.  */
3 
4 /* { dg-do compile } */
5 /* { dg-require-effective-target powerpc_p8vector_ok } */
6 /* { dg-options "-maltivec -mpower8-vector -O2" } */
7 
8 #include <altivec.h>
9 
10 vector signed char
testsc_h(vector signed char vsc2)11 testsc_h (vector signed char vsc2)
12 {
13   return vec_cntlz (vsc2);
14 }
15 
16 vector unsigned char
testuc_h(vector unsigned char vuc2)17 testuc_h (vector unsigned char vuc2)
18 {
19   return vec_cntlz (vuc2);
20 }
21 
22 /* { dg-final { scan-assembler-times "vclzb" 2 } } */
23