aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/tree-ssa/vrp-float-relations-6.c
blob: a75ae5d64fff5ac415b82cba1dd5f43a228c4a58 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
// { dg-do compile }
// { dg-options "-O2 -fgimple -fdump-tree-evrp" }

void link_error();

void __GIMPLE (ssa,startwith("evrp"))
foo1 (float x, float y)
{
  __BB(2):
  if (x_4(D) >= y_5(D))
    goto __BB5;
  else
    goto __BB3;

  __BB(3):
  // Relation at this point is VREL_LT.
  if (x_4(D) __UNLT y_5(D))
    goto __BB5;
  else
    goto __BB4;

  __BB(4):
  link_error ();
  goto __BB5;

  __BB(5):
  return;
}

void __GIMPLE (ssa,startwith("evrp"))
foo2 (float x, float y)
{
  __BB(2):
  if (x_4(D) >= y_5(D))
    goto __BB5;
  else
    goto __BB3;

  __BB(3):
  // Relation at this point is VREL_LT.
  if (x_4(D) __UNLE y_5(D))
    goto __BB5;
  else
    goto __BB4;

  __BB(4):
  link_error ();
  goto __BB5;

  __BB(5):
  return;
}

// { dg-final { scan-tree-dump-not "link_error" "evrp" } }