OSDN Git Service

PR rtl-optimization/52139
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / gcc.dg / tree-ssa / ipa-cp-1.c
1 /* { dg-do compile } */
2 /* { dg-options "-O3 -fdump-tree-optimized -fno-inline" } */
3 /* { dg-add-options bind_pic_locally } */
4
5 int
6 very_long_function(int a)
7 {
8   if (a > 0)
9     return 2 * a + very_long_function (a)/4;
10   else
11     return 2 * -a + very_long_function (a)/4;
12 }
13
14 blah ()
15 {
16   very_long_function (1);
17 }
18 /* One appereance for dump, one self recursive call and one call from main.  */
19 /* { dg-final { scan-tree-dump-times "very_long_function.constprop.0 \\(\\)" 3 "optimized"} } */
20 /* { dg-final { cleanup-tree-dump "optimized" } } */