1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2025-01-31 20:51:52 +01:00
llvm-mirror/test/CodeGen/X86/gnu-seh-nolpads.ll
Reid Kleckner 1848150600 [EH] Recognize __(gxx|gcc)_personality_seh0 as the GNU EH personalities
These are no-ops when there are no invokes. We don't need to emit LSDAs
for them.

Fixes PR33220.

llvm-svn: 304367
2017-05-31 22:35:52 +00:00

35 lines
785 B
LLVM

; RUN: llc -mtriple=x86_64-windows-gnu < %s | FileCheck %s
declare void @throwit()
declare void @__gxx_personality_seh0(...)
declare void @__gcc_personality_seh0(...)
define void @use_gxx_seh()
personality void (...)* @__gxx_personality_seh0 {
entry:
call void @throwit()
unreachable
}
; CHECK-LABEL: use_gxx_seh:
; CHECK: .seh_proc use_gxx_seh
; CHECK-NOT: .seh_handler __gxx_personality_seh0
; CHECK: callq throwit
; CHECK: .seh_handlerdata
; CHECK: .seh_endproc
define void @use_gcc_seh()
personality void (...)* @__gcc_personality_seh0 {
entry:
call void @throwit()
unreachable
}
; CHECK-LABEL: use_gcc_seh:
; CHECK: .seh_proc use_gcc_seh
; CHECK-NOT: .seh_handler __gcc_personality_seh0
; CHECK: callq throwit
; CHECK: .seh_handlerdata
; CHECK: .seh_endproc