aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/tree-ssa/vrp-float-3a.c
blob: 5aadaa7c4db61fcd4a1d5c5b1b79666b75443f46 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
// { dg-do compile }
// { dg-options "-O2 -fno-thread-jumps -fdisable-tree-fre1 -fdump-tree-evrp" }

void link_error ();
void bar ();

float
foo (float x)
{
  if (x != x)
    {
      // The true side of x != x implies NAN, so we should be able to
      // fold this.
      if (!__builtin_isnan (x))
	link_error ();
    }
}

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