| 1 |
/* { dg-do compile } */ |
| 2 |
/* { dg-options "-mhard-float -march=mips32r6" } */ |
| 3 |
/* { dg-skip-if "code quality test" { *-*-* } { "-O0" } { "" } } */ |
| 4 |
|
| 5 |
extern double fmin (double, double); |
| 6 |
extern double fmax (double, double); |
| 7 |
extern float fminf (float, float); |
| 8 |
extern float fmaxf (float, float); |
| 9 |
|
| 10 |
/* Test MIN.D. */ |
| 11 |
|
| 12 |
/* { dg-final { scan-assembler "\tmin\\.d\t" } } */ |
| 13 |
double test01 (double x, double y) { |
| 14 |
return fmin (x, y); |
| 15 |
} |
| 16 |
|
| 17 |
/* Test MIN.S. */ |
| 18 |
|
| 19 |
/* { dg-final { scan-assembler "\tmin\\.s\t" } } */ |
| 20 |
float test02 (float x, float y) { |
| 21 |
return fminf (x, y); |
| 22 |
} |
| 23 |
|
| 24 |
/* Test MAX.D. */ |
| 25 |
|
| 26 |
/* { dg-final { scan-assembler "\tmax\\.d\t" } } */ |
| 27 |
double test03 (double x, double y) { |
| 28 |
return fmax (x, y); |
| 29 |
} |
| 30 |
|
| 31 |
/* Test MAX.S. */ |
| 32 |
|
| 33 |
/* { dg-final { scan-assembler "\tmax\\.s\t" } } */ |
| 34 |
float test04 (float x, float y) { |
| 35 |
return fmaxf (x, y); |
| 36 |
} |