Fix PR3807 by inserting 'insertelement' instructions in the normal dest of

an invoke instead of after the invoke (in its block), which is invalid.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@67139 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Chris Lattner
2009-03-18 00:31:45 +00:00
parent 64ec298e68
commit bda0765e07
2 changed files with 25 additions and 5 deletions

View File

@@ -0,0 +1,15 @@
; RUN: llvm-as < %s | opt -deadargelim | llvm-dis
; PR3807
define internal { i32, i32 } @foo() {
ret {i32,i32} {i32 42, i32 4}
}
define i32 @bar() {
%x = invoke {i32,i32} @foo() to label %T unwind label %T2
T:
%y = extractvalue {i32,i32} %x, 1
ret i32 %y
T2:
unreachable
}