summaryrefslogtreecommitdiff
path: root/test/CodeGen/AMDGPU/si-annotate-cf-assertion.ll
diff options
context:
space:
mode:
authorDimitry Andric <dim@FreeBSD.org>2015-06-21 13:59:01 +0000
committerDimitry Andric <dim@FreeBSD.org>2015-06-21 13:59:01 +0000
commit3a0822f094b578157263e04114075ad7df81db41 (patch)
treebc48361fe2cd1ca5f93ac01b38b183774468fc79 /test/CodeGen/AMDGPU/si-annotate-cf-assertion.ll
parent85d8b2bbe386bcfe669575d05b61482d7be07e5d (diff)
Diffstat (limited to 'test/CodeGen/AMDGPU/si-annotate-cf-assertion.ll')
-rw-r--r--test/CodeGen/AMDGPU/si-annotate-cf-assertion.ll25
1 files changed, 25 insertions, 0 deletions
diff --git a/test/CodeGen/AMDGPU/si-annotate-cf-assertion.ll b/test/CodeGen/AMDGPU/si-annotate-cf-assertion.ll
new file mode 100644
index 000000000000..69d719385acd
--- /dev/null
+++ b/test/CodeGen/AMDGPU/si-annotate-cf-assertion.ll
@@ -0,0 +1,25 @@
+; REQUIRES: asserts
+; XFAIL: *
+; RUN: llc -march=amdgcn -mcpu=SI -verify-machineinstrs-asm-verbose=false < %s | FileCheck %s
+; RUN: llc -march=amdgcn -mcpu=tonga -verify-machineinstrs-asm-verbose=false < %s | FileCheck %s
+
+
+define void @test(i32 addrspace(1)* %g, i8 addrspace(3)* %l, i32 %x) nounwind {
+; CHECK-LABEL: {{^}}test:
+
+entry:
+ switch i32 %x, label %sw.default [
+ i32 0, label %sw.bb
+ i32 60, label %sw.bb
+ ]
+
+sw.bb:
+ unreachable
+
+sw.default:
+ unreachable
+
+sw.epilog:
+ ret void
+}
+