LLVM
8.0.1
|
#include "CodeGen/AsmPrinter/DwarfException.h"
Public Member Functions | |
DwarfCFIException (AsmPrinter *A) | |
~DwarfCFIException () override | |
void | endModule () override |
Emit all exception information that should come after the content. More... | |
void | beginFunction (const MachineFunction *MF) override |
Gather pre-function exception information. More... | |
void | endFunction (const MachineFunction *) override |
Gather and emit post-function exception information. More... | |
void | beginFragment (const MachineBasicBlock *MBB, ExceptionSymbolProvider ESP) override |
Public Member Functions inherited from llvm::EHStreamer | |
EHStreamer (AsmPrinter *A) | |
~EHStreamer () override | |
void | setSymbolSize (const MCSymbol *Sym, uint64_t Size) override |
For symbols that have a size designated (e.g. More... | |
void | beginInstruction (const MachineInstr *MI) override |
Process beginning of an instruction. More... | |
void | endInstruction () override |
Process end of an instruction. More... | |
Public Member Functions inherited from llvm::AsmPrinterHandler | |
virtual | ~AsmPrinterHandler () |
Pin vtable to this file. More... | |
virtual void | beginFunclet (const MachineBasicBlock &MBB, MCSymbol *Sym=nullptr) |
Emit target-specific EH funclet machinery. More... | |
virtual void | endFunclet () |
Additional Inherited Members | |
Static Public Member Functions inherited from llvm::EHStreamer | |
static bool | callToNoUnwindFunction (const MachineInstr *MI) |
Return `true' if this is a call to a function marked `nounwind'. More... | |
Protected Types inherited from llvm::EHStreamer | |
using | RangeMapType = DenseMap< MCSymbol *, PadRange > |
Protected Member Functions inherited from llvm::DwarfCFIExceptionBase | |
DwarfCFIExceptionBase (AsmPrinter *A) | |
void | markFunctionEnd () override |
void | endFragment () override |
Protected Member Functions inherited from llvm::EHStreamer | |
void | computeActionsTable (const SmallVectorImpl< const LandingPadInfo *> &LandingPads, SmallVectorImpl< ActionEntry > &Actions, SmallVectorImpl< unsigned > &FirstActions) |
Compute the actions table and gather the first action index for each landing pad site. More... | |
void | computePadMap (const SmallVectorImpl< const LandingPadInfo *> &LandingPads, RangeMapType &PadMap) |
virtual void | computeCallSiteTable (SmallVectorImpl< CallSiteEntry > &CallSites, const SmallVectorImpl< const LandingPadInfo *> &LandingPads, const SmallVectorImpl< unsigned > &FirstActions) |
Compute the call-site table. More... | |
MCSymbol * | emitExceptionTable () |
Emit landing pads and actions. More... | |
virtual void | emitTypeInfos (unsigned TTypeEncoding, MCSymbol *TTBaseLabel) |
Static Protected Member Functions inherited from llvm::EHStreamer | |
static unsigned | sharedTypeIDs (const LandingPadInfo *L, const LandingPadInfo *R) |
How many leading type ids two landing pads have in common. More... | |
static bool | isFilterEHSelector (int Selector) |
static bool | isCleanupEHSelector (int Selector) |
static bool | isCatchEHSelector (int Selector) |
Protected Attributes inherited from llvm::DwarfCFIExceptionBase | |
bool | shouldEmitCFI |
Per-function flag to indicate if frame CFI info should be emitted. More... | |
bool | hasEmittedCFISections |
Per-module flag to indicate if .cfi_section has beeen emitted. More... | |
Protected Attributes inherited from llvm::EHStreamer | |
AsmPrinter * | Asm |
Target of directive emission. More... | |
MachineModuleInfo * | MMI |
Collected machine module information. More... | |
Definition at line 38 of file DwarfException.h.
DwarfCFIException::DwarfCFIException | ( | AsmPrinter * | A | ) |
Definition at line 54 of file DwarfCFIException.cpp.
|
override |
Definition at line 59 of file DwarfCFIException.cpp.
|
overridevirtual |
Reimplemented from llvm::AsmPrinterHandler.
Definition at line 129 of file DwarfCFIException.cpp.
References llvm::MachineModuleInfo::addPersonality(), llvm::EHStreamer::Asm, assert(), llvm::dyn_cast(), llvm::N86::ESP, F(), llvm::TargetLoweringObjectFile::getCFIPersonalitySymbol(), llvm::MachineFunction::getFunction(), llvm::TargetLoweringObjectFile::getLSDAEncoding(), llvm::AsmPrinter::getObjFileLowering(), llvm::MachineBasicBlock::getParent(), llvm::TargetLoweringObjectFile::getPersonalityEncoding(), llvm::DwarfCFIExceptionBase::hasEmittedCFISections, llvm::EHStreamer::MMI, llvm::AsmPrinter::needsOnlyDebugCFIMoves(), llvm::AsmPrinter::OutStreamer, P, llvm::DwarfCFIExceptionBase::shouldEmitCFI, and llvm::AsmPrinter::TM.
Referenced by beginFunction().
|
overridevirtual |
Gather pre-function exception information.
Assumes being emitted immediately after the function entry point.
Implements llvm::AsmPrinterHandler.
Definition at line 88 of file DwarfCFIException.cpp.
References llvm::EHStreamer::Asm, llvm::MachineFunction::begin(), beginFragment(), llvm::AsmPrinter::CFI_M_None, llvm::classifyEHPersonality(), llvm::dwarf::DW_EH_PE_omit, F(), llvm::MCContext::getAsmInfo(), llvm::MachineModuleInfo::getContext(), getExceptionSym(), llvm::MachineFunction::getFunction(), llvm::MachineFunction::getLandingPads(), llvm::TargetLoweringObjectFile::getLSDAEncoding(), llvm::MachineFunction::getMMI(), llvm::AsmPrinter::getObjFileLowering(), llvm::TargetLoweringObjectFile::getPersonalityEncoding(), llvm::Function::getPersonalityFn(), llvm::Function::hasPersonalityFn(), llvm::isNoOpWithoutInvoke(), llvm::AsmPrinter::needsCFIMoves(), llvm::Function::needsUnwindTableEntry(), llvm::DwarfCFIExceptionBase::shouldEmitCFI, llvm::Constant::stripPointerCasts(), and llvm::MCAsmInfo::usesCFIForEH().
|
overridevirtual |
Gather and emit post-function exception information.
endFunction - Gather and emit post-function exception information.
Implements llvm::AsmPrinterHandler.
Definition at line 167 of file DwarfCFIException.cpp.
References llvm::EHStreamer::emitExceptionTable().
|
overridevirtual |
Emit all exception information that should come after the content.
endModule - Emit all exception information that should come after the content.
Implements llvm::AsmPrinterHandler.
Definition at line 63 of file DwarfCFIException.cpp.
References llvm::EHStreamer::Asm, llvm::dwarf::DW_EH_PE_indirect, llvm::TargetLoweringObjectFile::emitPersonalityValue(), llvm::AsmPrinter::getDataLayout(), llvm::AsmPrinter::getObjFileLowering(), llvm::MachineModuleInfo::getPersonalities(), llvm::TargetLoweringObjectFile::getPersonalityEncoding(), llvm::AsmPrinter::getSymbol(), llvm::AsmPrinter::MAI, llvm::EHStreamer::MMI, llvm::AsmPrinter::OutStreamer, and llvm::MCAsmInfo::usesCFIForEH().