1 /* { dg-do compile { target { powerpc*-*-* } } } */
2 /* { dg-skip-if "do not override -mcpu" { powerpc*-*-* } { "-mcpu=*" } { "-mcpu=power9" } } */
3 /* { dg-require-effective-target powerpc_p9vector_ok } */
4 /* { dg-skip-if "" { powerpc*-*-aix* } } */
5 /* { dg-options "-mcpu=power9" } */
7 /* This test should succeed on both 32- and 64-bit configurations. */
11 test_byte_in_either_range (unsigned char b
,
12 unsigned char first_lo_bound
,
13 unsigned char first_hi_bound
,
14 unsigned char second_lo_bound
,
15 unsigned char second_hi_bound
)
17 unsigned int range_encoding
;
18 range_encoding
= ((first_hi_bound
<< 24) | (first_lo_bound
<< 16)
19 | (second_hi_bound
<< 8) | second_lo_bound
);
21 return __builtin_byte_in_either_range (b
, range_encoding
);
24 /* { dg-final { scan-assembler "cmprb" } } */
25 /* { dg-final { scan-assembler "setb" } } */