aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.target/csky/and1.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/gcc.target/csky/and1.c')
-rw-r--r--gcc/testsuite/gcc.target/csky/and1.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.target/csky/and1.c b/gcc/testsuite/gcc.target/csky/and1.c
new file mode 100644
index 0000000..14ce11a
--- /dev/null
+++ b/gcc/testsuite/gcc.target/csky/and1.c
@@ -0,0 +1,12 @@
+/* { dg-do compile } */
+/* { dg-csky-options "-O1" } */
+
+/* Test special code generation patterns for bit operators. */
+
+int and1 (int x)
+{
+ return x & 0xfff7ffff;
+}
+
+/* { dg-final { scan-assembler "bclri" } } */
+