xref: /aosp_15_r20/external/llvm/test/CodeGen/X86/pr24374.ll (revision 9880d6810fe72a1726cb53787c6711e909410d58)
1*9880d681SAndroid Build Coastguard Worker; RUN: llc < %s | FileCheck %s
2*9880d681SAndroid Build Coastguard Workertarget datalayout = "e-m:w-i64:64-f80:128-n8:16:32:64-S128"
3*9880d681SAndroid Build Coastguard Workertarget triple = "x86_64-w64-windows-gnu"
4*9880d681SAndroid Build Coastguard Worker
5*9880d681SAndroid Build Coastguard Worker@llvm.global_ctors = appending global [1 x { i32, void ()*, i8* }] [{ i32, void ()*, i8* } { i32 65535, void ()* @g, i8* null }]
6*9880d681SAndroid Build Coastguard Worker
7*9880d681SAndroid Build Coastguard Workerdeclare i32 @__gxx_personality_seh0(...)
8*9880d681SAndroid Build Coastguard Worker
9*9880d681SAndroid Build Coastguard Worker; Function Attrs: nounwind
10*9880d681SAndroid Build Coastguard Workerdefine void @f() #0 personality i8* bitcast (i32 (...)* @__gxx_personality_seh0 to i8*) {
11*9880d681SAndroid Build Coastguard Workerentry:
12*9880d681SAndroid Build Coastguard Worker  invoke void @g()
13*9880d681SAndroid Build Coastguard Worker          to label %exit unwind label %lpad
14*9880d681SAndroid Build Coastguard Worker
15*9880d681SAndroid Build Coastguard Workerlpad:                                             ; preds = %entry
16*9880d681SAndroid Build Coastguard Worker  landingpad { i8*, i32 }
17*9880d681SAndroid Build Coastguard Worker          cleanup
18*9880d681SAndroid Build Coastguard Worker  unreachable
19*9880d681SAndroid Build Coastguard Worker
20*9880d681SAndroid Build Coastguard Workerexit:                                             ; preds = %entry
21*9880d681SAndroid Build Coastguard Worker  unreachable
22*9880d681SAndroid Build Coastguard Worker}
23*9880d681SAndroid Build Coastguard Worker; CHECK-LABEL: f:
24*9880d681SAndroid Build Coastguard Worker; CHECK:       .seh_proc f
25*9880d681SAndroid Build Coastguard Worker; CHECK:               .seh_handler __gxx_personality_seh0, @unwind, @except
26*9880d681SAndroid Build Coastguard Worker; CHECK:       callq g
27*9880d681SAndroid Build Coastguard Worker; CHECK:               .seh_handlerdata
28*9880d681SAndroid Build Coastguard Worker; CHECK:               .seh_endproc
29*9880d681SAndroid Build Coastguard Worker
30*9880d681SAndroid Build Coastguard Workerdefine void @g() {
31*9880d681SAndroid Build Coastguard Worker  unreachable
32*9880d681SAndroid Build Coastguard Worker}
33*9880d681SAndroid Build Coastguard Worker; CHECK-LABEL: g:
34*9880d681SAndroid Build Coastguard Worker; CHECK:       .seh_proc g
35*9880d681SAndroid Build Coastguard Worker; CHECK:       .seh_endproc
36*9880d681SAndroid Build Coastguard Worker
37*9880d681SAndroid Build Coastguard Workerattributes #0 = { nounwind }
38