1 /* Testcase to check generation of a SH2A specific instruction
3 /* { dg-do compile { target { sh2a } } } */
4 /* { dg-options "-O1" } */
5 /* { dg-final { scan-assembler "bset"} } */
13 /* This function generates the instruction "BSET #imm3,Rn" only
14 on using optimization option "-O1" and above. */
20 volatile static struct a x
= {1, 66, ~1}, y
= {1, 2, ~2};
23 return (x
.a
== y
.a
&& (x
.b
| 1) == y
.b
);
25 return (x
.a
== y
.a
&& (x
.b
| 2) == y
.b
);
27 return (x
.a
== y
.a
&& (x
.b
| 4) == y
.b
);
29 return (x
.a
== y
.a
&& (x
.b
| 8) == y
.b
);
31 return (x
.a
== y
.a
&& (x
.b
| 16) == y
.b
);
33 return (x
.a
== y
.a
&& (x
.b
| 32) == y
.b
);
35 return (x
.a
== y
.a
&& (x
.b
| 64) == y
.b
);
37 return (x
.a
== y
.a
&& (x
.b
| 128) == y
.b
);
43 volatile unsigned char x
;