summaryrefslogtreecommitdiff
path: root/test/CodeGen/XCore
diff options
context:
space:
mode:
authorDimitry Andric <dim@FreeBSD.org>2012-08-15 19:34:23 +0000
committerDimitry Andric <dim@FreeBSD.org>2012-08-15 19:34:23 +0000
commit58b69754af0cbff56b1cfce9be9392e4451f6628 (patch)
treeeacfc83d988e4b9d11114387ae7dc41243f2a363 /test/CodeGen/XCore
parent0378662f5bd3dbe8305a485b0282bceb8b52f465 (diff)
Notes
Diffstat (limited to 'test/CodeGen/XCore')
-rw-r--r--test/CodeGen/XCore/mkmsk.ll11
1 files changed, 11 insertions, 0 deletions
diff --git a/test/CodeGen/XCore/mkmsk.ll b/test/CodeGen/XCore/mkmsk.ll
new file mode 100644
index 0000000000000..377612b7d215a
--- /dev/null
+++ b/test/CodeGen/XCore/mkmsk.ll
@@ -0,0 +1,11 @@
+; RUN: llc < %s -march=xcore | FileCheck %s
+
+define i32 @f(i32) nounwind {
+; CHECK: f:
+; CHECK: mkmsk r0, r0
+; CHECK-NEXT: retsp 0
+entry:
+ %1 = shl i32 1, %0
+ %2 = add i32 %1, -1
+ ret i32 %2
+}