1 int x;
2 
foo(void)3 int __attribute__((noinline)) foo (void)
4 {
5   x = -x;
6   return 0;
7 }
bar(void)8 int __attribute__((const,noinline)) bar (void)
9 {
10   return 0;
11 }
12 
13 int __attribute__((noinline))
test(int c)14 test (int c)
15 {
16   int tmp = x;
17   int res = (c ? foo : bar) ();
18   return tmp + x + res;
19 }
20 
21 extern void abort (void);
main()22 int main()
23 {
24   x = 1;
25   if (test (1) != 0)
26     abort ();
27   return 0;
28 }
29