Go to the documentation of this file.
9 #ifndef LLVM_AVR_MCEXPR_H
10 #define LLVM_AVR_MCEXPR_H
56 void setNegated(
bool negated =
true) { Negated = negated; }
60 const MCFixup *Fixup)
const override;
78 int64_t evaluateAsInt64(int64_t
Value)
const;
86 : Kind(Kind), SubExpr(Expr), Negated(Negated) {}
87 ~AVRMCExpr() =
default;
92 #endif // LLVM_AVR_MCEXPR_H
@ VK_AVR_PM_HI8
Corresponds to pm_hi8().
This is an optimization pass for GlobalISel generic memory operations.
static VariantKind getKindByName(StringRef Name)
@ VK_AVR_HH8
Corresponds to hlo8() and hh8().
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 fixELFSymbolsInTLSFixups(MCAssembler &Asm) const override
@ VK_AVR_LO8
Corresponds to lo8().
Streaming machine code generation interface.
static GCRegistry::Add< CoreCLRGC > E("coreclr", "CoreCLR-compatible GC")
@ Target
Target specific expression.
VariantKind getKind() const
Gets the type of the expression.
This class implements an extremely fast bulk output stream that can only output to a stream.
A expression in AVR machine code.
const MCExpr * getSubExpr() const
@ VK_AVR_HI8_GS
Corresponds to hi8(gs()).
static const AVRMCExpr * create(VariantKind Kind, const MCExpr *Expr, bool isNegated, MCContext &Ctx)
Creates an AVR machine code expression.
@ VK_AVR_GS
Corresponds to gs().
AVR::Fixups getFixupKind() const
Gets the fixup which corresponds to the expression.
MCFragment * findAssociatedFragment() const override
const char * getName() const
Gets the name of the expression.
bool evaluateAsRelocatableImpl(MCValue &Res, const MCAsmLayout *Layout, const MCFixup *Fixup) const override
@ VK_AVR_PM
Corresponds to pm(), reference to program memory.
StringRef - Represent a constant reference to a string, i.e.
@ VK_AVR_LO8_GS
Corresponds to lo8(gs()).
static bool classof(const MCExpr *E)
void printImpl(raw_ostream &OS, const MCAsmInfo *MAI) const override
Fixups
The set of supported fixups.
Encapsulates the layout of an assembly file at a particular point in time.
VariantKind
Specifies the type of an expression.
void visitUsedExpr(MCStreamer &streamer) const override
@ VK_AVR_PM_HH8
Corresponds to pm_hh8().
MCFragment * findAssociatedFragment() const
Find the "associated section" for this expression, which is currently defined as the absolute section...
bool evaluateAsConstant(int64_t &Result) const
Evaluates the fixup as a constant value.
This represents an "assembler immediate".
void setNegated(bool negated=true)
@ VK_AVR_HI8
Corresponds to hi8().
This is an extension point for target-specific MCExpr subclasses to implement.
Encode information on a single operation to perform on a byte sequence (e.g., an encoded instruction)...
LLVM Value Representation.
Base class for the full range of assembler expressions which are needed for parsing.
@ VK_AVR_HHI8
Corresponds to hhi8().
@ VK_AVR_PM_LO8
Corresponds to pm_lo8().