[testsuite] require sqrt_insn effective target where needed
[official-gcc.git] / gcc / testsuite / gcc.target / powerpc / pr88100.c
blob764c897a497669b55b874e1d9da5a7049edba18b
1 /* PR88100. Verify that rs6000 gimple-folding code handles the
2 vec_splat_{su}{8,16,32} invalid data properly. */
4 /* { dg-do compile } */
5 /* { dg-require-effective-target powerpc_altivec_ok } */
6 /* { dg-options "-maltivec" } */
8 #include <altivec.h>
10 vector unsigned char
11 splatu1 (void)
13 return vec_splat_u8(0x100);/* { dg-error "argument 1 must be a literal between -16 and 15, inclusive" } */
16 vector unsigned short
17 splatu2 (void)
19 return vec_splat_u16(0x10000);/* { dg-error "argument 1 must be a literal between -16 and 15, inclusive" } */
22 vector unsigned int
23 splatu3 (void)
25 return vec_splat_u32(0x10000000);/* { dg-error "argument 1 must be a literal between -16 and 15, inclusive" } */
28 vector signed char
29 splats1 (void)
31 return vec_splat_s8(0x100);/* { dg-error "argument 1 must be a literal between -16 and 15, inclusive" } */
34 vector signed short
35 splats2 (void)
37 return vec_splat_s16(0x10000);/* { dg-error "argument 1 must be a literal between -16 and 15, inclusive" } */
40 vector signed int
41 splats3 (void)
43 return vec_splat_s32(0x10000000);/* { dg-error "argument 1 must be a literal between -16 and 15, inclusive" } */