2 /* { dg-options "-O2 --save-temps -fno-inline" } */
3 /* { dg-require-effective-target arm32 } */
5 extern void abort (void);
8 bics_si_test1 (int a
, int b
, int c
)
12 /* { dg-final { scan-assembler-not "bics\tr\[0-9\]+, r\[0-9\]+, r\[0-9\]+" } } */
13 /* { dg-final { scan-assembler-times "bic\tr\[0-9\]+, r\[0-9\]+, r\[0-9\]+" 2 } } */
21 bics_si_test2 (int a
, int b
, int c
)
23 int d
= a
& ~(b
<< 3);
25 /* { dg-final { scan-assembler-not "bics\tr\[0-9\]+, r\[0-9\]+, r\[0-9\]+, .sl \#3" } } */
26 /* { dg-final { scan-assembler "bic\tr\[0-9\]+, r\[0-9\]+, r\[0-9\]+, .sl \#3" } } */
38 x
= bics_si_test1 (29, ~4, 5);
39 if (x
!= ((29 & 4) + ~4 + 5))
42 x
= bics_si_test1 (5, ~2, 20);
46 x
= bics_si_test2 (35, ~4, 5);
47 if (x
!= ((35 & ~(~4 << 3)) + ~4 + 5))
50 x
= bics_si_test2 (96, ~2, 20);