OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gcc.target/] [sparc/] [fmaf-1.c] - Blame information for rev 801

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 691 jeremybenn
/* { dg-do compile } */
2
/* { dg-options "-O2 -mfmaf" } */
3
 
4
float fmadds (float a, float b, float c)
5
{
6
  return a * b + c;
7
}
8
 
9
float fmsubs (float a, float b, float c)
10
{
11
  return a * b - c;
12
}
13
 
14
float fnmadds (float a, float b, float c)
15
{
16
  return -(a * b + c);
17
}
18
 
19
float fnmsubs (float a, float b, float c)
20
{
21
  return -(a * b - c);
22
}
23
 
24
double fmaddd (double a, double b, double c)
25
{
26
  return a * b + c;
27
}
28
 
29
double fmsubd (double a, double b, double c)
30
{
31
  return a * b - c;
32
}
33
 
34
double fnmaddd (double a, double b, double c)
35
{
36
  return -(a * b + c);
37
}
38
 
39
double fnmsubd (double a, double b, double c)
40
{
41
  return -(a * b - c);
42
}
43
 
44
/* { dg-final { scan-assembler "fmadds\t%" } } */
45
/* { dg-final { scan-assembler "fmsubs\t%" } } */
46
/* { dg-final { scan-assembler "fnmadds\t%" } } */
47
/* { dg-final { scan-assembler "fnmsubs\t%" } } */
48
/* { dg-final { scan-assembler "fmaddd\t%" } } */
49
/* { dg-final { scan-assembler "fmsubd\t%" } } */
50
/* { dg-final { scan-assembler "fnmaddd\t%" } } */
51
/* { dg-final { scan-assembler "fnmsubd\t%" } } */

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.