Rebase.
[official-gcc.git] / gcc / testsuite / gcc.dg / tree-ssa / vrp92.c
bloba84ba8e2903c3716b6ef1f4242b04d7cf6acbddd
1 /* { dg-do compile } */
2 /* { dg-options "-O2 -fdump-tree-vrp1-details" } */
4 void bar (void);
5 int foo (int i, int j)
7 int res = 1;
8 if (i < j)
10 /* We should be able to simplify the following conditional
11 during propagation. */
12 if (i > j)
13 res = 0;
15 /* And compute res as having a value-range of [1,1]. */
16 if (res)
17 return i;
18 return j;
21 /* { dg-final { scan-tree-dump "res_.: \\\[1, 1\\\]" "vrp1" } } */
22 /* { dg-final { scan-tree-dump-not "Threaded" "vrp1" } } */
23 /* { dg-final { cleanup-tree-dump "vrp1" } } */