LLVM 22.0.0git
|
#include "llvm/MC/MCExpr.h"
Public Member Functions | |
Accessors | |
int64_t | getValue () const |
unsigned | getSizeInBytes () const |
bool | useHexFormat () const |
Public Member Functions inherited from llvm::MCExpr | |
MCExpr (const MCExpr &)=delete | |
MCExpr & | operator= (const MCExpr &)=delete |
ExprKind | getKind () const |
SMLoc | getLoc () const |
LLVM_ABI void | dump () const |
LLVM_ABI bool | evaluateAsAbsolute (int64_t &Res) const |
Try to evaluate the expression to an absolute value. | |
LLVM_ABI bool | evaluateAsAbsolute (int64_t &Res, const MCAssembler &Asm) const |
LLVM_ABI bool | evaluateAsAbsolute (int64_t &Res, const MCAssembler *Asm) const |
LLVM_ABI bool | evaluateKnownAbsolute (int64_t &Res, const MCAssembler &Asm) const |
Aggressive variant of evaluateAsRelocatable when relocations are unavailable (e.g. | |
LLVM_ABI bool | evaluateAsRelocatable (MCValue &Res, const MCAssembler *Asm) const |
Try to evaluate the expression to a relocatable value, i.e. | |
LLVM_ABI bool | evaluateAsValue (MCValue &Res, const MCAssembler &Asm) const |
Try to evaluate the expression to the form (a - b + constant) where neither a nor b are variables. | |
LLVM_ABI 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. |
Static Public Member Functions | |
static bool | classof (const MCExpr *E) |
Construction | |
static LLVM_ABI const MCConstantExpr * | create (int64_t Value, MCContext &Ctx, bool PrintInHex=false, unsigned SizeInBytes=0) |
Static Public Member Functions inherited from llvm::MCExpr | |
static LLVM_ABI bool | evaluateSymbolicAdd (const MCAssembler *, bool, const MCValue &, const MCValue &, MCValue &) |
Additional Inherited Members | |
Public Types inherited from llvm::MCExpr | |
enum | ExprKind : uint8_t { Binary , Constant , SymbolRef , Unary , Specifier , Target } |
Protected Types inherited from llvm::MCExpr | |
using | Spec = uint16_t |
Protected Member Functions inherited from llvm::MCExpr | |
MCExpr (ExprKind Kind, SMLoc Loc, unsigned SubclassData=0) | |
LLVM_ABI bool | evaluateAsRelocatableImpl (MCValue &Res, const MCAssembler *Asm, bool InSet) const |
unsigned | getSubclassData () const |
Definition at line 180 of file MCExpr.h.
References llvm::MCExpr::Constant, E(), and llvm::MCExpr::MCExpr().
|
static |
Definition at line 212 of file MCExpr.cpp.
Referenced by llvm::HexagonMCInstrInfo::addConstant(), ARMEmitUnwindInfo(), llvm::AMDGPU::MCKernelDescriptor::bits_get(), llvm::AMDGPU::MCKernelDescriptor::bits_set(), computeAccumOffset(), llvm::AMDGPUMCExpr::createExtraSGPRs(), llvm::AMDGPUMCExpr::createLit(), llvm::AMDGPUMCExpr::createOccupancy(), llvm::SystemZTargetGOFFStreamer::createWordDiffExpr(), llvm::SystemZTargetHLASMStreamer::createWordDiffExpr(), llvm::AMDGPUDisassembler::decodeVersionImm(), llvm::AMDGPUTargetELFStreamer::emitAMDGPULDS(), llvm::AMDGPUTargetAsmStreamer::EmitAmdhsaKernelDescriptor(), llvm::AMDGPUTargetELFStreamer::EmitAmdhsaKernelDescriptor(), llvm::AsmPrinter::emitCOFFFeatureSymbol(), llvm::MCWinCOFFStreamer::emitCOFFImgRel32(), llvm::MCWinCOFFStreamer::emitCOFFSecRel32(), llvm::MCELFStreamer::emitCommonSymbol(), llvm::WebAssemblyAsmPrinter::emitEndOfAsmFile(), llvm::CodeViewContext::emitFileChecksums(), llvm::MCStreamer::emitFill(), llvm::AsmPrinter::emitFrameAlloc(), llvm::AsmPrinter::emitGlobalAlias(), llvm::AsmPrinter::emitGlobalVariable(), llvm::ARMAsmPrinter::emitInstruction(), llvm::SystemZAsmPrinter::emitInstruction(), llvm::ARMAsmPrinter::emitJumpTableAddrs(), llvm::BPFAsmPrinter::emitJumpTableInfo(), llvm::ARMAsmPrinter::emitJumpTableTBInst(), llvm::AMDGPU::AMDGPUMCKernelCodeT::EmitKernelCodeT(), llvm::AsmPrinter::emitLabelPlusOffset(), llvm::XtensaAsmPrinter::emitMachineConstantPoolEntry(), llvm::ARMAsmPrinter::emitMachineConstantPoolValue(), llvm::TargetLoweringObjectFileELF::emitPersonalityValue(), EmitSymbolRefWithOfs(), llvm::AsmPrinter::emitXRayTable(), llvm::CodeViewContext::encodeDefRange(), llvm::MCExpr::evaluateAsRelocatableImpl(), llvm::AMDGPUTargetELFStreamer::finish(), llvm::MCResourceInfo::gatherResourceInfo(), llvm::MipsMCCodeEmitter::getBranchTarget21OpValue(), llvm::MipsMCCodeEmitter::getBranchTarget21OpValueMM(), llvm::MipsMCCodeEmitter::getBranchTarget26OpValue(), llvm::MipsMCCodeEmitter::getBranchTarget26OpValueMM(), llvm::MipsMCCodeEmitter::getBranchTargetOpValue(), llvm::MipsMCCodeEmitter::getBranchTargetOpValue1SImm16(), llvm::MipsMCCodeEmitter::getBranchTargetOpValueLsl2MMR6(), llvm::MipsMCCodeEmitter::getBranchTargetOpValueMMR6(), llvm::SIProgramInfo::getComputePGMRSrc1(), llvm::SIProgramInfo::getComputePGMRSrc2(), llvm::MipsTargetObjectFile::getDebugThreadLocalSymbol(), llvm::AMDGPU::MCKernelDescriptor::getDefaultAmdhsaKernelDescriptor(), llvm::SystemZMCInstLower::getExpr(), llvm::X86_64MCAsmInfoDarwin::getExprForPersonalitySymbol(), llvm::AArch64_ELFTargetObjectFile::getIndirectSymViaGOTPCRel(), llvm::ARMElfTargetObjectFile::getIndirectSymViaGOTPCRel(), llvm::RISCVELFTargetObjectFile::getIndirectSymViaGOTPCRel(), llvm::TargetLoweringObjectFileMachO::getIndirectSymViaGOTPCRel(), llvm::X86_64ELFTargetObjectFile::getIndirectSymViaGOTPCRel(), llvm::X86_64MachoTargetObjectFile::getIndirectSymViaGOTPCRel(), llvm::SIProgramInfo::getPGMRSrc1(), llvm::SIProgramInfo::getPGMRSrc2(), GetSubDivExpr(), GetSymbolRef(), GetSymbolRef(), llvm::X86_64MachoTargetObjectFile::getTTypeGlobalReference(), llvm::HexagonLowerToMC(), llvm::HexagonMCELFStreamer::HexagonMCEmitCommonSymbol(), llvm::HexagonAsmPrinter::HexagonProcessInstruction(), llvm::AMDGPU::AMDGPUMCKernelCodeT::initDefault(), llvm::SIInstrInfo::insertIndirectBranch(), llvm::AsmPrinter::lowerConstant(), llvm::AMDGPUMCInstLower::lowerOperand(), llvm::TargetLoweringObjectFileCOFF::lowerRelativeReference(), llvm::TargetLoweringObjectFileELF::lowerSymbolDifference(), llvm::LanaiMCInstLower::LowerSymbolOperand(), llvm::M68kMCInstLower::LowerSymbolOperand(), llvm::MSP430MCInstLower::LowerSymbolOperand(), llvm::XtensaAsmPrinter::LowerSymbolOperand(), LowerSymbolOperand(), llvm::AVRMCInstLower::lowerSymbolOperand(), lowerSymbolOperand(), lowerSymbolOperand(), llvm::AArch64MCInstLower::lowerSymbolOperandCOFF(), llvm::AArch64MCInstLower::lowerSymbolOperandELF(), llvm::AArch64MCInstLower::lowerSymbolOperandMachO(), makeEndMinusStartExpr(), makeStartPlusIntExpr(), MaskShift(), llvm::AMDGPU::maskShiftGet(), llvm::AMDGPU::maskShiftSet(), llvm::RISCVAsmBackend::maybeAddVendorReloc(), n1ConstDecoder(), llvm::LoongArchAsmBackend::relaxAlign(), llvm::RISCVAsmBackend::relaxAlign(), llvm::SIProgramInfo::reset(), llvm::AMDGPUAsmPrinter::runOnMachineFunction(), ScaleVectorOffset(), llvm::AMDGPUPALMetadata::setRegister(), llvm::MCContext::setSymbolValue(), llvm::AArch64ExternalSymbolizer::tryAddingSymbolicOperand(), llvm::MCExternalSymbolizer::tryAddingSymbolicOperand(), and tryFoldHelper().
|
inline |
Definition at line 172 of file MCExpr.h.
References llvm::MCExpr::getSubclassData().
|
inline |
Definition at line 171 of file MCExpr.h.
Referenced by llvm::CodeViewContext::encodeInlineLineTable(), IsMemoryAssignmentError(), and shouldBeSls().
|
inline |
Definition at line 176 of file MCExpr.h.
References llvm::MCExpr::getSubclassData().