aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/gcc.target/i386/pr26778.c
blob: f871b5d61f37391d154ae4cdea42a05414a70d68 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
/* { dg-do compile } */
/* { dg-require-effective-target ia32 } */
/* { dg-options "-O2 -march=pentium3" } */

typedef union {
  long long l;
  double d;
} db_number;

double test(double x[3]) {
  double th = x[1] + x[2];
  if (x[2] != th - x[1]) {
    db_number thdb;
    thdb.d = th;
    thdb.l++;
    th = thdb.d;
  }
  return x[0] + th;
}

/* { dg-final { scan-assembler-not "mov.ps" } } */