58 if (
F.hasFnAttribute(
"safeseh"))
63 shouldEmitMoves = shouldEmitPersonality = shouldEmitLSDA =
false;
87 shouldEmitPersonality =
88 forceEmitPersonality || ((hasLandingPads || hasEHFunclets) &&
92 shouldEmitLSDA = shouldEmitPersonality &&
105 emitEHRegistrationOffsetLabel(FuncInfo, FLinkageName);
107 shouldEmitLSDA = hasEHFunclets;
108 shouldEmitPersonality =
false;
118 if (!shouldEmitPersonality && !shouldEmitMoves && !shouldEmitLSDA)
140 if (shouldEmitPersonality || shouldEmitLSDA) {
151 emitCSpecificHandlerTable(MF);
153 emitExceptHandlerTable(MF);
155 emitCXXFrameHandler3Table(MF);
157 emitCLRExceptionTable(MF);
180 return Ctx.getOrCreateSymbol(
"?" + HandlerPrefix +
"$" +
182 FuncLinkageName +
"@4HA");
187 CurrentFuncletEntry = &
MBB;
211 if (shouldEmitMoves || shouldEmitPersonality) {
212 CurrentFuncletTextSection =
Asm->
OutStreamer->getCurrentSectionOnly();
216 if (shouldEmitPersonality) {
238 if (!CurrentFuncletEntry)
242 if (shouldEmitMoves || shouldEmitPersonality) {
257 Twine(
"$cppxdata$", FuncLinkageName));
263 emitCSpecificHandlerTable(MF);
274 CurrentFuncletEntry =
nullptr;
292 const MCExpr *WinException::getLabelPlusOne(
const MCSymbol *Label) {
305 const MCExpr *WinException::getOffsetPlusOne(
const MCSymbol *OffsetOf,
312 int WinException::getFrameIndexOffset(
int FrameIndex,
338 const int NullState = -1;
340 struct InvokeStateChange {
362 class InvokeStateChangeIterator {
368 : EHInfo(EHInfo), MFI(MFI), MFE(MFE), MBBI(MBBI), BaseState(BaseState) {
369 LastStateChange.PreviousEndLabel =
nullptr;
370 LastStateChange.NewStartLabel =
nullptr;
371 LastStateChange.NewState = BaseState;
382 auto BlockBegin = Begin->begin();
383 auto BlockEnd = std::prev(End)->end();
385 InvokeStateChangeIterator(EHInfo, Begin, End, BlockBegin, BaseState),
386 InvokeStateChangeIterator(EHInfo, End, End, BlockEnd, BaseState));
390 bool operator==(
const InvokeStateChangeIterator &O)
const {
391 assert(BaseState == O.BaseState);
402 return CurrentEndLabel == O.CurrentEndLabel;
405 bool operator!=(
const InvokeStateChangeIterator &O)
const {
408 InvokeStateChange &
operator*() {
return LastStateChange; }
409 InvokeStateChange *operator->() {
return &LastStateChange; }
410 InvokeStateChangeIterator &operator++() {
return scan(); }
413 InvokeStateChangeIterator &
scan();
416 const MCSymbol *CurrentEndLabel =
nullptr;
420 InvokeStateChange LastStateChange;
421 bool VisitingInvoke =
false;
428 bool IsNewBlock =
false;
429 for (; MFI != MFE; ++MFI, IsNewBlock =
true) {
432 for (
auto MBBE = MFI->end(); MBBI != MBBE; ++MBBI) {
434 if (!VisitingInvoke && LastStateChange.NewState != BaseState &&
439 LastStateChange.PreviousEndLabel = CurrentEndLabel;
440 LastStateChange.NewStartLabel =
nullptr;
441 LastStateChange.NewState = BaseState;
442 CurrentEndLabel =
nullptr;
452 if (Label == CurrentEndLabel) {
453 VisitingInvoke =
false;
460 auto &StateAndEnd = InvokeMapIter->second;
461 int NewState = StateAndEnd.first;
464 VisitingInvoke =
true;
465 if (NewState == LastStateChange.NewState) {
468 CurrentEndLabel = StateAndEnd.second;
472 LastStateChange.PreviousEndLabel = CurrentEndLabel;
473 LastStateChange.NewStartLabel = Label;
474 LastStateChange.NewState = NewState;
476 CurrentEndLabel = StateAndEnd.second;
483 if (LastStateChange.NewState != BaseState) {
485 LastStateChange.PreviousEndLabel = CurrentEndLabel;
486 LastStateChange.NewStartLabel =
nullptr;
487 LastStateChange.NewState = BaseState;
489 assert(CurrentEndLabel !=
nullptr);
493 CurrentEndLabel =
nullptr;
525 void WinException::emitCSpecificHandlerTable(
const MachineFunction *MF) {
530 bool VerboseAsm = OS.isVerboseAsm();
531 auto AddComment = [&](
const Twine &Comment) {
533 OS.AddComment(Comment);
552 const MCExpr *LabelDiff = getOffset(TableEnd, TableBegin);
555 AddComment(
"Number of call sites");
556 OS.EmitValue(EntryCount, 4);
558 OS.EmitLabel(TableBegin);
567 const MCSymbol *LastStartLabel =
nullptr;
568 int LastEHState = -1;
573 while (Stop != End && !Stop->isEHFuncletEntry())
575 for (
const auto &StateChange :
576 InvokeStateChangeIterator::range(FuncInfo, MF->
begin(), Stop)) {
579 if (LastEHState != -1)
580 emitSEHActionsForRange(FuncInfo, LastStartLabel,
581 StateChange.PreviousEndLabel, LastEHState);
582 LastStartLabel = StateChange.NewStartLabel;
583 LastEHState = StateChange.NewState;
586 OS.EmitLabel(TableEnd);
589 void WinException::emitSEHActionsForRange(
const WinEHFuncInfo &FuncInfo,
591 const MCSymbol *EndLabel,
int State) {
595 bool VerboseAsm = OS.isVerboseAsm();
596 auto AddComment = [&](
const Twine &Comment) {
598 OS.AddComment(Comment);
601 assert(BeginLabel && EndLabel);
602 while (State != -1) {
604 const MCExpr *FilterOrFinally;
605 const MCExpr *ExceptOrNull;
613 FilterOrFinally = UME.
Filter ? create32bitRef(UME.
Filter)
615 ExceptOrNull = create32bitRef(Handler->getSymbol());
618 AddComment(
"LabelStart");
619 OS.EmitValue(getLabelPlusOne(BeginLabel), 4);
620 AddComment(
"LabelEnd");
621 OS.EmitValue(getLabelPlusOne(EndLabel), 4);
622 AddComment(UME.
IsFinally ?
"FinallyFunclet" : UME.
Filter ?
"FilterFunction"
624 OS.EmitValue(FilterOrFinally, 4);
625 AddComment(UME.
IsFinally ?
"Null" :
"ExceptionHandler");
626 OS.EmitValue(ExceptOrNull, 4);
633 void WinException::emitCXXFrameHandler3Table(
const MachineFunction *MF) {
642 if (shouldEmitPersonality) {
647 computeIP2StateTable(MF, FuncInfo, IPToStateTable);
652 int UnwindHelpOffset = 0;
658 MCSymbol *TryBlockMapXData =
nullptr;
662 Twine(
"$stateUnwindMap$", FuncLinkageName));
666 if (!IPToStateTable.empty())
670 bool VerboseAsm = OS.isVerboseAsm();
671 auto AddComment = [&](
const Twine &Comment) {
673 OS.AddComment(Comment);
691 OS.EmitValueToAlignment(4);
692 OS.EmitLabel(FuncInfoXData);
694 AddComment(
"MagicNumber");
695 OS.EmitIntValue(0x19930522, 4);
697 AddComment(
"MaxState");
700 AddComment(
"UnwindMap");
701 OS.EmitValue(create32bitRef(UnwindMapXData), 4);
703 AddComment(
"NumTryBlocks");
706 AddComment(
"TryBlockMap");
707 OS.EmitValue(create32bitRef(TryBlockMapXData), 4);
709 AddComment(
"IPMapEntries");
710 OS.EmitIntValue(IPToStateTable.size(), 4);
712 AddComment(
"IPToStateXData");
713 OS.EmitValue(create32bitRef(IPToStateXData), 4);
716 AddComment(
"UnwindHelp");
717 OS.EmitIntValue(UnwindHelpOffset, 4);
720 AddComment(
"ESTypeList");
721 OS.EmitIntValue(0, 4);
723 AddComment(
"EHFlags");
724 OS.EmitIntValue(1, 4);
730 if (UnwindMapXData) {
731 OS.EmitLabel(UnwindMapXData);
735 AddComment(
"ToState");
736 OS.EmitIntValue(UME.
ToState, 4);
738 AddComment(
"Action");
739 OS.EmitValue(create32bitRef(CleanupSym), 4);
750 if (TryBlockMapXData) {
751 OS.EmitLabel(TryBlockMapXData);
756 MCSymbol *HandlerMapXData =
nullptr;
762 .
concat(FuncLinkageName));
770 "bad trymap interval");
772 AddComment(
"TryLow");
773 OS.EmitIntValue(TBME.
TryLow, 4);
775 AddComment(
"TryHigh");
776 OS.EmitIntValue(TBME.
TryHigh, 4);
778 AddComment(
"CatchHigh");
781 AddComment(
"NumCatches");
784 AddComment(
"HandlerArray");
785 OS.EmitValue(create32bitRef(HandlerMapXData), 4);
789 unsigned ParentFrameOffset = 0;
790 if (shouldEmitPersonality) {
797 MCSymbol *HandlerMapXData = HandlerMaps[
I];
798 if (!HandlerMapXData)
807 OS.EmitLabel(HandlerMapXData);
812 const MCExpr *FrameAllocOffsetRef =
nullptr;
815 assert(Offset != 0 &&
"Illegal offset for catch object!");
824 AddComment(
"Adjectives");
830 AddComment(
"CatchObjOffset");
831 OS.EmitValue(FrameAllocOffsetRef, 4);
833 AddComment(
"Handler");
834 OS.EmitValue(create32bitRef(HandlerSym), 4);
836 if (shouldEmitPersonality) {
837 AddComment(
"ParentFrameOffset");
838 OS.EmitIntValue(ParentFrameOffset, 4);
848 if (IPToStateXData) {
849 OS.EmitLabel(IPToStateXData);
850 for (
auto &IPStatePair : IPToStateTable) {
852 OS.EmitValue(IPStatePair.first, 4);
853 AddComment(
"ToState");
854 OS.EmitIntValue(IPStatePair.second, 4);
859 void WinException::computeIP2StateTable(
864 FuncletEnd = MF->
begin(),
866 FuncletStart !=
End; FuncletStart = FuncletEnd) {
868 while (++FuncletEnd != End) {
869 if (FuncletEnd->isEHFuncletEntry()) {
877 if (FuncletStart->isCleanupFuncletEntry())
882 if (FuncletStart == MF->
begin()) {
883 BaseState = NullState;
887 cast<FuncletPadInst>(FuncletStart->getBasicBlock()->getFirstNonPHI());
892 assert(StartLabel &&
"need local function start label");
893 IPToStateTable.push_back(
894 std::make_pair(create32bitRef(StartLabel), BaseState));
896 for (
const auto &StateChange : InvokeStateChangeIterator::range(
897 FuncInfo, FuncletStart, FuncletEnd, BaseState)) {
902 const MCSymbol *ChangeLabel = StateChange.NewStartLabel;
904 ChangeLabel = StateChange.PreviousEndLabel;
906 IPToStateTable.push_back(
907 std::make_pair(getLabelPlusOne(ChangeLabel), StateChange.NewState));
913 void WinException::emitEHRegistrationOffsetLabel(
const WinEHFuncInfo &FuncInfo,
948 auto AddComment = [&](
const Twine &Comment) {
954 emitEHRegistrationOffsetLabel(FuncInfo, FLinkageName);
965 if (PerName ==
"_except_handler4") {
988 int GSCookieOffset = -2;
999 int EHCookieOffset = 9999;
1007 AddComment(
"GSCookieOffset");
1009 AddComment(
"GSCookieXOROffset");
1011 AddComment(
"EHCookieOffset");
1013 AddComment(
"EHCookieXOROffset");
1026 AddComment(
"ToState");
1028 AddComment(UME.
IsFinally ?
"Null" :
"FilterFunction");
1030 AddComment(UME.
IsFinally ?
"FinallyFunclet" :
"ExceptionHandler");
1031 OS.
EmitValue(create32bitRef(ExceptOrFinally), 4);
1037 while (State != -1) {
1048 while (LeftRank < RightRank) {
1053 while (RightRank < LeftRank) {
1058 while (Left != Right) {
1087 assert(NumStates > 0 &&
"Don't need exception table!");
1089 for (
int State = 0; State < NumStates; ++State) {
1092 HandlerStates[HandlerBlock] = State;
1097 "ill-formed state numbering");
1100 HandlerStates[&MF->
front()] = NullState;
1125 std::unique_ptr<MCSymbol *[]> EndSymbolMap(
new MCSymbol *[NumStates]);
1130 FuncletEnd = MF->
begin(),
1132 FuncletStart !=
End; FuncletStart = FuncletEnd) {
1133 int FuncletState = HandlerStates[&*FuncletStart];
1136 while (++FuncletEnd != End) {
1137 if (FuncletEnd->isEHFuncletEntry()) {
1144 OS.
EmitValue(getOffset(EndSymbol, FuncBeginSym), 4);
1145 if (FuncletState != NullState) {
1147 EndSymbolMap[FuncletState] = EndSymbol;
1152 const MCSymbol *CurrentStartLabel =
nullptr;
1153 int CurrentState = NullState;
1155 for (
const auto &StateChange :
1156 InvokeStateChangeIterator::range(FuncInfo, FuncletStart, FuncletEnd)) {
1158 int StillPendingState =
1160 while (CurrentState != StillPendingState) {
1161 assert(CurrentState != NullState &&
1162 "Failed to find still-pending state!");
1164 Clauses.
push_back({CurrentStartLabel, StateChange.PreviousEndLabel,
1165 CurrentState, FuncletState});
1167 CurrentState = FuncInfo.
ClrEHUnwindMap[CurrentState].TryParentState;
1170 if (HandlerStack.
back().second == CurrentState)
1174 if (StateChange.NewState != CurrentState) {
1178 for (
int EnteredState = StateChange.NewState;
1179 EnteredState != CurrentState;
1182 int &MinEnclosingState = MinClauseMap[EnteredState];
1183 if (FuncletState < MinEnclosingState)
1184 MinEnclosingState = FuncletState;
1188 HandlerStack.
emplace_back(CurrentStartLabel, CurrentState);
1189 CurrentStartLabel = StateChange.NewStartLabel;
1190 CurrentState = StateChange.NewState;
1198 for (ClrClause &Clause : Clauses) {
1247 const MCExpr *ClauseBegin =
1248 getOffsetPlusOne(Clause.StartLabel, FuncBeginSym);
1249 const MCExpr *ClauseEnd = getOffsetPlusOne(Clause.EndLabel, FuncBeginSym);
1254 const MCExpr *HandlerBegin = getOffset(BeginSym, FuncBeginSym);
1255 MCSymbol *EndSym = EndSymbolMap[Clause.State];
1256 const MCExpr *HandlerEnd = getOffset(EndSym, FuncBeginSym);
1273 if (Clause.EnclosingState != MinClauseMap[Clause.State]) {
1276 assert(Clause.EnclosingState > MinClauseMap[Clause.State]);
Instances of this class represent a uniqued identifier for a section in the current translation unit...
void push_back(const T &Elt)
const MachineFunction * getParent() const
Return the MachineFunction containing this basic block.
unsigned getAlignment() const
getAlignment - Return the alignment (log2, not bytes) of the function.
SmallVector< WinEHHandlerType, 1 > HandlerArray
DenseMap< MCSymbol *, std::pair< int, MCSymbol * > > LabelToStateMap
std::unique_ptr< MCStreamer > OutStreamer
This is the MCStreamer object for the file we are generating.
static int getTryAncestor(const WinEHFuncInfo &FuncInfo, int Left, int Right)
static const MCSymbolRefExpr * create(const MCSymbol *Symbol, MCContext &Ctx)
MCSymbol * getSymbol(const GlobalValue *GV) const
static MCSymbol * getMCSymbolForMBB(AsmPrinter *Asm, const MachineBasicBlock *MBB)
Retrieve the MCSymbol for a GlobalValue or MachineBasicBlock.
MCSymbol - Instances of this class represent a symbol name in the MC file, and MCSymbols are created ...
int getNumber() const
MachineBasicBlocks are uniquely numbered at the function level, unless they're not in a MachineFuncti...
A Module instance is used to store all the information related to an LLVM module. ...
const DataLayout & getDataLayout() const
Return information about data layout.
SmallVector< SEHUnwindMapEntry, 4 > SEHUnwindMap
MCContext & OutContext
This is the context for the output file that we are streaming.
T dyn_cast() const
Returns the current pointer if it is of the specified pointer type, otherwises returns null...
void beginFunclet(const MachineBasicBlock &MBB, MCSymbol *Sym) override
Emit target-specific EH funclet machinery.
DenseMap< const FuncletPadInst *, int > FuncletBaseStateMap
static bool callToNoUnwindFunction(const MachineInstr *MI)
Return `true' if this is a call to a function marked `nounwind'.
const MachineFunction * MF
The current machine function.
bool isCleanupFuncletEntry() const
Returns true if this is the entry block of a cleanup funclet.
const std::vector< LandingPadInfo > & getLandingPads() const
Return a reference to the landing pad info for the current function.
MCSymbol * getOrCreateParentFrameOffsetSymbol(StringRef FuncName)
const Function * getFunction() const
getFunction - Return the LLVM function that this machine code represents
bool hasStackProtectorIndex() const
StringRef getName() const
Return a constant reference to the value's name.
MachineModuleInfo * MMI
Collected machine module information.
MBBOrBasicBlock Handler
Holds the __except or __finally basic block.
void endModule() override
Emit all exception information that should come after the content.
Emits exception handling directives.
const TargetSubtargetInfo & getSubtarget() const
getSubtarget - Return the subtarget for which this machine code is being compiled.
struct fuzzer::@269 Flags
Twine - A lightweight data structure for efficiently representing the concatenation of temporary valu...
static const MCBinaryExpr * createDiv(const MCExpr *LHS, const MCExpr *RHS, MCContext &Ctx)
This class consists of common code factored out of the SmallVector class to reduce code duplication b...
Base class for the full range of assembler expressions which are needed for parsing.
virtual unsigned getWinEHParentFrameOffset(const MachineFunction &MF) const
const Module * getModule() const
Constant * getPersonalityFn() const
Get the personality function associated with this function.
The MachineFrameInfo class represents an abstract stack frame until prolog/epilog code is inserted...
virtual bool isVerboseAsm() const
Return true if this streamer supports verbose assembly and if it is enabled.
LLVM_NODISCARD bool empty() const
int ToState
If unwinding continues through this handler, transition to the handler at this state.
Context object for machine code objects.
virtual void AddComment(const Twine &T, bool EOL=true)
Add a textual comment.
const MachineBasicBlock & front() const
void emitExceptionTable()
Emit landing pads and actions.
static const MCBinaryExpr * createSub(const MCExpr *LHS, const MCExpr *RHS, MCContext &Ctx)
virtual int getFrameIndexReferencePreferSP(const MachineFunction &MF, int FI, unsigned &FrameReg, bool IgnoreSPUpdates) const
Same as getFrameIndexReference, except that the stack pointer (as opposed to the frame pointer) will ...
static const MCBinaryExpr * createAdd(const MCExpr *LHS, const MCExpr *RHS, MCContext &Ctx)
void endFunclet() override
virtual void EmitIntValue(uint64_t Value, unsigned Size)
Special case of EmitValue that avoids the client having to pass in a MCExpr for constant integers...
virtual int getFrameIndexReference(const MachineFunction &MF, int FI, unsigned &FrameReg) const
getFrameIndexReference - This method should return the base register and offset used to reference a f...
Expected< const typename ELFT::Sym * > getSymbol(typename ELFT::SymRange Symbols, uint32_t Index)
void EmitValue(const MCExpr *Value, unsigned Size, SMLoc Loc=SMLoc())
static GCRegistry::Add< CoreCLRGC > E("coreclr","CoreCLR-compatible GC")
Similar to CxxUnwindMapEntry, but supports SEH filters.
SmallVector< ClrEHUnwindMapEntry, 4 > ClrEHUnwindMap
Streaming machine code generation interface.
MCSymbol * createTempSymbol(bool CanBeUnnamed=true)
Create and return a new assembler temporary symbol with a unique but unspecified name.
Constant * stripPointerCasts()
MCSymbol * CurrentFnSym
The symbol for the current function.
const MCAsmInfo * MAI
Target Asm Printer information.
MachineFrameInfo & getFrameInfo()
getFrameInfo - Return the frame info object for the current function.
const MachineOperand & getOperand(unsigned i) const
Type is formed as (base + (derived << SCT_COMPLEX_TYPE_SHIFT))
WinException(AsmPrinter *A)
TargetMachine & TM
Target machine description.
bool hasPersonalityFn() const
Check whether this function has a personality function.
This class is intended to be used as a driving class for all asm writers.
void endFunction(const MachineFunction *) override
Gather and emit post-function exception information.
EHPersonality classifyEHPersonality(const Value *Pers)
See if the given exception handling personality function is one that we understand.
virtual void EmitValueToAlignment(unsigned ByteAlignment, int64_t Value=0, unsigned ValueSize=1, unsigned MaxBytesToEmit=0)
Emit some number of copies of Value until the byte alignment ByteAlignment is reached.
bool isEHFuncletEntry() const
Returns true if this is the entry block of an EH funclet.
static const unsigned End
A function that returns a base type.
unsigned getStackPointerRegisterToSaveRestore() const
If a physical register, this specifies the register that llvm.savestack/llvm.restorestack should save...
BlockMass operator*(BlockMass L, BranchProbability R)
detail::concat_range< ValueT, RangeTs...> concat(RangeTs &&...Ranges)
Concatenated range across two or more ranges.
AsmPrinter * Asm
Target of directive emission.
void beginFunction(const MachineFunction *MF) override
Gather pre-function exception information.
void EmitAlignment(unsigned NumBits, const GlobalObject *GO=nullptr) const
Emit an alignment directive to the specified power of two boundary.
iterator_range< T > make_range(T x, T y)
Convenience function for iterating over sub-ranges.
virtual const TargetFrameLowering * getFrameLowering() const
SmallVector< CxxUnwindMapEntry, 4 > CxxUnwindMap
const Function * Filter
Holds the filter expression function.
Iterator for intrusive lists based on ilist_node.
virtual void EmitLabel(MCSymbol *Symbol)
Emit a label for Symbol into the current section.
unsigned getLSDAEncoding() const
MCSymbol * getOrCreateLSDASymbol(StringRef FuncName)
bool isFuncletEHPersonality(EHPersonality Pers)
Returns true if this is a personality function that invokes handler funclets (which must return to it...
T get() const
Returns the value of the specified pointer type.
This is a 'vector' (really, a variable-sized array), optimized for the case when the array is small...
Module.h This file contains the declarations for the Module class.
virtual const TargetLowering * getTargetLowering() const
Information about stack frame layout on the target.
LLVM_NODISCARD T pop_back_val()
bool needsUnwindTableEntry() const
True if this function needs an unwind table.
unsigned getPersonalityEncoding() const
SmallVector< WinEHTryBlockMapEntry, 4 > TryBlockMap
A range adaptor for a pair of iterators.
bool hasEHFunclets() const
GlobalVariable * TypeDescriptor
int getStackProtectorIndex() const
Return the index for the stack protector object.
bool operator!=(uint64_t V1, const APInt &V2)
Representation of each machine instruction.
static StringRef getRealLinkageName(StringRef Name)
If special LLVM prefix that is used to inform the asm printer to not emit usual symbol prefix before ...
void emplace_back(ArgTypes &&...Args)
MCSymbol * getOrCreateSymbol(const Twine &Name)
Lookup the symbol inside with the specified Name.
MCSymbol * getFunctionBegin() const
bool isCall(QueryType Type=AnyInBundle) const
LLVM_ATTRIBUTE_ALWAYS_INLINE size_type size() const
unsigned getPointerSizeInBits(unsigned AS=0) const
Layout pointer size, in bits FIXME: The defaults need to be removed once all of the backends/clients ...
MCSymbol * getMCSymbol() const
MCSymbol * getFunctionEnd() const
LLVM_NODISCARD std::enable_if<!is_simple_type< Y >::value, typename cast_retty< X, const Y >::ret_type >::type dyn_cast(const Y &Val)
const WinEHFuncInfo * getWinEHFuncInfo() const
getWinEHFuncInfo - Return information about how the current function uses Windows exception handling...
union llvm::WinEHHandlerType::@61 CatchObj
The CatchObj starts out life as an LLVM alloca and is eventually turned frame index.
ClrHandlerType HandlerType
static int getTryRank(const WinEHFuncInfo &FuncInfo, int State)
virtual MCSymbol * getCFIPersonalitySymbol(const GlobalValue *GV, const TargetMachine &TM, MachineModuleInfo *MMI) const
const TargetLoweringObjectFile & getObjFileLowering() const
Return information about object file lowering.
assert(ImpDefSCC.getReg()==AMDGPU::SCC &&ImpDefSCC.isDef())
LLVM Value Representation.
StringRef - Represent a constant reference to a string, i.e.
bool operator==(uint64_t V1, const APInt &V2)
static GCRegistry::Add< ErlangGC > A("erlang","erlang-compatible garbage collector")
bool isNoOpWithoutInvoke(EHPersonality Pers)
Return true if this personality may be safely removed if there are no invoke instructions remaining i...
static const MCConstantExpr * create(int64_t Value, MCContext &Ctx)
static Expected< BitVector > scan(StringRef &S, StringRef Original)
This file describes how to lower LLVM code to machine code.
unsigned getAlignment() const
Return alignment of the basic block.
void tidyLandingPads(DenseMap< MCSymbol *, uintptr_t > *LPMap=nullptr)
Remap landing pad labels and remove any deleted landing pads.
bool usesWindowsCFI() const