Go to the documentation of this file.
25 #define DEBUG_TYPE "mipsmcexpr"
125 if (Expr->evaluateAsAbsolute(AbsVal))
128 Expr->
print(OS, MAI,
true);
188 AbsVal = SignExtend64<16>(AbsVal);
192 AbsVal = SignExtend64<16>((AbsVal + 0x8000) >> 16);
195 AbsVal = SignExtend64<16>((AbsVal + 0x80008000LL) >> 32);
198 AbsVal = SignExtend64<16>((AbsVal + 0x800080008000LL) >> 48);
276 E->fixELFSymbolsInTLSFixups(
Asm);
294 if (
const MipsMCExpr *S2 = dyn_cast<const MipsMCExpr>(S1->getSubExpr())) {
void visitUsedExpr(const MCExpr &Expr)
This is an optimization pass for GlobalISel generic memory operations.
static void fixELFSymbolsInTLSFixupsImpl(const MCExpr *Expr, MCAssembler &Asm)
Context object for machine code objects.
This class is intended to be used as a base class for asm properties and features specific to the tar...
void visitUsedExpr(MCStreamer &Streamer) const override
void printImpl(raw_ostream &OS, const MCAsmInfo *MAI) const override
Binary assembler expressions.
bool evaluateAsRelocatable(MCValue &Res, const MCAsmLayout *Layout, const MCFixup *Fixup) const
Try to evaluate the expression to a relocatable value, i.e.
Streaming machine code generation interface.
static GCRegistry::Add< CoreCLRGC > E("coreclr", "CoreCLR-compatible GC")
@ Target
Target specific expression.
bool isAbsolute() const
Is this an absolute (as opposed to relocatable) value.
const MCExpr * getRHS() const
Get the right-hand side expression of the binary operator.
This class implements an extremely fast bulk output stream that can only output to a stream.
const MCSymbol & getSymbol() const
int64_t getConstant() const
const MCSymbolRefExpr * getSymA() const
@ Binary
Binary expressions.
static MCValue get(const MCSymbolRefExpr *SymA, const MCSymbolRefExpr *SymB=nullptr, int64_t Val=0, uint32_t RefKind=0)
void fixELFSymbolsInTLSFixups(MCAssembler &Asm) const override
Represent a reference to a symbol from inside an expression.
PowerPC TLS Dynamic Call Fixup
#define llvm_unreachable(msg)
Marks that the current location is not supposed to be reachable.
const MCExpr * getSubExpr() const
Get the child of this expression.
static const MipsMCExpr * create(MipsExprKind Kind, const MCExpr *Expr, MCContext &Ctx)
Encapsulates the layout of an assembly file at a particular point in time.
uint32_t getRefKind() const
void print(raw_ostream &OS, const MCAsmInfo *MAI, bool InParens=false) const
@ SymbolRef
References to labels and assigned expressions.
@ Unary
Unary expressions.
@ Constant
Constant expressions.
static const MipsMCExpr * createGpOff(MipsExprKind Kind, const MCExpr *Expr, MCContext &Ctx)
bool evaluateAsRelocatableImpl(MCValue &Res, const MCAsmLayout *Layout, const MCFixup *Fixup) const override
This represents an "assembler immediate".
Encode information on a single operation to perform on a byte sequence (e.g., an encoded instruction)...
Base class for the full range of assembler expressions which are needed for parsing.
MipsExprKind getKind() const
Get the kind of this expression.
const MCSymbolRefExpr * getSymB() const
const MCExpr * getLHS() const
Get the left-hand side expression of the binary operator.