Update to new EH scheme.
authorBill Wendling <isanbard@gmail.com>
Thu, 1 Sep 2011 01:02:41 +0000 (01:02 +0000)
committerBill Wendling <isanbard@gmail.com>
Thu, 1 Sep 2011 01:02:41 +0000 (01:02 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138927 91177308-0d34-0410-b5e6-96231b3b80d8

test/Transforms/IndVarSimplify/2004-04-05-InvokeCastCrash.ll
test/Transforms/IndVarSimplify/2005-02-11-InvokeCrash.ll
test/Transforms/IndVarSimplify/2005-02-17-TruncateExprCrash.ll
test/Transforms/IndVarSimplify/crash.ll
test/Transforms/IndVarSimplify/interesting-invoke-use.ll

index 1ed4c44d2650cd53fbdbd9da05f19309643f9ed4..708a961272b5a3c060586e71ece615d6d95a5f0d 100644 (file)
@@ -110,12 +110,16 @@ declare void @_ZNK4llvm19MachineInstrBuilder7addMRegEiNS_14MachineOperand7UseTyp
 
 declare void @_ZNK4llvm19MachineInstrBuilder7addSImmEi()
 
+declare i32 @__gxx_personality_v0(...)
+
 define void @_ZN4llvm11_GLOBAL__N_22InsertPrologEpilogCode20runOnMachineFunctionERNS_15MachineFunctionE(%"struct.llvm::MachineFunction"* %F) {
 entry:
        %tmp.8.i = invoke %"struct.llvm::TargetFrameInfo"* null( %"struct.llvm::TargetMachine"* null )
                        to label %invoke_cont.0.i unwind label %invoke_catch.0.i                ; <%"struct.llvm::TargetFrameInfo"*> [#uses=0]
 
 invoke_catch.0.i:              ; preds = %invoke_cont.49.i, %invoke_cont.48.i, %invoke_cont.47.i, %invoke_cont.i53.i, %no_exit.i, %invoke_cont.44.i, %invoke_cont.43.i, %invoke_cont.42.i, %invoke_cont.41.i, %invoke_cont.40.i, %invoke_cont.39.i, %invoke_cont.38.i, %invoke_cont.37.i, %then.2.i, %invoke_cont.35.i, %invoke_cont.34.i, %then.1.i, %endif.0.i, %invoke_cont.9.i, %invoke_cont.8.i, %invoke_cont.7.i, %invoke_cont.i.i, %then.0.i, %invoke_cont.4.i, %invoke_cont.3.i, %invoke_cont.2.i, %invoke_cont.1.i, %endif.0.i.i, %tmp.7.i.noexc.i, %invoke_cont.0.i, %entry
+        %exn0.i = landingpad {i8*, i32} personality i32 (...)* @__gxx_personality_v0
+                 cleanup
        ret void
 
 invoke_cont.0.i:               ; preds = %entry
@@ -164,6 +168,8 @@ tmp.0.i.noexc.i:            ; preds = %then.0.i
                        to label %invoke_cont.i.i unwind label %cond_true.i.i
 
 cond_true.i.i:         ; preds = %tmp.0.i.noexc.i
+        %exn.i.i = landingpad {i8*, i32} personality i32 (...)* @__gxx_personality_v0
+                 cleanup
        ret void
 
 invoke_cont.i.i:               ; preds = %tmp.0.i.noexc.i
@@ -256,6 +262,8 @@ tmp.0.i.noexc55.i:          ; preds = %no_exit.i
                        to label %invoke_cont.i53.i unwind label %cond_true.i52.i
 
 cond_true.i52.i:               ; preds = %tmp.0.i.noexc55.i
+        %exn.i52.i = landingpad {i8*, i32} personality i32 (...)* @__gxx_personality_v0
+                 cleanup
        ret void
 
 invoke_cont.i53.i:             ; preds = %tmp.0.i.noexc55.i
index aee67ccacc5f40f5f488eb3f11847c5cb3e74edb..a5706ca6198eb46bc352bf91a7f59a2dd6500e79 100644 (file)
@@ -5,9 +5,6 @@ entry:
         %tmp.7 = invoke i32 @_ZN5ArrayISt7complexIdEE8get_sizeERK10dim_vector( )
                         to label %invoke_cont.0 unwind label %cond_true.1               ; <i32> [#uses=2]
 
-cond_true.1:            ; preds = %entry
-        unwind
-
 invoke_cont.0:          ; preds = %entry
         %tmp.4.i = bitcast i32 %tmp.7 to i32            ; <i32> [#uses=0]
         %tmp.14.0.i5 = add i32 %tmp.7, -1               ; <i32> [#uses=1]
@@ -17,7 +14,14 @@ no_exit.i:              ; preds = %no_exit.i, %invoke_cont.0
         %tmp.14.0.i.0 = phi i32 [ %tmp.14.0.i, %no_exit.i ], [ %tmp.14.0.i5, %invoke_cont.0 ]           ; <i32> [#uses=1]
         %tmp.14.0.i = add i32 %tmp.14.0.i.0, -1         ; <i32> [#uses=1]
         br label %no_exit.i
+
+cond_true.1:            ; preds = %entry
+        %exn = landingpad {i8*, i32} personality i32 (...)* @__gxx_personality_v0
+                 cleanup
+        resume { i8*, i32 } %exn
 }
 
+declare i32 @__gxx_personality_v0(...)
+
 declare i32 @_ZN5ArrayISt7complexIdEE8get_sizeERK10dim_vector()
 
index 70a7a9de05f087343814b8b90c5731ae7f0e615e..ce043beb7fd95b6b8453bc10183ff54b882a2a24 100644 (file)
@@ -10,6 +10,8 @@ entry:
                        to label %endif.1 unwind label %then.i.i551
 
 then.i.i551:           ; preds = %entry
+        %exn551 = landingpad {i8*, i32} personality i32 (...)* @__gxx_personality_v0
+                 cleanup
        ret void
 
 endif.1:               ; preds = %entry
@@ -20,6 +22,8 @@ then.2:               ; preds = %endif.1
                        to label %loopentry.0 unwind label %invoke_catch.6
 
 invoke_catch.6:                ; preds = %then.2
+        %exn6 = landingpad {i8*, i32} personality i32 (...)* @__gxx_personality_v0
+                 cleanup
        ret void
 
 loopentry.0:           ; preds = %then.2
@@ -59,3 +63,5 @@ loopexit.1:           ; preds = %no_exit.0, %endif.4
 then.i.i:              ; preds = %endif.1
        ret void
 }
+
+declare i32 @__gxx_personality_v0(...)
index 949997884a572e15801c126db80127a67d48deb4..3335be781dfc6d64aa94765cf35c2a96701ac671 100644 (file)
@@ -80,6 +80,8 @@ entry:
   br label %"3.i"
 
 "7.i":                                            ; preds = %"3.i"
+  %2 = landingpad { i8*, i32 } personality i32 (i32, i64, i8*, i8*)* @__gccgo_personality_v0
+          catch i8* null
   br label %"3.i"
 
 main.f.exit:                                      ; preds = %"3.i"
index 8adc0e5257777dc82d4b137375da5cb7cf2f7720..69bea6eaaed4dbbe87dc358c109c4f5890a7bba2 100644 (file)
@@ -47,9 +47,13 @@ bb178:          ; preds = %invcont127
   br label %bb123
 
 lpad266:                ; preds = %invcont129, %bb128, %bb123
+  %exn = landingpad {i8*, i32} personality i32 (...)* @__gxx_personality_v0
+            cleanup
   unreachable
 }
 
+declare i32 @__gxx_personality_v0(...)
+
 declare void @system__img_int__image_integer(%struct.string___XUP* noalias sret, i32)
 
 declare void @system__string_ops__str_concat(%struct.string___XUP* noalias sret, [0 x i8]*, %struct.string___XUB*, [0 x i8]*, %struct.string___XUB*)