summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-11.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-11.c')
-rw-r--r--gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-11.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-11.c b/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-11.c
new file mode 100644
index 00000000000..0065b77746a
--- /dev/null
+++ b/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-11.c
@@ -0,0 +1,15 @@
+/* { dg-do compile { target { powerpc*-*-* } } } */
+/* { dg-skip-if "do not override -mcpu" { powerpc*-*-* } { "-mcpu=*" } { "-mcpu=power8" } } */
+/* { dg-require-effective-target powerpc_p9vector_ok } */
+/* { dg-options "-mcpu=power8" } */
+
+#include <altivec.h>
+#include <stdbool.h>
+
+bool
+test_data_class (__ieee128 *p)
+{
+ __ieee128 source = *p;
+
+ return __builtin_vec_scalar_test_data_class (source, 3); /* { dg-error "Builtin function __builtin_vsx_scalar_test_data_class_qp requires" } */
+}