1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: sed -e s/.Cxx:// %s | llc -mtriple=x86_64-pc-windows-msvc | FileCheck %s --check-prefix=CXX
3 ; RUN: sed -e s/.Seh:// %s | llc -mtriple=x86_64-pc-windows-msvc | FileCheck %s --check-prefix=SEH
5 declare i32 @__CxxFrameHandler3(...)
6 declare i32 @__C_specific_handler(...)
7 declare void @dummy_filter()
11 ;Cxx: define void @test() personality i32 (...)* @__CxxFrameHandler3 {
12 ;Seh: define void @test() personality i32 (...)* @__C_specific_handler {
15 to label %invoke.cont unwind label %catch.dispatch
18 %cs1 = catchswitch within none [label %catch.body] unwind label %catch.dispatch.2
21 ;Cxx: %catch = catchpad within %cs1 [i8* null, i32 u0x40, i8* null]
22 ;Seh: %catch = catchpad within %cs1 [void ()* @dummy_filter]
23 invoke void @f(i32 2) [ "funclet"(token %catch) ]
24 to label %unreachable unwind label %terminate
27 %cleanup = cleanuppad within %catch []
28 call void @f(i32 3) [ "funclet"(token %cleanup) ]
38 %cs2 = catchswitch within none [label %catch.body.2] unwind to caller
41 ;Cxx: %catch2 = catchpad within %cs2 [i8* null, i32 u0x40, i8* null]
42 ;Seh: %catch2 = catchpad within %cs2 [void ()* @dummy_filter]
47 ; CXX-LABEL: $ip2state$test:
48 ; CXX-NEXT: .long .Lfunc_begin0@IMGREL
50 ; CXX-NEXT: .long .Ltmp0@IMGREL+1
52 ; CXX-NEXT: .long .Ltmp1@IMGREL+1
54 ; CXX-NEXT: .long "?catch$3@?0?test@4HA"@IMGREL
56 ; CXX-NEXT: .long .Ltmp2@IMGREL+1
58 ; CXX-NEXT: .long .Ltmp3@IMGREL+1
60 ; CXX-NEXT: .long "?catch$5@?0?test@4HA"@IMGREL
64 ; SEH-LABEL: .Llsda_begin0:
65 ; SEH-NEXT: .long .Ltmp0@IMGREL+1
66 ; SEH-NEXT: .long .Ltmp1@IMGREL+1
67 ; SEH-NEXT: .long dummy_filter@IMGREL
68 ; SEH-NEXT: .long .LBB0_3@IMGREL
69 ; SEH-NEXT: .long .Ltmp0@IMGREL+1
70 ; SEH-NEXT: .long .Ltmp1@IMGREL+1
71 ; SEH-NEXT: .long dummy_filter@IMGREL
72 ; SEH-NEXT: .long .LBB0_2@IMGREL
73 ; SEH-NEXT: .long .Ltmp2@IMGREL+1
74 ; SEH-NEXT: .long .Ltmp3@IMGREL+1
75 ; SEH-NEXT: .long "?dtor$5@?0?test@4HA"@IMGREL
77 ; SEH-NEXT: .long .Ltmp2@IMGREL+1
78 ; SEH-NEXT: .long .Ltmp3@IMGREL+1
79 ; SEH-NEXT: .long dummy_filter@IMGREL
80 ; SEH-NEXT: .long .LBB0_2@IMGREL
81 ; SEH-NEXT: .Llsda_end0: