aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/gcc.target/sparc/cmask.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc-4.9/gcc/testsuite/gcc.target/sparc/cmask.c')
-rw-r--r--gcc-4.9/gcc/testsuite/gcc.target/sparc/cmask.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/gcc-4.9/gcc/testsuite/gcc.target/sparc/cmask.c b/gcc-4.9/gcc/testsuite/gcc.target/sparc/cmask.c
new file mode 100644
index 000000000..d1be910f5
--- /dev/null
+++ b/gcc-4.9/gcc/testsuite/gcc.target/sparc/cmask.c
@@ -0,0 +1,21 @@
+/* { dg-do compile } */
+/* { dg-options "-mvis3" } */
+
+void test_cm8 (long x)
+{
+ __builtin_vis_cmask8 (x);
+}
+
+void test_cm16 (long x)
+{
+ __builtin_vis_cmask16 (x);
+}
+
+void test_cm32 (long x)
+{
+ __builtin_vis_cmask32 (x);
+}
+
+/* { dg-final { scan-assembler "cmask8\t%" } } */
+/* { dg-final { scan-assembler "cmask16\t%" } } */
+/* { dg-final { scan-assembler "cmask32\t%" } } */