mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2026-04-27 04:18:42 +00:00
New EH representation for MSVC compatibility
This introduces new instructions neccessary to implement MSVC-compatible exception handling support. Most of the middle-end and none of the back-end haven't been audited or updated to take them into account. Differential Revision: http://reviews.llvm.org/D11097 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@243766 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
1 parent
aa50fa7c2f
commit
4a45f0871a
39 files changed
+2313
-121
No files matched your search
@@ -25,3 +25,74 @@ lpad: ; preds = %entry
|
||||
declare void @_Z3quxv() optsize
|
||||
|
||||
declare i32 @__gxx_personality_v0(...)
|
||||
|
||||
define void @cleanupret0() personality i32 (...)* @__gxx_personality_v0 {
|
||||
entry:
|
||||
br label %bb
|
||||
bb:
|
||||
cleanuppad void [i7 4]
|
||||
cleanupret i8 0 unwind label %bb
|
||||
}
|
||||
|
||||
define void @cleanupret1() personality i32 (...)* @__gxx_personality_v0 {
|
||||
entry:
|
||||
br label %bb
|
||||
bb:
|
||||
cleanuppad void [i7 4]
|
||||
cleanupret void unwind label %bb
|
||||
}
|
||||
|
||||
define void @cleanupret2() personality i32 (...)* @__gxx_personality_v0 {
|
||||
entry:
|
||||
cleanupret i8 0 unwind to caller
|
||||
}
|
||||
|
||||
define void @cleanupret3() personality i32 (...)* @__gxx_personality_v0 {
|
||||
cleanupret void unwind to caller
|
||||
}
|
||||
|
||||
define void @catchret() personality i32 (...)* @__gxx_personality_v0 {
|
||||
entry:
|
||||
br label %bb
|
||||
bb:
|
||||
catchret label %bb
|
||||
}
|
||||
|
||||
define i8 @catchpad() personality i32 (...)* @__gxx_personality_v0 {
|
||||
entry:
|
||||
br label %bb2
|
||||
bb:
|
||||
ret i8 %cbv
|
||||
bb2:
|
||||
%cbv = catchpad i8 [i7 4] to label %bb unwind label %bb2
|
||||
}
|
||||
|
||||
define void @terminatepad0() personality i32 (...)* @__gxx_personality_v0 {
|
||||
entry:
|
||||
br label %bb
|
||||
bb:
|
||||
terminatepad [i7 4] unwind label %bb
|
||||
}
|
||||
|
||||
define void @terminatepad1() personality i32 (...)* @__gxx_personality_v0 {
|
||||
entry:
|
||||
terminatepad [i7 4] unwind to caller
|
||||
}
|
||||
|
||||
define void @cleanuppad() personality i32 (...)* @__gxx_personality_v0 {
|
||||
entry:
|
||||
cleanuppad void [i7 4]
|
||||
ret void
|
||||
}
|
||||
|
||||
define void @catchendpad0() personality i32 (...)* @__gxx_personality_v0 {
|
||||
entry:
|
||||
br label %bb
|
||||
bb:
|
||||
catchendpad unwind label %bb
|
||||
}
|
||||
|
||||
define void @catchendpad1() personality i32 (...)* @__gxx_personality_v0 {
|
||||
entry:
|
||||
catchendpad unwind to caller
|
||||
}
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
; PR1042
|
||||
define i32 @foo() {
|
||||
; CHECK: The unwind destination does not have a landingpad instruction
|
||||
; CHECK: The unwind destination does not have an exception handling instruction
|
||||
%A = invoke i32 @foo( )
|
||||
to label %L unwind label %L ; <i32> [#uses=1]
|
||||
L: ; preds = %0, %0
|
||||
@@ -18,7 +18,7 @@ L1: ; preds = %0
|
||||
L2: ; preds = %0
|
||||
br label %L
|
||||
L: ; preds = %L2, %L1, %L1
|
||||
; CHECK: The unwind destination does not have a landingpad instruction
|
||||
; CHECK: The unwind destination does not have an exception handling instruction
|
||||
ret i32 %A
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user