| 1 |
/* { dg-lto-do run } */ |
| 2 |
/* { dg-lto-options { { -O3 -flto -fno-early-inlining } } } */ |
| 3 |
|
| 4 |
struct a |
| 5 |
{ |
| 6 |
int foo,bar; |
| 7 |
}; |
| 8 |
struct b |
| 9 |
{ |
| 10 |
struct a a[10]; |
| 11 |
}; |
| 12 |
|
| 13 |
__attribute__ ((used)) struct b b, *bptr=&b, *bptr2=&b; |
| 14 |
__attribute__ ((used)) int i,j; |
| 15 |
|
| 16 |
extern "C" void inline_me_late (void); |
| 17 |
int n=1; |
| 18 |
|
| 19 |
int |
| 20 |
main (void) |
| 21 |
{ |
| 22 |
int jj=j; |
| 23 |
bptr2->a[jj].bar = 0; |
| 24 |
for (int i=0; i<n; i++) |
| 25 |
inline_me_late (); |
| 26 |
if (!__builtin_constant_p (bptr2->a[jj].bar == 0)) |
| 27 |
__builtin_abort (); |
| 28 |
return 0; |
| 29 |
} |