diff options
Diffstat (limited to 'gcc/testsuite/gcc.target/powerpc/bfp/scalar-extract-exp-4.c')
-rw-r--r-- | gcc/testsuite/gcc.target/powerpc/bfp/scalar-extract-exp-4.c | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.target/powerpc/bfp/scalar-extract-exp-4.c b/gcc/testsuite/gcc.target/powerpc/bfp/scalar-extract-exp-4.c new file mode 100644 index 0000000..5022415 --- /dev/null +++ b/gcc/testsuite/gcc.target/powerpc/bfp/scalar-extract-exp-4.c @@ -0,0 +1,18 @@ +/* { dg-do compile { target { powerpc*-*-* } } } */ +/* { dg-skip-if "do not override -mcpu" { powerpc*-*-* } { "-mcpu=*" } { "-mcpu=power8" } } */ +/* { dg-require-effective-target lp64 } */ +/* { dg-require-effective-target powerpc_p9vector_ok } */ +/* { dg-options "-mcpu=power8" } */ + +/* This test should succeed only on 64-bit configurations. */ +#include <altivec.h> + +unsigned long long int +get_exponent (__ieee128 *p) +{ + __ieee128 source = *p; + + return __builtin_vec_scalar_extract_exp (source); /* { dg-error "Builtin function __builtin_vsx_scalar_extract_expq requires" } */ +} + + |