1 ; RUN: llc -mtriple=x86_64-pc-windows-coreclr < %s | FileCheck %s
3 declare void @ProcessCLRException()
4 declare ptr addrspace(1) @llvm.eh.exceptionpointer.p1(token)
6 declare void @g(ptr addrspace(1))
8 ; CHECK-LABEL: test1: # @test1
9 define void @test1() personality ptr @ProcessCLRException {
12 to label %exit unwind label %catch.pad
14 %cs1 = catchswitch within none [label %catch.body] unwind to caller
16 ; CHECK: {{^[^: ]+}}: # %catch.body
17 ; CHECK: movq %rdx, %rcx
19 %catch = catchpad within %cs1 [i32 5]
20 %exn = call ptr addrspace(1) @llvm.eh.exceptionpointer.p1(token %catch)
21 call void @g(ptr addrspace(1) %exn) [ "funclet"(token %catch) ]
22 catchret from %catch to label %exit