| 1 |
/* { dg-do compile { target { powerpc*-*-linux* } } } */ |
| 2 |
/* { dg-options "-O2 -mvsx -mno-float128" } */ |
| 3 |
/* { dg-require-effective-target powerpc_vsx } */ |
| 4 |
|
| 5 |
/* Test that we can use #pragma GCC target to enable -mfloat128. */ |
| 6 |
|
| 7 |
#ifdef __FLOAT128__ |
| 8 |
#error "-mno-float128 should disable initially defining __FLOAT128__" |
| 9 |
#endif |
| 10 |
|
| 11 |
#pragma GCC target("float128") |
| 12 |
|
| 13 |
#ifndef __FLOAT128__ |
| 14 |
#error "#pragma GCC target(\"float128\") should enable -mfloat128" |
| 15 |
#endif |
| 16 |
|
| 17 |
__float128 |
| 18 |
qadd (__float128 a, __float128 b) |
| 19 |
{ |
| 20 |
return a+b; |
| 21 |
} |