summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/ifcvt-2.c
diff options
context:
space:
mode:
authorbstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4>2016-02-10 17:20:51 +0000
committerbstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4>2016-02-10 17:20:51 +0000
commit2d9d01985a7a7866916fafa19c5c296702e69714 (patch)
tree259c095c65fc0c6279b7a17755b3f851f51babb3 /gcc/testsuite/gcc.dg/ifcvt-2.c
parentc8ebeb0e3c6b093e649592be7d51d1c0032a1dc7 (diff)
downloadgcc-2d9d01985a7a7866916fafa19c5c296702e69714.tar.gz
2016-02-10 Basile Starynkevitch <basile@starynkevitch.net>
{{merging with even more of GCC 6, using subversion 1.9 svn merge -r227001:227400 ^/trunk ; there is some gengtype issue before svn r228000... }} git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/melt-branch@233281 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/testsuite/gcc.dg/ifcvt-2.c')
-rw-r--r--gcc/testsuite/gcc.dg/ifcvt-2.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.dg/ifcvt-2.c b/gcc/testsuite/gcc.dg/ifcvt-2.c
new file mode 100644
index 00000000000..e0e1728a34c
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/ifcvt-2.c
@@ -0,0 +1,17 @@
+/* { dg-do compile { target aarch64*-*-* x86_64-*-* } } */
+/* { dg-options "-fdump-rtl-ce1 -O2" } */
+
+
+typedef unsigned char uint8_t;
+typedef unsigned int uint16_t;
+
+uint8_t
+_xtime (const uint8_t byte, const uint16_t generator)
+{
+ if (byte & 0x80)
+ return byte ^ generator;
+ else
+ return byte << 1;
+}
+
+/* { dg-final { scan-rtl-dump "3 true changes made" "ce1" } } */