summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.target/i386/pr47312.c
blob: 03769a1cf818d38d37114259765a30d0cd9379a1 (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
/* PR target/47312 */
/* { dg-do link } */
/* { dg-require-effective-target lto } */
/* { dg-require-effective-target xop } */
/* { dg-require-effective-target c99_runtime } */
/* { dg-options "-O -flto -mno-sse3 -mxop" } */
/* { dg-add-options c99_runtime } */

extern double fma (double, double, double);
extern float fmaf (float, float, float);
extern long double fmal (long double, long double, long double);

volatile float f;
volatile double d;
volatile long double ld;

int
main ()
{
  f = fmaf (f, f, f);
  d = fma (d, d, d);
  ld = fmal (ld, ld, ld);
  __asm__ volatile ("" : : "r" (&f), "r" (&d), "r" (&ld) : "memory");
  return 0;
}