2009-07-17 Richard Guenther <rguenther@suse.de>
[official-gcc.git] / gcc / testsuite / gcc.target / mips / nmadd-3.c
blobdf726186128a83bf8d2f4bd381e43724963dd0f1
1 /* The same code as nmadd-2.c, but compiled with -fno-finite-math-only.
2 We can't use nmadd and nmsub in that case. */
3 /* { dg-do compile } */
4 /* { dg-options "-O2 -fno-fast-math -fno-finite-math-only isa=4 -mhard-float" } */
5 /* { dg-final { scan-assembler-not "nmadd.s" } } */
6 /* { dg-final { scan-assembler-not "nmadd.d" } } */
7 /* { dg-final { scan-assembler-not "nmsub.s" } } */
8 /* { dg-final { scan-assembler-not "nmsub.d" } } */
10 float
11 sub1 (float f, float g, float h)
13 return -((f * g) + h);
16 double
17 sub2 (double f, double g, double h)
19 return -((f * g) + h);
22 float
23 sub3 (float f, float g, float h)
25 return -((f * g) - h);
28 double
29 sub4 (double f, double g, double h)
31 return -((f * g) - h);