summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.target/aarch64/ccmp_2.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/gcc.target/aarch64/ccmp_2.c')
-rw-r--r--gcc/testsuite/gcc.target/aarch64/ccmp_2.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.target/aarch64/ccmp_2.c b/gcc/testsuite/gcc.target/aarch64/ccmp_2.c
new file mode 100644
index 00000000000..77ab0207886
--- /dev/null
+++ b/gcc/testsuite/gcc.target/aarch64/ccmp_2.c
@@ -0,0 +1,12 @@
+/* { dg-do compile } */
+/* { dg-options "-O2" } */
+
+int g(void);
+int h(int a, _Bool c)
+{
+ if (a != 0 && c)
+ return g();
+ return 1;
+}
+
+/* { dg-final { scan-assembler "\tccmp\t" } } */