10 #ifndef LLVM_MC_MCFRAGMENT_H
11 #define LLVM_MC_MCFRAGMENT_H
23 class MCSubtargetInfo;
57 bool AlignToBundleEnd;
59 uint8_t BundlePadding;
84 uint8_t BundlePadding,
MCSection *Parent =
nullptr);
145 :
MCFragment(FType, HasInstructions, 0, Sec) {}
164 template<
unsigned ContentsSize>
182 template<
unsigned ContentsSize,
unsigned FixupsSize>
261 Inst(Inst), STI(STI) {}
291 unsigned MaxBytesToEmit;
295 unsigned MaxBytesToEmit,
MCSection *Sec =
nullptr)
297 EmitNops(
false), Value(Value),
298 ValueSize(ValueSize), MaxBytesToEmit(MaxBytesToEmit) {}
422 AddrDelta(&AddrDelta) {
496 unsigned StartFileId;
497 unsigned StartLineNum;
508 unsigned StartLineNum,
const MCSymbol *FnStartSym,
512 StartFileId(StartFileId), StartLineNum(StartLineNum),
513 FnStartSym(FnStartSym), FnEndSym(FnEndSym) {}
542 ArrayRef<std::pair<const MCSymbol *, const MCSymbol *>> Ranges,
545 Ranges(Ranges.
begin(), Ranges.
end()),
546 FixedSizePortion(FixedSizePortion) {}
uint8_t getBundlePadding() const
Get the padding size that must be inserted before this fragment.
Instances of this class represent a uniqued identifier for a section in the current translation unit...
void push_back(const T &Elt)
const_iterator end(StringRef path)
Get end iterator over path.
MCAlignFragment(unsigned Alignment, int64_t Value, unsigned ValueSize, unsigned MaxBytesToEmit, MCSection *Sec=nullptr)
MCOrgFragment(const MCExpr &Offset, int8_t Value, SMLoc Loc, MCSection *Sec=nullptr)
static bool classof(const MCFragment *F)
unsigned getValueSize() const
const MCSymbol * getFnStartSym() const
MCDwarfLineAddrFragment(int64_t LineDelta, const MCExpr &AddrDelta, MCSection *Sec=nullptr)
static bool classof(const MCFragment *F)
MCSymbol - Instances of this class represent a symbol name in the MC file, and MCSymbols are created ...
unsigned getAlignment() const
SmallString< 8 > & getContents()
static bool classof(const MCFragment *F)
const MCExpr & getAddrDelta() const
bool alignToBundleEnd() const
Should this fragment be placed at the end of an aligned bundle?
const MCSymbol * getFnEndSym() const
Interface implemented by fragments that contain encoded instructions and/or data. ...
MCCVDefRangeFragment(ArrayRef< std::pair< const MCSymbol *, const MCSymbol * >> Ranges, StringRef FixedSizePortion, MCSection *Sec=nullptr)
static bool classof(const MCFragment *F)
const_iterator begin(StringRef path)
Get begin iterator over path.
This is a compact (memory-size-wise) fragment for holding an encoded instruction (non-relaxable) that...
const MCSubtargetInfo & getSubtargetInfo()
MCFillFragment(uint8_t Value, uint64_t Size, MCSection *Sec=nullptr)
const MCExpr & getOffset() const
const MCInst & getInst() const
Interface implemented by fragments that contain encoded instructions and/or data. ...
fixup_iterator fixup_end()
const_fixup_iterator fixup_end() const
Encapsulates the layout of an assembly file at a particular point in time.
void setEmitNops(bool Value)
Base class for the full range of assembler expressions which are needed for parsing.
unsigned getMaxBytesToEmit() const
void setAlignToBundleEnd(bool V)
MCDummyFragment(MCSection *Sec)
int64_t getLineDelta() const
void destroy()
Destroys the current fragment.
void setHasInstructions(bool V)
static bool classof(const MCFragment *F)
static bool classof(const MCFragment *F)
Function Alias Analysis false
ArrayRef - Represent a constant reference to an array (0 or more elements consecutively in memory)...
const MCSymbol * getSymbol()
MCLEBFragment(const MCExpr &Value_, bool IsSigned_, MCSection *Sec=nullptr)
MCEncodedFragmentWithContents(MCFragment::FragmentType FType, bool HasInstructions, MCSection *Sec)
SmallVectorImpl< char > & getContents()
const MCExpr & getAddrDelta() const
MCSafeSEHFragment(const MCSymbol *Sym, MCSection *Sec=nullptr)
Instances of this class represent a single low-level machine instruction.
MCRelaxableFragment(const MCInst &Inst, const MCSubtargetInfo &STI, MCSection *Sec=nullptr)
A relaxable fragment holds on to its MCInst, since it may need to be relaxed during the assembler lay...
bool hasInstructions() const
Does this fragment have instructions emitted into it? By default this is false, but specific fragment...
An ilist node that can access its parent list.
static bool classof(const MCFragment *F)
const_fixup_iterator fixup_begin() const
static bool classof(const MCFragment *F)
bool isDummy() const
Return true if given frgment has FT_Dummy type.
FragmentType getKind() const
static bool classof(const MCFragment *F)
SmallVectorImpl< MCFixup > & getFixups()
MCEncodedFragment(MCFragment::FragmentType FType, bool HasInstructions, MCSection *Sec)
MCCVInlineLineTableFragment(unsigned SiteFuncId, unsigned StartFileId, unsigned StartLineNum, const MCSymbol *FnStartSym, const MCSymbol *FnEndSym, MCSection *Sec=nullptr)
static bool classof(const MCFragment *F)
const SmallString< 8 > & getContents() const
Fragment representing the .cv_def_range directive.
const SmallVectorImpl< char > & getContents() const
MCEncodedFragmentWithFixups(MCFragment::FragmentType FType, bool HasInstructions, MCSection *Sec)
StringRef getFixedSizePortion() const
MCCompactEncodedInstFragment(MCSection *Sec=nullptr)
MCSection * getParent() const
const SmallString< 8 > & getContents() const
ArrayRef< std::pair< const MCSymbol *, const MCSymbol * > > getRanges() const
SmallVectorImpl< MCFixup >::const_iterator const_fixup_iterator
SmallString< 8 > & getContents()
Fragment representing the binary annotations produced by the .cv_inline_linetable directive...
void setBundlePadding(uint8_t N)
Set the padding size for this fragment.
static bool classof(const MCFragment *F)
Interface implemented by fragments that contain encoded instructions and/or data and also have fixups...
const MCSymbol * getAtom() const
static bool classof(const MCFragment *F)
const SmallString< 8 > & getContents() const
static bool classof(const MCFragment *F)
fixup_iterator fixup_begin()
MCSubtargetInfo - Generic base class for all target subtargets.
SmallString< 8 > & getContents()
void setLayoutOrder(unsigned Value)
Fragment for data and encoded instructions.
const SmallVectorImpl< MCFixup > & getFixups() const
LLVM Value Representation.
const MCExpr & getValue() const
unsigned getLayoutOrder() const
static bool classof(const MCFragment *F)
StringRef - Represent a constant reference to a string, i.e.
SmallString< 8 > & getContents()
Represents a location in source code.
void setParent(MCSection *Value)
MCDataFragment(MCSection *Sec=nullptr)
MCDwarfCallFrameFragment(const MCExpr &AddrDelta, MCSection *Sec=nullptr)
const MCSymbol * getSymbol() const
SmallVectorImpl< MCFixup >::iterator fixup_iterator
void setInst(const MCInst &Value)
const SmallString< 8 > & getContents() const
void setAtom(const MCSymbol *Value)
Holds state from .cv_file and .cv_loc directives for later emission.
static bool classof(const MCFragment *F)