1; RUN: llc < %s -mtriple=i386-pc-mingw32 2 3define void @func() nounwind personality i8* bitcast (i32 (...)* @__gxx_personality_v0 to i8*) { 4invoke.cont: 5 %call = tail call i8* @malloc() 6 %a = invoke i32 @bar() 7 to label %bb1 unwind label %lpad 8 9bb1: 10 ret void 11 12lpad: 13 %exn.ptr = landingpad { i8*, i32 } 14 catch i8* null 15 %exn = extractvalue { i8*, i32 } %exn.ptr, 0 16 %eh.selector = extractvalue { i8*, i32 } %exn.ptr, 1 17 %ehspec.fails = icmp slt i32 %eh.selector, 0 18 br i1 %ehspec.fails, label %ehspec.unexpected, label %cleanup 19 20cleanup: 21 resume { i8*, i32 } %exn.ptr 22 23ehspec.unexpected: 24 tail call void @__cxa_call_unexpected(i8* %exn) noreturn nounwind 25 unreachable 26} 27 28declare noalias i8* @malloc() 29 30declare i32 @__gxx_personality_v0(...) 31 32declare void @_Unwind_Resume_or_Rethrow(i8*) 33 34declare void @__cxa_call_unexpected(i8*) 35 36declare i32 @bar() 37