PR middle-end/77357 - strlen of constant strings not folded
[official-gcc.git] / gcc / testsuite / gcc.dg / ipa / ipa-pta-8.c
blob5bedc9d8a6550df8f772982c012a0ba5351f120b
1 /* { dg-do run } */
2 /* { dg-options "-O2 -fno-early-inlining -fipa-pta" } */
4 static int *__attribute__((noinline,noclone))
5 pass_me (int *p)
7 return p;
10 /* When foo is inlined into main we have to make sure to adjust
11 main()s IPA CLOBBERED set according to the decl remappings
12 inlining does. */
14 static int
15 foo (void)
17 int a = 0;
18 int *p = pass_me (&a);
19 *p = 1;
20 return a;
23 extern void abort (void);
25 int main()
27 if (foo () != 1)
28 abort ();
30 return 0;