summaryrefslogtreecommitdiffstats
path: root/llvm/test
diff options
context:
space:
mode:
authorTim Northover <tnorthover@apple.com>2017-01-30 21:45:21 +0000
committerTim Northover <tnorthover@apple.com>2017-01-30 21:45:21 +0000
commit2bf8c9d381d479a0164a1991b607547bcd4d2458 (patch)
treee356c01c7f018f1877c002229c2db91ca4fa9cdd /llvm/test
parenta3b72798af09724ab6b5e08a56031b8a06692f0b (diff)
downloadbcm5719-llvm-2bf8c9d381d479a0164a1991b607547bcd4d2458.tar.gz
bcm5719-llvm-2bf8c9d381d479a0164a1991b607547bcd4d2458.zip
GlobalISel: correctly translate invoke when callee is a register.
This should fix the GlobalISel verifier. llvm-svn: 293550
Diffstat (limited to 'llvm/test')
-rw-r--r--llvm/test/CodeGen/AArch64/GlobalISel/irtranslator-exceptions.ll16
1 files changed, 15 insertions, 1 deletions
diff --git a/llvm/test/CodeGen/AArch64/GlobalISel/irtranslator-exceptions.ll b/llvm/test/CodeGen/AArch64/GlobalISel/irtranslator-exceptions.ll
index f5eacda8b09..412f70e17b2 100644
--- a/llvm/test/CodeGen/AArch64/GlobalISel/irtranslator-exceptions.ll
+++ b/llvm/test/CodeGen/AArch64/GlobalISel/irtranslator-exceptions.ll
@@ -6,7 +6,7 @@ declare i32 @foo(i32)
declare i32 @__gxx_personality_v0(...)
declare i32 @llvm.eh.typeid.for(i8*)
-; CHECK: name: bar
+; CHECK-LABEL: name: bar
; CHECK: body:
; CHECK-NEXT: bb.1 (%ir-block.0):
; CHECK: successors: %[[GOOD:bb.[0-9]+.continue]]{{.*}}%[[BAD:bb.[0-9]+.broken]]
@@ -43,3 +43,17 @@ continue:
%res.good = insertvalue { i8*, i32 } undef, i32 %sel.int, 1
ret { i8*, i32 } %res.good
}
+
+; CHECK-LABEL: name: test_invoke_indirect
+; CHECK: [[CALLEE:%[0-9]+]](p0) = COPY %x0
+; CHECK: BLR [[CALLEE]]
+define void @test_invoke_indirect(void()* %callee) personality i8* bitcast (i32 (...)* @__gxx_personality_v0 to i8*) {
+ invoke void %callee() to label %continue unwind label %broken
+
+broken:
+ landingpad { i8*, i32 } catch i8* bitcast(i8** @_ZTIi to i8*)
+ ret void
+
+continue:
+ ret void
+}
OpenPOWER on IntegriCloud