LLVM: llvm::TargetLoweringObjectFileXCOFF Class Reference (original) (raw)

Public Member Functions

TargetLoweringObjectFileXCOFF ()=default

~TargetLoweringObjectFileXCOFF () override=default

void

Initialize (MCContext &Ctx, const TargetMachine &TM) override

This method must be called before any actual lowering is done.

bool

shouldPutJumpTableInFunctionSection (bool UsesLabelDifference, const Function &F) const override

MCSection *

getExplicitSectionGlobal (const GlobalObject *GO, SectionKind Kind, const TargetMachine &TM) const override

Targets should implement this method to assign a section to globals with an explicit section specfied.

MCSection *

getStaticCtorSection (unsigned Priority, const MCSymbol *KeySym) const override

MCSection *

getStaticDtorSection (unsigned Priority, const MCSymbol *KeySym) const override

MCSection *

SelectSectionForGlobal (const GlobalObject *GO, SectionKind Kind, const TargetMachine &TM) const override

MCSection *

getSectionForJumpTable (const Function &F, const TargetMachine &TM) const override

MCSection *

getSectionForConstant (const DataLayout &DL, SectionKind Kind, const Constant *C, Align &Alignment) const override

Given a constant with the SectionKind, return a section that it should be placed in.

MCSection *

getSectionForFunctionDescriptor (const Function *F, const TargetMachine &TM) const override

On targets that use separate function descriptor symbols, return a section for the descriptor given its symbol.

MCSection *

getSectionForTOCEntry (const MCSymbol *Sym, const TargetMachine &TM) const override

On targets that support TOC entries, return a section for the entry given the symbol it refers to.

MCSection *

getSectionForExternalReference (const GlobalObject *GO, const TargetMachine &TM) const override

For external functions, this will always return a function descriptor csect.

MCSymbol *

getTargetSymbol (const GlobalValue *GV, const TargetMachine &TM) const override

For functions, this will always return a function descriptor symbol.

MCSymbol *

getFunctionEntryPointSymbol (const GlobalValue *Func, const TargetMachine &TM) const override

If supported, return the function entry point symbol.

MCSection *

getSectionForLSDA (const Function &F, const MCSymbol &FnSym, const TargetMachine &TM) const override

For functions, this will return the LSDA section.

Public Member Functions inherited from llvm::TargetLoweringObjectFile

TargetLoweringObjectFile ()=default

TargetLoweringObjectFile (const TargetLoweringObjectFile &)=delete

TargetLoweringObjectFile &

operator= (const TargetLoweringObjectFile &)=delete

~TargetLoweringObjectFile () override

Mangler &

getMangler () const

virtual void

emitPersonalityValue (MCStreamer &Streamer, const DataLayout &TM, const MCSymbol *Sym, const MachineModuleInfo *MMI) const

virtual void

emitModuleMetadata (MCStreamer &Streamer, Module &M) const

Emit the module-level metadata that the platform cares about.

void

emitCGProfileMetadata (MCStreamer &Streamer, Module &M) const

Emit Call Graph Profile metadata.

void

emitPseudoProbeDescMetadata (MCStreamer &Streamer, Module &M, std::function< void(MCStreamer &Streamer)> COMDATSymEmitter=nullptr) const

Emit pseudo_probe_desc metadata.

virtual void

emitLinkerDirectives (MCStreamer &Streamer, Module &M) const

Process linker options metadata and emit platform-specific bits.

virtual void

getModuleMetadata (Module &M)

Get the module-level metadata that the platform cares about.

virtual MCSection *

getSectionForConstant (const DataLayout &DL, SectionKind Kind, const Constant *C, Align &Alignment, StringRef SectionSuffix) const

Similar to the function above, but append SectionSuffix to the section name.

virtual MCSection *

getSectionForMachineBasicBlock (const Function &F, const MachineBasicBlock &MBB, const TargetMachine &TM) const

virtual MCSection *

getUniqueSectionForFunction (const Function &F, const TargetMachine &TM) const

MCSection *

SectionForGlobal (const GlobalObject *GO, SectionKind Kind, const TargetMachine &TM) const

This method computes the appropriate section to emit the specified global variable or function definition.

MCSection *

SectionForGlobal (const GlobalObject *GO, const TargetMachine &TM) const

This method computes the appropriate section to emit the specified global variable or function definition.

virtual void

getNameWithPrefix (SmallVectorImpl< char > &OutName, const GlobalValue *GV, const TargetMachine &TM) const

virtual MCSection *

getSectionForJumpTable (const Function &F, const TargetMachine &TM, const MachineJumpTableEntry *JTE) const

virtual const MCExpr *

getTTypeGlobalReference (const GlobalValue *GV, unsigned Encoding, const TargetMachine &TM, MachineModuleInfo *MMI, MCStreamer &Streamer) const

Return an MCExpr to use for a reference to the specified global variable from exception handling information.

MCSymbol *

getSymbolWithGlobalValueBase (const GlobalValue *GV, StringRef Suffix, const TargetMachine &TM) const

Return the MCSymbol for a private symbol with global value name as its base, with the specified suffix.

virtual MCSymbol *

getCFIPersonalitySymbol (const GlobalValue *GV, const TargetMachine &TM, MachineModuleInfo *MMI) const

unsigned

getPersonalityEncoding () const

unsigned

getLSDAEncoding () const

unsigned

getTTypeEncoding () const

unsigned

getCallSiteEncoding () const

const MCExpr *

getTTypeReference (const MCSymbolRefExpr *Sym, unsigned Encoding, MCStreamer &Streamer) const

virtual const MCExpr *

getDebugThreadLocalSymbol (const MCSymbol *Sym) const

Create a symbol reference to describe the given TLS variable when emitting the address in debug info.

virtual const MCExpr *

lowerRelativeReference (const GlobalValue *LHS, const GlobalValue *RHS, int64_t Addend, std::optional< int64_t > PCRelativeOffset, const TargetMachine &TM) const

bool

hasPLTPCRelative () const

Target supports a PC-relative relocation that references the PLT of a function.

virtual const MCExpr *

lowerDSOLocalEquivalent (const MCSymbol *LHS, const MCSymbol *RHS, int64_t Addend, std::optional< int64_t > PCRelativeOffset, const TargetMachine &TM) const

bool

supportIndirectSymViaGOTPCRel () const

Target supports replacing a data "PC"-relative access to a symbol through another symbol, by accessing the later via a GOT entry instead?

bool

supportGOTPCRelWithOffset () const

Target GOT "PC"-relative relocation supports encoding an additional binary expression with an offset?

bool

supportDebugThreadLocalLocation () const

Target supports TLS offset relocation in debug section?

virtual MCRegister

getStaticBase () const

Returns the register used as static base in RWPI variants.

virtual const MCExpr *

getIndirectSymViaRWPI (const MCSymbol *Sym) const

Get the target specific RWPI relocation.

virtual const MCExpr *

getIndirectSymViaGOTPCRel (const GlobalValue *GV, const MCSymbol *Sym, const MCValue &MV, int64_t Offset, MachineModuleInfo *MMI, MCStreamer &Streamer) const

Get the target specific PC relative GOT entry relocation.

virtual MCSection *

getSectionForCommandLines () const

If supported, return the section to use for the llvm.commandline metadata.

Public Member Functions inherited from llvm::MCObjectFileInfo

void

initMCObjectFileInfo (MCContext &MCCtx, bool PIC, bool LargeCodeModel=false)

virtual

~MCObjectFileInfo ()

MCContext &

getContext () const

bool

getSupportsCompactUnwindWithoutEHFrame () const

bool

getOmitDwarfIfHaveCompactUnwind () const

unsigned

getFDEEncoding () const

unsigned

getCompactUnwindDwarfEHFrameOnly () const

std::optional< sframe::ABI >

getSFrameABIArch () const

virtual unsigned

getTextSectionAlignment () const

MCSection *

getTextSection () const

MCSection *

getDataSection () const

MCSection *

getBSSSection () const

MCSection *

getReadOnlySection () const

MCSection *

getLSDASection () const

MCSection *

getImportCallSection () const

MCSection *

getCompactUnwindSection () const

MCSection *

getDwarfAbbrevSection () const

MCSection *

getDwarfInfoSection () const

MCSection *

getDwarfInfoSection (uint64_t Hash) const

MCSection *

getDwarfLineSection () const

MCSection *

getDwarfLineStrSection () const

MCSection *

getDwarfFrameSection () const

MCSection *

getDwarfPubNamesSection () const

MCSection *

getDwarfPubTypesSection () const

MCSection *

getDwarfGnuPubNamesSection () const

MCSection *

getDwarfGnuPubTypesSection () const

const MCSection *

getDwarfDebugInlineSection () const

MCSection *

getDwarfStrSection () const

MCSection *

getDwarfLocSection () const

MCSection *

getDwarfARangesSection () const

MCSection *

getDwarfRangesSection () const

MCSection *

getDwarfRnglistsSection () const

MCSection *

getDwarfLoclistsSection () const

MCSection *

getDwarfMacinfoSection () const

MCSection *

getDwarfMacroSection () const

MCSection *

getDwarfDebugNamesSection () const

MCSection *

getDwarfAccelNamesSection () const

MCSection *

getDwarfAccelObjCSection () const

MCSection *

getDwarfAccelNamespaceSection () const

MCSection *

getDwarfAccelTypesSection () const

MCSection *

getDwarfInfoDWOSection () const

MCSection *

getDwarfTypesSection (uint64_t Hash) const

MCSection *

getDwarfTypesDWOSection () const

MCSection *

getDwarfAbbrevDWOSection () const

MCSection *

getDwarfStrDWOSection () const

MCSection *

getDwarfLineDWOSection () const

MCSection *

getDwarfLocDWOSection () const

MCSection *

getDwarfStrOffDWOSection () const

MCSection *

getDwarfStrOffSection () const

MCSection *

getDwarfAddrSection () const

MCSection *

getDwarfRnglistsDWOSection () const

MCSection *

getDwarfLoclistsDWOSection () const

MCSection *

getDwarfMacroDWOSection () const

MCSection *

getDwarfMacinfoDWOSection () const

MCSection *

getDwarfCUIndexSection () const

MCSection *

getDwarfTUIndexSection () const

MCSection *

getDwarfSwiftASTSection () const

MCSection *

getCOFFDebugSymbolsSection () const

MCSection *

getCOFFDebugTypesSection () const

MCSection *

getCOFFGlobalTypeHashesSection () const

MCSection *

getTLSExtraDataSection () const

const MCSection *

getTLSDataSection () const

MCSection *

getTLSBSSSection () const

MCSection *

getStackMapSection () const

MCSection *

getFaultMapSection () const

MCSection *

getRemarksSection () const

MCSection *

getCallGraphSection (const MCSection &TextSec) const

MCSection *

getStackSizesSection (const MCSection &TextSec) const

MCSection *

getBBAddrMapSection (const MCSection &TextSec) const

MCSection *

getKCFITrapSection (const MCSection &TextSec) const

MCSection *

getPseudoProbeSection (const MCSection &TextSec) const

MCSection *

getPseudoProbeDescSection (StringRef FuncName) const

MCSection *

getLLVMStatsSection () const

MCSection *

getPCSection (StringRef Name, const MCSection *TextSec) const

MCSection *

getDataRelROSection () const

const MCSection *

getMergeableConst4Section () const

const MCSection *

getMergeableConst8Section () const

const MCSection *

getMergeableConst16Section () const

const MCSection *

getMergeableConst32Section () const

const MCSection *

getTLSTLVSection () const

const MCSection *

getTLSThreadInitSection () const

const MCSection *

getCStringSection () const

const MCSection *

getUStringSection () const

MCSection *

getTextCoalSection () const

const MCSection *

getConstTextCoalSection () const

const MCSection *

getConstDataSection () const

const MCSection *

getDataCoalSection () const

const MCSection *

getConstDataCoalSection () const

const MCSection *

getDataCommonSection () const

MCSection *

getDataBSSSection () const

const MCSection *

getFourByteConstantSection () const

const MCSection *

getEightByteConstantSection () const

const MCSection *

getSixteenByteConstantSection () const

MCSection *

getLazySymbolPointerSection () const

MCSection *

getNonLazySymbolPointerSection () const

MCSection *

getThreadLocalPointerSection () const

MCSection *

getAddrSigSection () const

MCSection *

getDrectveSection () const

MCSection *

getPDataSection () const

MCSection *

getXDataSection () const

MCSection *

getSXDataSection () const

MCSection *

getGEHContSection () const

MCSection *

getGFIDsSection () const

MCSection *

getGIATsSection () const

MCSection *

getGLJMPSection () const

MCSection *

getPPA2ListSection () const

MCSection *

getADASection () const

MCSection *

getIDRLSection () const

MCSection *

getTOCBaseSection () const

MCSection *

getEHFrameSection () const

MCSection *

getSFrameSection () const

bool

isPositionIndependent () const

MCSection *

getSwift5ReflectionSection (llvm::binaryformat::Swift5ReflectionSectionKind ReflSectionKind)