Use conditional internal functions in if-conversion
[official-gcc.git] / gcc / testsuite / gcc.target / powerpc / pr69946.c
blobe0ff422198dd321c7effa545a4e71f8c2b712051
1 /* { dg-do compile { target { powerpc*-*-* && lp64 } } } */
2 /* { dg-skip-if "" { powerpc_elfv2 } } */
3 /* { dg-options "-O2" } */
5 /* This used to generate a rotate:DI by 44, with mask 0xf00, which is
6 implemented using a rlwinm instruction. We used to write 44 for the
7 shift count there; it should be 12. */
9 struct A
11 int a : 4;
12 int : 2;
13 int b : 2;
14 int : 2;
15 int c : 2;
16 int d : 1;
17 int e;
19 struct B
21 int a : 4;
22 } *a;
23 void bar (struct A);
25 void
26 foo (void)
28 struct B b = a[0];
29 struct A c;
30 c.a = b.a;
31 c.b = 1;
32 c.c = 1;
33 c.d = 0;
34 bar (c);
37 /* { dg-final { scan-assembler-not {(?n)rlwinm.*,44,20,23} } } */