36 return ConstantPools->addEntry(
Streamer, Expr, 4, Loc);
40 ConstantPools->emitForCurrentSection(
Streamer);
41 ConstantPools->clearCacheForCurrentSection(
Streamer);
61 for (
unsigned II = 0, IE =
Size;
II != IE;
II++) {
62 const unsigned I = LittleEndian ? (
Size -
II - 1) :
II;
63 Buffer[
Size -
II - 1] = uint8_t(Inst >>
I * CHAR_BIT);
69 Size = (Suffix ==
'n' ? 2 : 4);
73 for (
unsigned II = 0, IE =
Size;
II != IE;
II =
II + 2) {
74 const unsigned I0 = LittleEndian ?
II + 0 :
II + 1;
75 const unsigned I1 = LittleEndian ?
II + 1 :
II + 0;
76 Buffer[
Size -
II - 2] = uint8_t(Inst >> I0 * CHAR_BIT);
77 Buffer[
Size -
II - 1] = uint8_t(Inst >> I1 * CHAR_BIT);
132 if (STI.
getCPU() ==
"xscale")
141 }
else if (STI.
hasFeature(ARM::HasV8_1MMainlineOps))
143 else if (STI.
hasFeature(ARM::HasV8MMainlineOps))
151 else if (STI.
hasFeature(ARM::HasV8MBaselineOps))
169 return (STI.
hasFeature(ARM::HasV8MBaselineOps) &&
199 }
else if (STI.
hasFeature(ARM::FeatureRClass)) {
202 }
else if (STI.
hasFeature(ARM::FeatureMClass)) {
214 }
else if (STI.
hasFeature(ARM::FeatureThumb2)) {
226 emitFPU(ARM::FK_CRYPTO_NEON_FP_ARMV8);
228 emitFPU(ARM::FK_NEON_FP_ARMV8);
241 if (STI.
hasFeature(ARM::FeatureFPARMv8_D16_SP)) {
248 : ARM::FK_FPV5_SP_D16);
252 }
else if (STI.
hasFeature(ARM::FeatureVFP4_D16_SP))
255 : (STI.
hasFeature(ARM::FeatureFP64) ? ARM::FK_VFPV4_D16
256 : ARM::FK_FPV4_SP_D16));
257 else if (STI.
hasFeature(ARM::FeatureVFP3_D16_SP))
261 ? (STI.
hasFeature(ARM::FeatureFP16) ? ARM::FK_VFPV3_FP16
266 ? ARM::FK_VFPV3_D16_FP16
268 : (STI.
hasFeature(ARM::FeatureFP16) ? ARM::FK_VFPV3XD_FP16
269 : ARM::FK_VFPV3XD)));
287 else if (STI.
hasFeature(ARM::HasMVEIntegerOps))
313 else if (STI.
hasFeature(ARM::FeatureTrustZone))
315 else if (STI.
hasFeature(ARM::FeatureVirtualization))
328 if (TT.isOSBinFormatELF())
330 if (TT.isOSBinFormatCOFF())
static bool isV8M(const MCSubtargetInfo &STI)
static ARMBuildAttrs::CPUArch getArchForCPU(const MCSubtargetInfo &STI)
uint64_t IntrinsicInst * II
virtual void emitUnwindRaw(int64_t StackOffset, const SmallVectorImpl< uint8_t > &Opcodes)
~ARMTargetStreamer() override
void emitTargetAttributes(const MCSubtargetInfo &STI)
Emit the build attributes that only depend on the hardware that we expect.
virtual void reset()
Reset any state between object emissions, i.e.
virtual void annotateTLSDescriptorSequence(const MCSymbolRefExpr *SRE)
virtual void finishAttributeSection()
ARMTargetStreamer(MCStreamer &S)
virtual void emitARMWinCFISaveSP(unsigned Reg)
virtual void emitPersonalityIndex(unsigned Index)
virtual void emitInst(uint32_t Inst, char Suffix='\0')
virtual void emitARMWinCFISaveLR(unsigned Offset)
virtual void emitArchExtension(uint64_t ArchExt)
virtual void emitRegSave(const SmallVectorImpl< unsigned > &RegList, bool isVector)
virtual void emitTextAttribute(unsigned Attribute, StringRef String)
virtual void emitARMWinCFIAllocStack(unsigned Size, bool Wide)
virtual void emitMovSP(unsigned Reg, int64_t Offset=0)
virtual void emitARMWinCFICustom(unsigned Opcode)
virtual void emitARMWinCFISaveRegMask(unsigned Mask, bool Wide)
virtual void emitARMWinCFIEpilogEnd()
virtual void emitARMWinCFIPrologEnd(bool Fragment)
virtual void switchVendor(StringRef Vendor)
virtual void emitFnStart()
virtual void emitPersonality(const MCSymbol *Personality)
virtual void emitObjectArch(ARM::ArchKind Arch)
const MCExpr * addConstantPoolEntry(const MCExpr *, SMLoc Loc)
Callback used to implement the ldr= pseudo.
virtual void emitHandlerData()
virtual void emitIntTextAttribute(unsigned Attribute, unsigned IntValue, StringRef StringValue="")
virtual void emitThumbSet(MCSymbol *Symbol, const MCExpr *Value)
virtual void emitFPU(ARM::FPUKind FPU)
virtual void emitCantUnwind()
virtual void emitARMWinCFISaveFRegs(unsigned First, unsigned Last)
virtual void emitARMWinCFIEpilogStart(unsigned Condition)
virtual void emitPad(int64_t Offset)
void emitCurrentConstantPool()
Callback used to implement the .ltorg directive.
virtual void emitAttribute(unsigned Attribute, unsigned Value)
virtual void emitARMWinCFINop(bool Wide)
virtual void emitSetFP(unsigned FpReg, unsigned SpReg, int64_t Offset=0)
void emitConstantPools() override
virtual void emitArch(ARM::ArchKind Arch)
bool isLittleEndian() const
True if the target is little endian.
const MCAsmInfo * getAsmInfo() const
Base class for the full range of assembler expressions which are needed for parsing.
Streaming machine code generation interface.
MCContext & getContext() const
virtual void emitBytes(StringRef Data)
Emit the bytes in Data into the output.
Generic base class for all target subtargets.
bool hasFeature(unsigned Feature) const
const Triple & getTargetTriple() const
Represent a reference to a symbol from inside an expression.
MCSymbol - Instances of this class represent a symbol name in the MC file, and MCSymbols are created ...
Target specific streamer interface.
MCStreamer & getStreamer()
Represents a location in source code.
This class consists of common code factored out of the SmallVector class to reduce code duplication b...
StackOffset holds a fixed and a scalable offset in bytes.
StringRef - Represent a constant reference to a string, i.e.
bool starts_with(StringRef Prefix) const
Check if this string starts with the given Prefix.
constexpr bool empty() const
empty - Check if the string is empty.
Triple - Helper class for working with autoconf configuration names.
LLVM Value Representation.
#define llvm_unreachable(msg)
Marks that the current location is not supposed to be reachable.
@ AllowMVEIntegerAndFloat
This is an optimization pass for GlobalISel generic memory operations.
MCTargetStreamer * createARMObjectTargetELFStreamer(MCStreamer &S)
@ First
Helpers to iterate all locations in the MemoryEffectsBase class.
MCTargetStreamer * createARMObjectTargetWinCOFFStreamer(MCStreamer &S)
MCTargetStreamer * createARMObjectTargetStreamer(MCStreamer &S, const MCSubtargetInfo &STI)