PR tree-optimization/84740
[official-gcc.git] / gcc / testsuite / gcc.dg / lto / 20081118_0.c
blob58e0dfdbcea81d6a152bbe75d72266cf72fb2446
1 /* { dg-lto-options {{-O2 -DOPTIMIZE -flto -flto-partition=1to1} {-O0 -flto -flto-partition=1to1}} } */
3 extern void abort (void);
4 extern int f (void);
5 extern int foo (void);
7 extern inline int __attribute__ ((gnu_inline))
8 e_inline_baz (void)
10 return 1 + f();
13 int
14 bar (void)
16 return e_inline_baz ();
19 int
20 main ()
22 #ifdef OPTIMIZE
23 if (bar () != 2 || foo () != 3)
24 abort ();
25 #else
26 if (bar () != 0 || foo () != 0)
27 abort ();
28 #endif
29 return 0;