1 /* { dg-do compile } */
2 /* { dg-options "-mcpu=nps400 -mcmem -O2" } */
3
4 struct strange_bool
5 {
6 unsigned short bool_bit :1;
7 unsigned short other_bits :15;
8 };
9
10 struct strange_bool a_strange_bool __attribute__((section(".cmem")));
11
12 extern void bar();
13
14 void foo() {
15 if (a_strange_bool.bool_bit)
16 bar();
17 }
18
19 /* { dg-final { scan-assembler "xldb\\s+r\[0-9\]+,\\\[@a_strange_bool\\\]" } } */
20 /* { dg-final { scan-assembler "btst_s\\s+r\[0-9\]+,7" { target arceb-*-* } } } */