29 lines · plain
1; RUN: opt -S -x86-winehstate < %s | FileCheck %s --check-prefix=IR2; RUN: llc < %s | FileCheck %s --check-prefix=ASM3 4; IR-NOT: define.*__ehhandler5; IR: define available_externally void @foo(ptr %0)6; IR-NOT: define.*__ehhandler7 8; No code should be emitted.9; ASM-NOT: __ehtable10; ASM-NOT: __ehhandler11 12target datalayout = "e-m:x-p:32:32-i64:64-f80:32-n8:16:32-a:0:32-S32"13target triple = "i686-pc-windows-msvc"14 15declare i32 @__CxxFrameHandler3(...) unnamed_addr16 17define available_externally void @foo(ptr) personality ptr @__CxxFrameHandler3 {18start:19 invoke void %0()20 to label %good unwind label %bad21 22good: ; preds = %start23 ret void24 25bad: ; preds = %start26 %cleanuppad = cleanuppad within none []27 cleanupret from %cleanuppad unwind to caller28}29