|
LLVM
4.0.0
|
Represent a reference to a symbol from inside an expression. More...
#include <MCExpr.h>
Public Member Functions | |
Accessors | |
| const MCSymbol & | getSymbol () const |
| VariantKind | getKind () const |
| void | printVariantKind (raw_ostream &OS) const |
| bool | hasSubsectionsViaSymbols () const |
Public Member Functions inherited from llvm::MCExpr | |
| ExprKind | getKind () const |
| void | print (raw_ostream &OS, const MCAsmInfo *MAI, bool InParens=false) const |
| void | dump () const |
| bool | evaluateAsAbsolute (int64_t &Res, const MCAsmLayout &Layout, const SectionAddrMap &Addrs) const |
| Try to evaluate the expression to an absolute value. More... | |
| bool | evaluateAsAbsolute (int64_t &Res) const |
| bool | evaluateAsAbsolute (int64_t &Res, const MCAssembler &Asm) const |
| bool | evaluateAsAbsolute (int64_t &Res, const MCAsmLayout &Layout) const |
| bool | evaluateKnownAbsolute (int64_t &Res, const MCAsmLayout &Layout) const |
| bool | evaluateAsRelocatable (MCValue &Res, const MCAsmLayout *Layout, const MCFixup *Fixup) const |
| Try to evaluate the expression to a relocatable value, i.e. More... | |
| bool | evaluateAsValue (MCValue &Res, const MCAsmLayout &Layout) const |
| Try to evaluate the expression to the form (a - b + constant) where neither a nor b are variables. More... | |
| MCFragment * | findAssociatedFragment () const |
| Find the "associated section" for this expression, which is currently defined as the absolute section for constants, or otherwise the section associated with the first defined symbol in the expression. More... | |
Static Public Member Functions | |
| static bool | classof (const MCExpr *E) |
Construction | |
| static const MCSymbolRefExpr * | create (const MCSymbol *Symbol, MCContext &Ctx) |
| static const MCSymbolRefExpr * | create (const MCSymbol *Symbol, VariantKind Kind, MCContext &Ctx) |
| static const MCSymbolRefExpr * | create (StringRef Name, VariantKind Kind, MCContext &Ctx) |
Static Utility Functions | |
| static StringRef | getVariantKindName (VariantKind Kind) |
| static VariantKind | getVariantKindForName (StringRef Name) |
Additional Inherited Members | |
Protected Member Functions inherited from llvm::MCExpr | |
| MCExpr (ExprKind Kind) | |
| bool | evaluateAsRelocatableImpl (MCValue &Res, const MCAssembler *Asm, const MCAsmLayout *Layout, const MCFixup *Fixup, const SectionAddrMap *Addrs, bool InSet) const |
Represent a reference to a symbol from inside an expression.
A symbol reference in an expression may be a use of a label, a use of an assembler variable (defined constant), or constitute an implicit definition of the symbol as external.
| enum llvm::MCSymbolRefExpr::VariantKind : uint16_t |
Definition at line 329 of file MCExpr.h.
References llvm::MCExpr::getKind(), and llvm::MCExpr::SymbolRef.
|
inlinestatic |
Definition at line 298 of file MCExpr.h.
References VK_None.
Referenced by llvm::ConstantPool::addEntry(), buildSymbolDiff(), computeLabelDiff(), createPCXRelExprOp(), createSparcMCOperand(), llvm::AddressPool::emit(), EmitAbsDifference(), llvm::MCStreamer::emitAbsoluteSymbolDiff(), llvm::MCWinCOFFStreamer::EmitCOFFSecRel32(), llvm::MCWinCOFFStreamer::EmitCOFFSectionIndex(), llvm::MipsTargetELFStreamer::emitDirectiveCpLoad(), llvm::MipsTargetELFStreamer::emitDirectiveCpsetup(), llvm::MipsTargetELFStreamer::emitDirectiveEnd(), llvm::AsmPrinter::EmitFunctionBody(), EmitGenDwarfAranges(), EmitGenDwarfInfo(), EmitGenDwarfRanges(), llvm::SystemZAsmPrinter::EmitInstruction(), llvm::ARMAsmPrinter::EmitInstruction(), llvm::X86AsmPrinter::EmitInstruction(), llvm::AMDGPUAsmPrinter::EmitInstruction(), llvm::ARMAsmPrinter::EmitJumpTableAddrs(), llvm::AsmPrinter::EmitJumpTableInfo(), llvm::ARMAsmPrinter::EmitJumpTableInsts(), llvm::ARMAsmPrinter::EmitJumpTableTBInst(), llvm::AsmPrinter::EmitLabelPlusOffset(), llvm::SystemZAsmPrinter::EmitMachineConstantPoolValue(), llvm::ARMAsmPrinter::EmitMachineConstantPoolValue(), emitNonLazySymbolPointer(), llvm::MCObjectStreamer::EmitRelocDirective(), EmitRuntimeFunction(), llvm::AMDGPUTargetELFStreamer::EmitRuntimeMetadata(), EmitSymbolRefWithOfs(), llvm::MCStreamer::EmitSymbolValue(), EmitUnwindInfo(), llvm::MCELFStreamer::EmitWeakReference(), llvm::ARMAsmPrinter::EmitXXStructor(), llvm::CodeViewContext::encodeDefRange(), llvm::AVRMCExpr::evaluateAsRelocatableImpl(), llvm::PPCMCExpr::evaluateAsRelocatableImpl(), forceExpAbs(), llvm::ARMElfTargetObjectFile::getDebugThreadLocalSymbol(), llvm::MipsTargetObjectFile::getDebugThreadLocalSymbol(), llvm::X86ELFTargetObjectFile::getDebugThreadLocalSymbol(), llvm::TargetLoweringObjectFile::getDebugThreadLocalSymbol(), llvm::SystemZMCInstLower::getExpr(), llvm::SparcELFMCAsmInfo::getExprForFDESymbol(), llvm::MCAsmInfo::getExprForFDESymbol(), llvm::SparcELFMCAsmInfo::getExprForPersonalitySymbol(), llvm::AArch64MCAsmInfoDarwin::getExprForPersonalitySymbol(), llvm::X86_64MCAsmInfoDarwin::getExprForPersonalitySymbol(), getGlobalOffsetTable(), llvm::X86_64MachoTargetObjectFile::getIndirectSymViaGOTPCRel(), llvm::AArch64_MachoTargetObjectFile::getIndirectSymViaGOTPCRel(), llvm::TargetLoweringObjectFileMachO::getIndirectSymViaGOTPCRel(), llvm::X86TargetLowering::getPICJumpTableRelocBaseExpr(), llvm::PPCTargetLowering::getPICJumpTableRelocBaseExpr(), llvm::TargetLowering::getPICJumpTableRelocBaseExpr(), GetSymbolRef(), getTLSGetOffset(), llvm::X86_64MachoTargetObjectFile::getTTypeGlobalReference(), llvm::SparcELFTargetObjectFile::getTTypeGlobalReference(), llvm::AArch64_MachoTargetObjectFile::getTTypeGlobalReference(), llvm::ARMElfTargetObjectFile::getTTypeGlobalReference(), llvm::TargetLoweringObjectFileELF::getTTypeGlobalReference(), llvm::TargetLoweringObjectFileMachO::getTTypeGlobalReference(), llvm::TargetLoweringObjectFile::getTTypeGlobalReference(), llvm::TargetLoweringObjectFile::getTTypeReference(), llvm::HexagonLowerToMC(), llvm::HexagonAsmPrinter::HexagonProcessInstruction(), llvm::MSP430MCInstLower::Lower(), llvm::LanaiMCInstLower::Lower(), llvm::BPFMCInstLower::Lower(), llvm::AsmPrinter::lowerConstant(), llvm::X86TargetLowering::LowerCustomJumpTableEntry(), llvm::AVRMCInstLower::lowerInstruction(), llvm::AMDGPUMCInstLower::lowerOperand(), llvm::AArch64MCInstLower::lowerOperand(), llvm::ARMAsmPrinter::lowerOperand(), llvm::LowerPPCMachineInstrToMCInst(), llvm::TargetLoweringObjectFileELF::lowerRelativeReference(), LowerSymbolOperand(), llvm::AVRMCInstLower::lowerSymbolOperand(), llvm::MSP430MCInstLower::LowerSymbolOperand(), llvm::BPFMCInstLower::LowerSymbolOperand(), llvm::LanaiMCInstLower::LowerSymbolOperand(), llvm::AArch64MCInstLower::lowerSymbolOperandDarwin(), llvm::AArch64MCInstLower::lowerSymbolOperandELF(), MakeStartMinusEndExpr(), llvm::FaultMaps::recordFaultingOp(), llvm::AArch64ExternalSymbolizer::tryAddingSymbolicOperand(), llvm::MCExternalSymbolizer::tryAddingSymbolicOperand(), and llvm::AMDGPUSymbolizer::tryAddingSymbolicOperand().
|
static |
Definition at line 164 of file MCExpr.cpp.
|
static |
Definition at line 170 of file MCExpr.cpp.
|
inline |
Definition at line 313 of file MCExpr.h.
Referenced by llvm::AVRMCExpr::evaluateAsRelocatableImpl(), llvm::MCExpr::evaluateAsRelocatableImpl(), llvm::PPCMCExpr::evaluateAsRelocatableImpl(), llvm::MCValue::getAccessVariant(), getRelocType(), HasSecRelSymbolRef(), llvm::MCObjectWriter::isSymbolRefDifferenceFullyResolved(), llvm::MCAssembler::isThumbFunc(), llvm::MCExpr::print(), printExpr(), and llvm::PPCInstPrinter::printTLSCall().
Definition at line 311 of file MCExpr.h.
Referenced by llvm::MCAssembler::computeFragmentSize(), llvm::AVRMCExpr::evaluateAsRelocatableImpl(), llvm::MCExpr::evaluateAsRelocatableImpl(), llvm::PPCMCExpr::evaluateAsRelocatableImpl(), EvaluateCRExpr(), llvm::MCExpr::findAssociatedFragment(), fixELFSymbolsInTLSFixupsImpl(), llvm::MCAsmLayout::getBaseSymbol(), llvm::TargetLoweringObjectFileMachO::getIndirectSymViaGOTPCRel(), llvm::MachObjectWriter::getSymbolAddress(), getSymbolOffsetImpl(), handleIndirectSymViaGOTPCRel(), hasGOTReference(), llvm::MCObjectWriter::isSymbolRefDifferenceFullyResolved(), llvm::MCAssembler::isThumbFunc(), llvm::MCExpr::print(), printExpr(), llvm::PPCInstPrinter::printTLSCall(), llvm::ARMAsmBackend::processFixupValue(), llvm::AVRAsmBackend::processFixupValue(), and StartsWithGlobalOffsetTable().
|
static |
Definition at line 287 of file MCExpr.cpp.
|
static |
Definition at line 175 of file MCExpr.cpp.
Referenced by llvm::PPCInstPrinter::printTLSCall().
|
inline |
Definition at line 317 of file MCExpr.h.
Referenced by llvm::MCExpr::evaluateAsRelocatableImpl().
| void MCSymbolRefExpr::printVariantKind | ( | raw_ostream & | OS | ) | const |
Definition at line 386 of file MCExpr.cpp.
Referenced by llvm::MCExpr::print().
1.8.6