Mercurial > hg > CbC > CbC_gcc
annotate gcc/testsuite/gcc.dg/tree-ssa/vrp11.c @ 131:84e7813d76e9
gcc-8.2
author | mir3636 |
---|---|
date | Thu, 25 Oct 2018 07:37:49 +0900 |
parents | 04ced10e8804 |
children |
rev | line source |
---|---|
111 | 1 /* { dg-do compile } */ |
2 /* { dg-options "-O2 -fdump-tree-vrp1 -fno-early-inlining" } */ | |
3 | |
4 inline int | |
5 bounce (int arg) | |
6 { | |
7 return arg; | |
8 } | |
9 | |
10 int | |
11 foo (int k, int j, int z) | |
12 { | |
13 if (k > z) | |
14 { | |
15 if (j > k) | |
16 { | |
17 /* We should fold this to if (1). */ | |
18 if (j > bounce (z)) | |
19 return j; | |
20 } | |
21 } | |
22 | |
23 return j+1; | |
24 } | |
25 | |
26 /* { dg-final { scan-tree-dump-times "Folding predicate.*to 1" 1 "vrp1" } } */ |