1 /* Verify that overloaded built-ins for vec_sl with int
2 inputs produce the right results. */
4 /* { dg-do compile } */
5 /* { dg-require-effective-target powerpc_altivec_ok } */
6 /* { dg-options "-maltivec -O2" } */
11 testsl_signed (vector
signed int x
, vector
unsigned int y
)
17 testsl_unsigned (vector
unsigned int x
, vector
unsigned int y
)
23 testsr_signed (vector
signed int x
, vector
unsigned int y
)
29 testsr_unsigned (vector
unsigned int x
, vector
unsigned int y
)
35 testsra_signed (vector
signed int x
, vector
unsigned int y
)
37 return vec_sra (x
, y
);
41 testsra_unsigned (vector
unsigned int x
, vector
unsigned int y
)
43 return vec_sra (x
, y
);
47 testrl_signed (vector
signed int x
, vector
unsigned int y
)
53 testrl_unsigned (vector
unsigned int x
, vector
unsigned int y
)
58 /* { dg-final { scan-assembler-times "vslw" 2 } } */
59 /* { dg-final { scan-assembler-times "vsrw" 2 } } */
60 /* { dg-final { scan-assembler-times "vsraw" 2 } } */
61 /* { dg-final { scan-assembler-times "vrlw" 2 } } */