|
LLVM 23.0.0git
|
Instances of this class represent a uniqued identifier for a section in the current translation unit. More...
#include "llvm/MC/MCSection.h"
Classes | |
| struct | FragList |
| struct | iterator |
Public Attributes | |
| friend | MCAssembler |
| friend | MCObjectStreamer |
Static Public Attributes | |
| static constexpr unsigned | NonUniqueID = ~0U |
Protected Member Functions | |
| MCSection (StringRef Name, bool IsText, bool IsBss, MCSymbol *Begin) | |
Protected Attributes | |
| StringRef | Name |
Friends | |
| class | MCFragment |
Instances of this class represent a uniqued identifier for a section in the current translation unit.
The MCContext class uniques and creates these.
Definition at line 517 of file MCSection.h.
Definition at line 21 of file MCSection.cpp.
References Name.
Referenced by getBeginSymbol(), llvm::MCSectionELF::getLinkedToSection(), llvm::MCSectionCOFF::MCAsmInfoCOFF, llvm::MCSectionELF::MCAsmInfoELF, llvm::MCSectionWasm::MCAsmInfoWasm, llvm::MCSectionXCOFF::MCAsmInfoXCOFF, llvm::MCSectionDXContainer::MCContext, llvm::MCSectionSPIRV::MCContext, MCSection(), llvm::MCSectionGOFF::MCSymbolGOFF, and operator=().
References MCSection().
|
inline |
Definition at line 639 of file MCSection.h.
|
inline |
Definition at line 638 of file MCSection.h.
Referenced by llvm::MCSectionMachO::allocAtoms(), llvm::MCAssembler::getSectionAddressSize(), and llvm::MachObjectWriter::writeObject().
| LLVM_DUMP_METHOD void MCSection::dump | ( | DenseMap< const MCFragment *, SmallVector< const MCSymbol *, 0 > > * | FragToSyms = nullptr | ) | const |
Definition at line 46 of file MCSection.cpp.
References llvm::errs(), F, firstLinkerRelaxable(), getName(), isLinkerRelaxable(), LLVM_DUMP_METHOD, and MCFragment.
Referenced by llvm::MCAssembler::dump().
|
inline |
Definition at line 640 of file MCSection.h.
|
inline |
Makes sure that Alignment is at least MinAlignment.
Definition at line 605 of file MCSection.h.
Referenced by llvm::MCWinCOFFStreamer::emitCOFFSafeSEH(), llvm::MCWinCOFFStreamer::emitCOFFSymbolIndex(), llvm::AMDGPUAsmPrinter::emitFunctionBodyEnd(), and llvm::MipsTargetELFStreamer::finish().
|
inline |
Definition at line 616 of file MCSection.h.
Referenced by llvm::MCObjectStreamer::emitPrefAlign().
|
inline |
Definition at line 632 of file MCSection.h.
Referenced by dump().
|
inline |
Definition at line 601 of file MCSection.h.
Referenced by addData(), getAlignment(), getAlignmentForObjectFile(), llvm::MachObjectWriter::getPaddingSize(), and llvm::MachObjectWriter::writeSection().
Definition at line 33 of file MCSection.cpp.
References getAlign(), getPreferredAlignment(), llvm::NextPowerOf2(), and Size.
|
inline |
Definition at line 590 of file MCSection.h.
Referenced by llvm::DwarfCompileUnit::addAddrTableBase(), llvm::DwarfUnit::addRnglistsBase(), llvm::DwarfCompileUnit::addScopeRangeList(), llvm::DwarfUnit::addStringOffsetsStart(), llvm::DwarfCompileUnit::applyStmtList(), llvm::MCStreamer::changeSection(), llvm::MCContext::createELFRelSection(), llvm::DwarfUnit::emitCommonHeader(), llvm::BPFAsmPrinter::emitJumpTableInfo(), llvm::MCObjectStreamer::emitRelocDirective(), llvm::ELFObjectWriter::executePostLayoutBinding(), llvm::MCObjectFileInfo::getBBAddrMapSection(), getBeginSymbol(), llvm::MCObjectFileInfo::getCallGraphSection(), llvm::MCObjectFileInfo::getKCFITrapSection(), llvm::MCObjectFileInfo::getPCSection(), llvm::MCObjectFileInfo::getPseudoProbeSection(), llvm::MCObjectFileInfo::getStackSizesSection(), llvm::DwarfCompileUnit::initStmtList(), llvm::MCDwarfLineStr::MCDwarfLineStr(), llvm::ELFObjectWriter::recordRelocation(), and llvm::LoongArchAsmBackend::relaxAlign().
Definition at line 591 of file MCSection.h.
References getBeginSymbol(), and MCSection().
|
inline |
Definition at line 636 of file MCSection.h.
References MCFragment.
Referenced by llvm::MCStreamer::changeSection().
Definition at line 27 of file MCSection.cpp.
|
inline |
Definition at line 587 of file MCSection.h.
References Name.
Referenced by addData(), llvm::BTFDebug::beginFunctionImpl(), canUseLocalRelocation(), dump(), llvm::SystemZHLASMAsmStreamer::emitLabel(), llvm::MCContext::getAssociativeCOFFSection(), llvm::TargetLoweringObjectFileGOFF::getModuleMetadata(), isDwoSection(), llvm::MCAsmInfoDarwin::isSectionAtomizableBySymbols(), llvm::GOFFObjectWriter::recordRelocation(), llvm::XtensaTargetELFStreamer::startLiteralSection(), llvm::WinCOFFWriter::writeObject(), and llvm::MachObjectWriter::writeSection().
|
inline |
Definition at line 623 of file MCSection.h.
|
inline |
Definition at line 610 of file MCSection.h.
Referenced by getAlignmentForObjectFile().
| bool MCSection::hasEnded | ( | ) | const |
Definition at line 43 of file MCSection.cpp.
|
inline |
Definition at line 626 of file MCSection.h.
Referenced by llvm::AMDGPUAsmPrinter::doFinalization(), and llvm::MCObjectStreamer::mayHaveInstructions().
|
inline |
Check whether this section is "virtual", that is has no actual object file contents.
Definition at line 647 of file MCSection.h.
Referenced by llvm::AsmPrinter::emitGlobalVariable(), llvm::MachObjectWriter::getPaddingSize(), llvm::MCAssembler::getSectionFileSize(), llvm::MCSectionGOFF::getTextStyle(), llvm::MachObjectWriter::writeSection(), and llvm::MCAssembler::writeSectionData().
|
inline |
Definition at line 633 of file MCSection.h.
Referenced by llvm::LoongArchAsmBackend::addReloc(), attemptToFoldSymbolOffsetDifference(), and dump().
|
inline |
Definition at line 629 of file MCSection.h.
Referenced by llvm::AArch64TargetStreamer::emitNoteSection().
|
inline |
Definition at line 588 of file MCSection.h.
Referenced by llvm::MCSectionWasm::MCAsmInfoWasm, llvm::MCSectionXCOFF::MCAsmInfoXCOFF, llvm::MCSectionDXContainer::MCContext, llvm::MCSectionGOFF::MCSymbolGOFF, and llvm::MCAsmInfoXCOFF::useCodeAlign().
References MCSection().
|
inline |
Definition at line 602 of file MCSection.h.
Referenced by llvm::MipsTargetELFStreamer::emitDirectiveEnd(), llvm::MipsTargetELFStreamer::emitMipsAbiFlags(), llvm::MipsRegInfoRecord::EmitMipsOptionRecord(), llvm::dwarf_linker::classic::DwarfStreamer::emitSwiftAST(), llvm::dwarf_linker::classic::DwarfStreamer::emitSwiftReflectionSection(), and llvm::XtensaTargetELFStreamer::startLiteralSection().
|
inline |
Definition at line 594 of file MCSection.h.
References assert().
|
inline |
Definition at line 634 of file MCSection.h.
|
inline |
Definition at line 627 of file MCSection.h.
Referenced by llvm::MCObjectStreamer::emitInstruction().
|
inline |
Definition at line 630 of file MCSection.h.
|
inline |
Definition at line 624 of file MCSection.h.
Referenced by llvm::MCAssembler::layout().
|
friend |
Definition at line 521 of file MCSection.h.
References MCFragment.
Referenced by dump(), getDummyFragment(), llvm::MCSection::iterator::iterator(), MCFragment, and llvm::MCSection::iterator::operator*().
| friend llvm::MCSection::MCAssembler |
Definition at line 519 of file MCSection.h.
| friend llvm::MCSection::MCObjectStreamer |
Definition at line 520 of file MCSection.h.
|
protected |
Definition at line 579 of file MCSection.h.
Referenced by getName(), llvm::MCSectionCOFF::isImplicitlyDiscardable(), llvm::MCSectionCOFF::MCAsmInfoCOFF, llvm::MCSectionELF::MCAsmInfoELF, llvm::MCSectionWasm::MCAsmInfoWasm, llvm::MCSectionXCOFF::MCAsmInfoXCOFF, llvm::MCSectionDXContainer::MCContext, MCSection(), llvm::MCSectionGOFF::MCSymbolGOFF, llvm::MCSectionGOFF::setName(), and llvm::MCSectionCOFF::shouldOmitSectionDirective().
|
staticconstexpr |
Definition at line 522 of file MCSection.h.
Referenced by calcUniqueIDUpdateFlagsAndSize(), llvm::MCContext::createELFGroupSection(), llvm::AsmPrinter::emitPatchableFunctionEntries(), llvm::AsmPrinter::emitXRayTable(), llvm::MCContext::getAssociativeCOFFSection(), llvm::MCContext::getCOFFSection(), llvm::MCContext::getELFSection(), llvm::MCContext::getELFSection(), llvm::MCContext::getELFSection(), llvm::TargetLoweringObjectFileWasm::getExplicitSectionGlobal(), llvm::TargetLoweringObjectFileELF::getSectionForLSDA(), llvm::TargetLoweringObjectFileELF::getSectionForMachineBasicBlock(), llvm::MCSectionCOFF::isUnique(), llvm::MCSectionELF::isUnique(), llvm::MCContext::recordELFMergeableSectionInfo(), selectELFSectionForGlobal(), llvm::TargetLoweringObjectFileCOFF::SelectSectionForGlobal(), and selectWasmSectionForGlobal().