PR middle-end/77357 - strlen of constant strings not folded
[official-gcc.git] / gcc / testsuite / gcc.dg / ipa / noclone-1.c
blobc405e61b732b1ba86159c1e5bf4f6c755b991dc1
1 /* { dg-do compile } */
2 /* { dg-options "-O3 -fipa-cp -fipa-cp-clone -fdump-ipa-cp -fno-early-inlining" } */
4 int global_1, global_2;
6 __attribute__((__noclone__)) int g (int b, int c)
8 global_1 = b;
9 global_2 = c;
12 __attribute__((__noclone__)) int f (int a)
14 /* Second parameter of g gets different values. */
15 if (a > 0)
16 g (a, 3);
17 else
18 g (a, 5);
21 int main ()
23 f (7);
24 return 0;
28 /* { dg-final { scan-ipa-dump-times "versioned function" 0 "cp" } } */