| 1 |
/* { dg-do compile } */ |
| 2 |
/* { dg-options "-O2 -mfpmath=sse -msse2" } */ |
| 3 |
/* { dg-final { scan-assembler-times "comiss" 9 } } */ |
| 4 |
/* { dg-final { scan-assembler-times "set" 9 } } */ |
| 5 |
|
| 6 |
int is_ordered_and_nonequal_sh_1 (float a, float b) |
| 7 |
{ |
| 8 |
return !__builtin_isunordered (a, b) && (a != b); |
| 9 |
} |
| 10 |
|
| 11 |
int is_ordered_and_nonequal_sh_2 (float a, float b) |
| 12 |
{ |
| 13 |
return !__builtin_isunordered (a, b) && (b != a); |
| 14 |
} |
| 15 |
|
| 16 |
int is_ordered_and_nonequal_sh_3 (float a, float b) |
| 17 |
{ |
| 18 |
return (b != a) && !__builtin_isunordered (a, b); |
| 19 |
} |
| 20 |
|
| 21 |
int is_ordered_and_nonequal_sh_4 (float a, float b) |
| 22 |
{ |
| 23 |
return !__builtin_isunordered (a, b) && !(a == b); |
| 24 |
} |
| 25 |
|
| 26 |
int is_ordered_and_nonequal_sh_5 (float a, float b) |
| 27 |
{ |
| 28 |
return !__builtin_isunordered (a, b) && !(b == a); |
| 29 |
} |
| 30 |
|
| 31 |
int is_ordered_and_nonequal_sh_6 (float a, float b) |
| 32 |
{ |
| 33 |
return !(b == a) && !__builtin_isunordered (a, b); |
| 34 |
} |
| 35 |
|
| 36 |
int is_ordered_or_nonequal_sh_7 (float a, float b) |
| 37 |
{ |
| 38 |
return !(__builtin_isunordered (a, b) || (a == b)); |
| 39 |
} |
| 40 |
|
| 41 |
int is_ordered_or_nonequal_sh_8 (float a, float b) |
| 42 |
{ |
| 43 |
return !(__builtin_isunordered (a, b) || (b == a)); |
| 44 |
} |
| 45 |
|
| 46 |
int is_ordered_or_nonequal_sh_9 (float a, float b) |
| 47 |
{ |
| 48 |
return !((a == b) || __builtin_isunordered (b, a)); |
| 49 |
} |