LLVM API Documentation
#include <HexagonTargetObjectFile.h>
Public Member Functions | |
void | Initialize (MCContext &Ctx, const TargetMachine &TM) override |
bool | IsGlobalInSmallSection (const GlobalValue *GV, const TargetMachine &TM, SectionKind Kind) const |
bool | IsGlobalInSmallSection (const GlobalValue *GV, const TargetMachine &TM) const |
bool | IsSmallDataEnabled () const |
const MCSection * | SelectSectionForGlobal (const GlobalValue *GV, SectionKind Kind, Mangler &Mang, const TargetMachine &TM) const override |
Definition at line 18 of file HexagonTargetObjectFile.h.
void HexagonTargetObjectFile::Initialize | ( | MCContext & | ctx, |
const TargetMachine & | TM | ||
) | [override, virtual] |
This method must be called before any actual lowering is done. This specifies the current context for codegen, and gives the lowering implementations a chance to set up their default sections.
Initialize - this method must be called before any actual lowering is done. This specifies the current context for codegen, and gives the lowering implementations a chance to set up their default sections.
Reimplemented from llvm::TargetLoweringObjectFile.
Definition at line 31 of file HexagonTargetObjectFile.cpp.
References llvm::SectionKind::getBSS(), llvm::TargetLoweringObjectFile::getContext(), llvm::SectionKind::getDataRel(), llvm::MCContext::getELFSection(), llvm::ELF::SHF_ALLOC, llvm::ELF::SHF_WRITE, llvm::ELF::SHT_NOBITS, and llvm::ELF::SHT_PROGBITS.
bool HexagonTargetObjectFile::IsGlobalInSmallSection | ( | const GlobalValue * | GV, |
const TargetMachine & | TM, | ||
SectionKind | Kind | ||
) | const |
IsGlobalInSmallSection - Return true if this global address should be placed into small data/bss section.
IsGlobalInSmallSection - Return true if this global value should be placed into small data/bss section.
Definition at line 73 of file HexagonTargetObjectFile.cpp.
References llvm::dyn_cast(), llvm::TargetSubtargetInfo::getDataLayout(), llvm::SequentialType::getElementType(), llvm::TargetMachine::getSubtargetImpl(), llvm::GlobalValue::getType(), llvm::DataLayout::getTypeAllocSize(), llvm::SectionKind::isBSS(), llvm::SectionKind::isCommon(), llvm::SectionKind::isDataNoRel(), and IsInSmallSection().
Referenced by IsGlobalInSmallSection(), llvm::HexagonTargetLowering::LowerGLOBALADDRESS(), and SelectSectionForGlobal().
bool HexagonTargetObjectFile::IsGlobalInSmallSection | ( | const GlobalValue * | GV, |
const TargetMachine & | TM | ||
) | const |
IsGlobalInSmallSection - Return true if this global value should be placed into small data/bss section.
Definition at line 57 of file HexagonTargetObjectFile.cpp.
References llvm::TargetLoweringObjectFile::getKindForGlobal(), llvm::GlobalValue::hasAvailableExternallyLinkage(), llvm::GlobalValue::isDeclaration(), and IsGlobalInSmallSection().
Definition at line 51 of file HexagonTargetObjectFile.cpp.
References SmallDataThreshold.
const MCSection * HexagonTargetObjectFile::SelectSectionForGlobal | ( | const GlobalValue * | GV, |
SectionKind | Kind, | ||
Mangler & | Mang, | ||
const TargetMachine & | TM | ||
) | const [override, virtual] |
Reimplemented from llvm::TargetLoweringObjectFileELF.
Definition at line 90 of file HexagonTargetObjectFile.cpp.
References llvm::SectionKind::isBSS(), llvm::SectionKind::isDataNoRel(), and IsGlobalInSmallSection().