class WinException

Declaration

class WinException : public EHStreamer { /* full declaration omitted */ };

Description

Emits exception handling directives.

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:26

Inherits from: EHStreamer

Member Variables

private bool shouldEmitPersonality = false
Per-function flag to indicate if personality info should be emitted.
private bool shouldEmitLSDA = false
Per-function flag to indicate if the LSDA should be emitted.
private bool shouldEmitMoves = false
Per-function flag to indicate if frame moves info should be emitted.
private bool useImageRel32 = false
True if this is a 64-bit target and we should use image relative offsets.
private bool isAArch64 = false
True if we are generating exception handling on Windows for ARM64.
private bool isThumb = false
True if we are generating exception handling on Windows for ARM (Thumb).
private const llvm::MachineBasicBlock* CurrentFuncletEntry = nullptr
Pointer to the current funclet entry BB.
private llvm::MCSection* CurrentFuncletTextSection = nullptr
The section of the last funclet start.
private std::vector<const MCSymbol*> EHContTargets
The list of symbols to add to the ehcont section

Inherited from EHStreamer:

protected Asm
protected MMI

Method Overview

Inherited from EHStreamer:

Inherited from AsmPrinterHandler:

Methods

WinException(llvm::AsmPrinter* A)

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:99

Parameters

llvm::AsmPrinter* A

void beginFunclet(
    const llvm::MachineBasicBlock& MBB,
    llvm::MCSymbol* Sym)

Description

Emit target-specific EH funclet machinery.

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:115

Parameters

const llvm::MachineBasicBlock& MBB
llvm::MCSymbol* Sym

void beginFunction(
    const llvm::MachineFunction* MF)

Description

Gather pre-function exception information. Assumes being emitted immediately after the function entry point.

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:107

Parameters

const llvm::MachineFunction* MF

void computeIP2StateTable(
    const llvm::MachineFunction* MF,
    const llvm::WinEHFuncInfo& FuncInfo,
    SmallVectorImpl<
        std::pair<const MCExpr*, int>>&
        IPToStateTable)

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:71

Parameters

const llvm::MachineFunction* MF
const llvm::WinEHFuncInfo& FuncInfo
SmallVectorImpl<std::pair<const MCExpr*, int>>& IPToStateTable

const llvm::MCExpr* create32bitRef(
    const llvm::MCSymbol* Value)

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:80

Parameters

const llvm::MCSymbol* Value

const llvm::MCExpr* create32bitRef(
    const llvm::GlobalValue* GV)

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:81

Parameters

const llvm::GlobalValue* GV

void emitCLRExceptionTable(
    const llvm::MachineFunction* MF)

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:69

Parameters

const llvm::MachineFunction* MF

void emitCSpecificHandlerTable(
    const llvm::MachineFunction* MF)

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:54

Parameters

const llvm::MachineFunction* MF

void emitCXXFrameHandler3Table(
    const llvm::MachineFunction* MF)

Description

Emit the EH table data for 32-bit and 64-bit functions using the __CxxFrameHandler3 personality.

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:62

Parameters

const llvm::MachineFunction* MF

void emitEHRegistrationOffsetLabel(
    const llvm::WinEHFuncInfo& FuncInfo,
    llvm::StringRef FLinkageName)

Description

Emits the label used with llvm.eh.recoverfp, which is used by outlined funclets.

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:77

Parameters

const llvm::WinEHFuncInfo& FuncInfo
llvm::StringRef FLinkageName

void emitExceptHandlerTable(
    const llvm::MachineFunction* MF)

Description

Emit the EH table data for _except_handler3 and _except_handler4 personality functions. These are only used on 32-bit and do not use CFI tables.

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:67

Parameters

const llvm::MachineFunction* MF

void emitSEHActionsForRange(
    const llvm::WinEHFuncInfo& FuncInfo,
    const llvm::MCSymbol* BeginLabel,
    const llvm::MCSymbol* EndLabel,
    int State)

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:56

Parameters

const llvm::WinEHFuncInfo& FuncInfo
const llvm::MCSymbol* BeginLabel
const llvm::MCSymbol* EndLabel
int State

void endFunclet()

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:116

void endFuncletImpl()

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:94

void endFunction(const llvm::MachineFunction*)

Description

Gather and emit post-function exception information.

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:112

Parameters

const llvm::MachineFunction*

void endModule()

Description

Emit all exception information that should come after the content.

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:103

int getFrameIndexOffset(
    int FrameIndex,
    const llvm::WinEHFuncInfo& FuncInfo)

Description

Gets the offset that we should use in a table for a stack object with the given index. For targets using CFI (Win64, etc), this is relative to the established SP at the end of the prologue. For targets without CFI (Win32 only), it is relative to the frame pointer.

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:92

Parameters

int FrameIndex
const llvm::WinEHFuncInfo& FuncInfo

const llvm::MCExpr* getLabel(
    const llvm::MCSymbol* Label)

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:82

Parameters

const llvm::MCSymbol* Label

const llvm::MCExpr* getLabelPlusOne(
    const llvm::MCSymbol* Label)

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:83

Parameters

const llvm::MCSymbol* Label

const llvm::MCExpr* getOffset(
    const llvm::MCSymbol* OffsetOf,
    const llvm::MCSymbol* OffsetFrom)

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:84

Parameters

const llvm::MCSymbol* OffsetOf
const llvm::MCSymbol* OffsetFrom

const llvm::MCExpr* getOffsetPlusOne(
    const llvm::MCSymbol* OffsetOf,
    const llvm::MCSymbol* OffsetFrom)

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:85

Parameters

const llvm::MCSymbol* OffsetOf
const llvm::MCSymbol* OffsetFrom

void markFunctionEnd()

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:109

~WinException()

Description

Pin vtable to this file.

Declared at: llvm/lib/CodeGen/AsmPrinter/WinException.h:100