llvm-project/llvm/test/CodeGen/WinEH/wineh-comdat.ll
Anshul Nigham ac85248f11
[NewPM] Port x86-winehstate (#180687)
x86-winehstate has been converted to a module pass for NewPM since it
uses data from the Module by overriding `doInitialization` and
`doFinalization`.
2026-02-10 18:50:34 -08:00

19 lines
573 B
LLVM

; RUN: opt -mtriple=i686-unknown-windows-msvc -S -x86-winehstate < %s | FileCheck %s
; RUN: opt -mtriple=i686-unknown-windows-msvc -S -passes=x86-winehstate < %s | FileCheck %s
$f = comdat any
define void @f() comdat personality ptr @__CxxFrameHandler3 {
invoke void @g() to label %return unwind label %unwind
return:
ret void
unwind:
%pad = cleanuppad within none []
cleanupret from %pad unwind to caller
}
declare void @g()
declare i32 @__CxxFrameHandler3(...)
; CHECK: define internal i32 @"__ehhandler$f"(ptr %0, ptr %1, ptr %2, ptr %3){{ .+}} comdat($f) {