LLVM: llvm::MCStreamer Class Reference (original) (raw)
Streaming machine code generation interface. More...
#include "[llvm/MC/MCStreamer.h](MCStreamer%5F8h%5Fsource.html)"
| Public Member Functions | |
|---|---|
| MCStreamer (const MCStreamer &)=delete | |
| MCStreamer & | operator= (const MCStreamer &)=delete |
| virtual | ~MCStreamer () |
| void | visitUsedExpr (const MCExpr &Expr) |
| virtual void | visitUsedSymbol (const MCSymbol &Sym) |
| void | setTargetStreamer (MCTargetStreamer *TS) |
| void | setStartTokLocPtr (const SMLoc *Loc) |
| SMLoc | getStartTokLoc () const |
| virtual void | reset () |
| State management. | |
| MCContext & | getContext () const |
| bool | isObj () const |
| virtual MCAssembler * | getAssemblerPtr () |
| void | setUseAssemblerInfoForParsing (bool v) |
| bool | getUseAssemblerInfoForParsing () |
| MCTargetStreamer * | getTargetStreamer () |
| void | setAllowAutoPadding (bool v) |
| bool | getAllowAutoPadding () const |
| MCSymbol * | emitLineTableLabel () |
| virtual MCSymbol * | emitCFILabel () |
| When emitting an object file, create and emit a real label. | |
| WinEH::FrameInfo * | EnsureValidWinFrameInfo (SMLoc Loc) |
| Retrieve the current frame info if one is available and it is not yet closed. | |
| unsigned | getNumFrameInfos () |
| ArrayRef< MCDwarfFrameInfo > | getDwarfFrameInfos () const |
| bool | hasUnfinishedDwarfFrameInfo () |
| unsigned | getNumWinFrameInfos () |
| ArrayRef< std::unique_ptr< WinEH::FrameInfo > > | getWinFrameInfos () const |
| WinEH::FrameInfo::Epilog * | getCurrentWinEpilog () const |
| bool | isInEpilogCFI () const |
| void | generateCompactUnwindEncodings (MCAsmBackend *MAB) |
| virtual void | emitFileDirective (StringRef Filename) |
| Switch to a new logical file. | |
| virtual void | emitFileDirective (StringRef Filename, StringRef CompilerVersion, StringRef TimeStamp, StringRef Description) |
| Emit ".file assembler diretive with additioal info. | |
| virtual void | emitIdent (StringRef IdentString) |
| Emit the "identifiers" directive. | |
| unsigned | emitDwarfFileDirective (unsigned FileNo, StringRef Directory, StringRef Filename, std::optional< MD5::MD5Result > Checksum=std::nullopt, std::optional< StringRef > Source=std::nullopt, unsigned CUID=0) |
| Associate a filename with a specified logical file number. | |
| virtual Expected< unsigned > | tryEmitDwarfFileDirective (unsigned FileNo, StringRef Directory, StringRef Filename, std::optional< MD5::MD5Result > Checksum=std::nullopt, std::optional< StringRef > Source=std::nullopt, unsigned CUID=0) |
| Associate a filename with a specified logical file number. | |
| virtual void | emitDwarfFile0Directive (StringRef Directory, StringRef Filename, std::optional< MD5::MD5Result > Checksum, std::optional< StringRef > Source, unsigned CUID=0) |
| Specify the "root" file of the compilation, using the ".file 0" extension. | |
| virtual void | emitCFIBKeyFrame () |
| virtual void | emitCFIMTETaggedFrame () |
| virtual void | emitDwarfLocDirective (unsigned FileNo, unsigned Line, unsigned Column, unsigned Flags, unsigned Isa, unsigned Discriminator, StringRef FileName, StringRef Comment={}) |
| This implements the DWARF2 '.loc fileno lineno ...' assembler directive. | |
| virtual void | emitDwarfLocLabelDirective (SMLoc Loc, StringRef Name) |
| This implements the '.loc_label Name' directive. | |
| virtual bool | emitCVFileDirective (unsigned FileNo, StringRef Filename, ArrayRef< uint8_t > Checksum, unsigned ChecksumKind) |
| Associate a filename with a specified logical file number, and also specify that file's checksum information. | |
| virtual bool | emitCVFuncIdDirective (unsigned FunctionId) |
| Introduces a function id for use with .cv_loc. | |
| virtual bool | emitCVInlineSiteIdDirective (unsigned FunctionId, unsigned IAFunc, unsigned IAFile, unsigned IALine, unsigned IACol, SMLoc Loc) |
| Introduces an inline call site id for use with .cv_loc. | |
| virtual void | emitCVLocDirective (unsigned FunctionId, unsigned FileNo, unsigned Line, unsigned Column, bool PrologueEnd, bool IsStmt, StringRef FileName, SMLoc Loc) |
| This implements the CodeView '.cv_loc' assembler directive. | |
| virtual void | emitCVLinetableDirective (unsigned FunctionId, const MCSymbol *FnStart, const MCSymbol *FnEnd) |
| This implements the CodeView '.cv_linetable' assembler directive. | |
| virtual void | emitCVInlineLinetableDirective (unsigned PrimaryFunctionId, unsigned SourceFileId, unsigned SourceLineNum, const MCSymbol *FnStartSym, const MCSymbol *FnEndSym) |
| This implements the CodeView '.cv_inline_linetable' assembler directive. | |
| virtual void | emitCVDefRangeDirective (ArrayRef< std::pair< const MCSymbol *, const MCSymbol * > > Ranges, StringRef FixedSizePortion) |
| This implements the CodeView '.cv_def_range' assembler directive. | |
| virtual void | emitCVDefRangeDirective (ArrayRef< std::pair< const MCSymbol *, const MCSymbol * > > Ranges, codeview::DefRangeRegisterRelHeader DRHdr) |
| virtual void | emitCVDefRangeDirective (ArrayRef< std::pair< const MCSymbol *, const MCSymbol * > > Ranges, codeview::DefRangeSubfieldRegisterHeader DRHdr) |
| virtual void | emitCVDefRangeDirective (ArrayRef< std::pair< const MCSymbol *, const MCSymbol * > > Ranges, codeview::DefRangeRegisterHeader DRHdr) |
| virtual void | emitCVDefRangeDirective (ArrayRef< std::pair< const MCSymbol *, const MCSymbol * > > Ranges, codeview::DefRangeFramePointerRelHeader DRHdr) |
| virtual void | emitCVStringTableDirective () |
| This implements the CodeView '.cv_stringtable' assembler directive. | |
| virtual void | emitCVFileChecksumsDirective () |
| This implements the CodeView '.cv_filechecksums' assembler directive. | |
| virtual void | emitCVFileChecksumOffsetDirective (unsigned FileNo) |
| This implements the CodeView '.cv_filechecksumoffset' assembler directive. | |
| virtual void | emitCVFPOData (const MCSymbol *ProcSym, SMLoc Loc={}) |
| This implements the CodeView '.cv_fpo_data' assembler directive. | |
| virtual void | emitAbsoluteSymbolDiff (const MCSymbol *Hi, const MCSymbol *Lo, unsigned Size) |
| Emit the absolute difference between two symbols. | |
| virtual void | emitAbsoluteSymbolDiffAsULEB128 (const MCSymbol *Hi, const MCSymbol *Lo) |
| Emit the absolute difference between two symbols encoded with ULEB128. | |
| virtual MCSymbol * | getDwarfLineTableSymbol (unsigned CUID) |
| virtual void | emitCFISections (bool EH, bool Debug, bool SFrame) |
| void | emitCFIStartProc (bool IsSimple, SMLoc Loc=SMLoc()) |
| void | emitCFIEndProc () |
| virtual void | emitCFIDefCfa (int64_t Register, int64_t Offset, SMLoc Loc={}) |
| virtual void | emitCFIDefCfaOffset (int64_t Offset, SMLoc Loc={}) |
| virtual void | emitCFIDefCfaRegister (int64_t Register, SMLoc Loc={}) |
| virtual void | emitCFILLVMDefAspaceCfa (int64_t Register, int64_t Offset, int64_t AddressSpace, SMLoc Loc={}) |
| virtual void | emitCFIOffset (int64_t Register, int64_t Offset, SMLoc Loc={}) |
| virtual void | emitCFIPersonality (const MCSymbol *Sym, unsigned Encoding) |
| virtual void | emitCFILsda (const MCSymbol *Sym, unsigned Encoding) |
| virtual void | emitCFIRememberState (SMLoc Loc) |
| virtual void | emitCFIRestoreState (SMLoc Loc) |
| virtual void | emitCFISameValue (int64_t Register, SMLoc Loc={}) |
| virtual void | emitCFIRestore (int64_t Register, SMLoc Loc={}) |
| virtual void | emitCFIRelOffset (int64_t Register, int64_t Offset, SMLoc Loc) |
| virtual void | emitCFIAdjustCfaOffset (int64_t Adjustment, SMLoc Loc={}) |
| virtual void | emitCFIEscape (StringRef Values, SMLoc Loc={}) |
| virtual void | emitCFIReturnColumn (int64_t Register) |
| virtual void | emitCFIGnuArgsSize (int64_t Size, SMLoc Loc={}) |
| virtual void | emitCFISignalFrame () |
| virtual void | emitCFIUndefined (int64_t Register, SMLoc Loc={}) |
| virtual void | emitCFIRegister (int64_t Register1, int64_t Register2, SMLoc Loc={}) |
| virtual void | emitCFIWindowSave (SMLoc Loc={}) |
| virtual void | emitCFINegateRAState (SMLoc Loc={}) |
| virtual void | emitCFINegateRAStateWithPC (SMLoc Loc={}) |
| virtual void | emitCFILabelDirective (SMLoc Loc, StringRef Name) |
| virtual void | emitCFIValOffset (int64_t Register, int64_t Offset, SMLoc Loc={}) |
| virtual void | emitWinCFIStartProc (const MCSymbol *Symbol, SMLoc Loc=SMLoc()) |
| virtual void | emitWinCFIEndProc (SMLoc Loc=SMLoc()) |
| virtual void | emitWinCFIFuncletOrFuncEnd (SMLoc Loc=SMLoc()) |
| This is used on platforms, such as Windows on ARM64, that require function or funclet sizes to be emitted in .xdata before the End marker is emitted for the frame. | |
| virtual void | emitWinCFIStartChained (SMLoc Loc=SMLoc()) |
| virtual void | emitWinCFIEndChained (SMLoc Loc=SMLoc()) |
| virtual void | emitWinCFIPushReg (MCRegister Register, SMLoc Loc=SMLoc()) |
| virtual void | emitWinCFISetFrame (MCRegister Register, unsigned Offset, SMLoc Loc=SMLoc()) |
| virtual void | emitWinCFIAllocStack (unsigned Size, SMLoc Loc=SMLoc()) |
| virtual void | emitWinCFISaveReg (MCRegister Register, unsigned Offset, SMLoc Loc=SMLoc()) |
| virtual void | emitWinCFISaveXMM (MCRegister Register, unsigned Offset, SMLoc Loc=SMLoc()) |
| virtual void | emitWinCFIPushFrame (bool Code, SMLoc Loc=SMLoc()) |
| virtual void | emitWinCFIEndProlog (SMLoc Loc=SMLoc()) |
| virtual void | emitWinCFIBeginEpilogue (SMLoc Loc=SMLoc()) |
| virtual void | emitWinCFIEndEpilogue (SMLoc Loc=SMLoc()) |
| virtual void | emitWinCFIUnwindV2Start (SMLoc Loc=SMLoc()) |
| virtual void | emitWinCFIUnwindVersion (uint8_t Version, SMLoc Loc=SMLoc()) |
| virtual void | emitWinEHHandler (const MCSymbol *Sym, bool Unwind, bool Except, SMLoc Loc=SMLoc()) |
| virtual void | emitWinEHHandlerData (SMLoc Loc=SMLoc()) |
| virtual void | emitCGProfileEntry (const MCSymbolRefExpr *From, const MCSymbolRefExpr *To, uint64_t Count) |
| MCSection * | getAssociatedPDataSection (const MCSection *TextSec) |
| Get the .pdata section used for the given section. | |
| MCSection * | getAssociatedXDataSection (const MCSection *TextSec) |
| Get the .xdata section used for the given section. | |
| virtual void | emitSyntaxDirective () |
| virtual void | emitRelocDirective (const MCExpr &Offset, StringRef Name, const MCExpr *Expr, SMLoc Loc={}) |
| Record a relocation described by the .reloc directive. | |
| virtual void | emitAddrsig () |
| virtual void | emitAddrsigSym (const MCSymbol *Sym) |
| virtual void | emitInstruction (const MCInst &Inst, const MCSubtargetInfo &STI) |
| Emit the given Instruction into the current section. | |
| virtual void | emitPseudoProbe (uint64_t Guid, uint64_t Index, uint64_t Type, uint64_t Attr, uint64_t Discriminator, const MCPseudoProbeInlineStack &InlineStack, MCSymbol *FnSym) |
| Emit the a pseudo probe into the current section. | |
| void | emitRawText (const Twine &String) |
| If this file is backed by a assembly streamer, this dumps the specified string in the output .s file. | |
| virtual void | finishImpl () |
| Streamer specific finalization. | |
| void | finish (SMLoc EndLoc=SMLoc()) |
| Finish emission of machine code. | |
| virtual bool | mayHaveInstructions (MCSection &Sec) const |
| void | maybeEmitDwarf64Mark () |
| Emit a special value of 0xffffffff if producing 64-bit debugging info. | |
| virtual void | emitDwarfUnitLength (uint64_t Length, const Twine &Comment) |
| Emit a unit length field. | |
| virtual MCSymbol * | emitDwarfUnitLength (const Twine &Prefix, const Twine &Comment) |
| Emit a unit length field. | |
| virtual void | emitDwarfLineStartLabel (MCSymbol *StartSym) |
| Emit the debug line start label. | |
| virtual void | emitDwarfLineEndEntry (MCSection *Section, MCSymbol *LastLabel, MCSymbol *EndLabel=nullptr) |
| Emit the debug line end entry. | |
| virtual void | emitDwarfAdvanceLineAddr (int64_t LineDelta, const MCSymbol *LastLabel, const MCSymbol *Label, unsigned PointerSize) |
| If targets does not support representing debug line section by .loc/.file directives in assembly output, we need to populate debug line section with raw debug line contents. | |
| Assembly File Formatting. | |
| virtual bool | isVerboseAsm () const |
| Return true if this streamer supports verbose assembly and if it is enabled. | |
| virtual bool | hasRawTextSupport () const |
| Return true if this asm streamer supports emitting unformatted text to the .s file with EmitRawText. | |
| virtual bool | isIntegratedAssemblerRequired () const |
| Is the integrated assembler required for this streamer to function correctly? | |
| virtual void | AddComment (const Twine &T, bool EOL=true) |
| Add a textual comment. | |
| virtual raw_ostream & | getCommentOS () |
| Return a raw_ostream that comments can be written to. | |
| virtual void | emitRawComment (const Twine &T, bool TabPrefix=true) |
| Print T and prefix it with the comment string (normally #) and optionally a tab. | |
| virtual void | addExplicitComment (const Twine &T) |
| Add explicit comment T. | |
| virtual void | emitExplicitComments () |
| Emit added explicit comments. | |
| virtual void | addBlankLine () |
| Emit a blank line to a .s file to pretty it up. | |
| Symbol & Section Management | |
| MCSectionSubPair | getCurrentSection () const |
| Return the current section that the streamer is emitting code to. | |
| MCSection * | getCurrentSectionOnly () const |
| MCSectionSubPair | getPreviousSection () const |
| Return the previous section that the streamer is emitting code to. | |
| MCFragment * | getCurrentFragment () const |
| size_t | getCurFragSize () const |
| void | pushSection () |
| Save the current and previous section on the section stack. | |
| virtual bool | popSection () |
| Restore the current and previous section from the section stack. | |
| virtual void | switchSection (MCSection *Section, uint32_t Subsec=0) |
| Set the current section where code is being emitted to Section. | |
| bool | switchSection (MCSection *Section, const MCExpr *) |
| void | switchSectionNoPrint (MCSection *Section) |
| Similar to switchSection, but does not print the section directive. | |
| virtual void | initSections (bool NoExecStack, const MCSubtargetInfo &STI) |
| Create the default sections and set the initial one. | |
| MCSymbol * | endSection (MCSection *Section) |
| virtual StringRef | getMnemonic (const MCInst &MI) const |
| Returns the mnemonic for MI, if the streamer has access to a instruction printer and returns an empty string otherwise. | |
| virtual void | emitLabel (MCSymbol *Symbol, SMLoc Loc=SMLoc()) |
| Emit a label for Symbol into the current section. | |
| virtual void | emitEHSymAttributes (const MCSymbol *Symbol, MCSymbol *EHSymbol) |
| virtual void | emitSubsectionsViaSymbols () |
| Emit a .subsection_via_symbols directive. | |
| virtual void | emitLinkerOptions (ArrayRef< std::string > Kind) |
| Emit the given list Options of strings as linker options into the output. | |
| virtual void | emitDataRegion (MCDataRegionType Kind) |
| Note in the output the specified region Kind. | |
| virtual void | emitVersionMin (MCVersionMinType Type, unsigned Major, unsigned Minor, unsigned Update, VersionTuple SDKVersion) |
| Specify the Mach-O minimum deployment target version. | |
| virtual void | emitBuildVersion (unsigned Platform, unsigned Major, unsigned Minor, unsigned Update, VersionTuple SDKVersion) |
| Emit/Specify Mach-O build version command. | |
| virtual void | emitDarwinTargetVariantBuildVersion (unsigned Platform, unsigned Major, unsigned Minor, unsigned Update, VersionTuple SDKVersion) |
| void | emitVersionForTarget (const Triple &Target, const VersionTuple &SDKVersion, const Triple *DarwinTargetVariantTriple, const VersionTuple &DarwinTargetVariantSDKVersion) |
| virtual void | emitAssignment (MCSymbol *Symbol, const MCExpr *Value) |
| Emit an assignment of Value to Symbol. | |
| virtual void | emitConditionalAssignment (MCSymbol *Symbol, const MCExpr *Value) |
| Emit an assignment of Value to Symbol, but only if Value is also emitted. | |
| virtual void | emitWeakReference (MCSymbol *Alias, const MCSymbol *Symbol) |
| Emit an weak reference from Alias to Symbol. | |
| virtual bool | emitSymbolAttribute (MCSymbol *Symbol, MCSymbolAttr Attribute)=0 |
| Add the given Attribute to Symbol. | |
| virtual void | emitSymbolDesc (MCSymbol *Symbol, unsigned DescValue) |
| Set the DescValue for the Symbol. | |
| virtual void | beginCOFFSymbolDef (const MCSymbol *Symbol) |
| Start emitting COFF symbol definition. | |
| virtual void | emitCOFFSymbolStorageClass (int StorageClass) |
| Emit the storage class of the symbol. | |
| virtual void | emitCOFFSymbolType (int Type) |
| Emit the type of the symbol. | |
| virtual void | endCOFFSymbolDef () |
| Marks the end of the symbol definition. | |
| virtual void | emitCOFFSafeSEH (MCSymbol const *Symbol) |
| virtual void | emitCOFFSymbolIndex (MCSymbol const *Symbol) |
| Emits the symbol table index of a Symbol into the current section. | |
| virtual void | emitCOFFSectionIndex (MCSymbol const *Symbol) |
| Emits a COFF section index. | |
| virtual void | emitCOFFSecRel32 (MCSymbol const *Symbol, uint64_t Offset) |
| Emits a COFF section relative relocation. | |
| virtual void | emitCOFFImgRel32 (MCSymbol const *Symbol, int64_t Offset) |
| Emits a COFF image relative relocation. | |
| virtual void | emitCOFFSecNumber (MCSymbol const *Symbol) |
| Emits the physical number of the section containing the given symbol as assigned during object writing (i.e., this is not a runtime relocation). | |
| virtual void | emitCOFFSecOffset (MCSymbol const *Symbol) |
| Emits the offset of the symbol from the beginning of the section during object writing (i.e., this is not a runtime relocation). | |
| virtual void | emitXCOFFLocalCommonSymbol (MCSymbol *LabelSym, uint64_t Size, MCSymbol *CsectSym, Align Alignment) |
| Emits an lcomm directive with XCOFF csect information. | |
| virtual void | emitXCOFFSymbolLinkageWithVisibility (MCSymbol *Symbol, MCSymbolAttr Linkage, MCSymbolAttr Visibility) |
| Emit a symbol's linkage and visibility with a linkage directive for XCOFF. | |
| virtual void | emitXCOFFRenameDirective (const MCSymbol *Name, StringRef Rename) |
| Emit a XCOFF .rename directive which creates a synonym for an illegal or undesirable name. | |
| virtual void | emitXCOFFExceptDirective (const MCSymbol *Symbol, const MCSymbol *Trap, unsigned Lang, unsigned Reason, unsigned FunctionSize, bool hasDebug) |
| Emit an XCOFF .except directive which adds information about a trap instruction to the object file exception section. | |
| virtual void | emitXCOFFRefDirective (const MCSymbol *Symbol) |
| Emit a XCOFF .ref directive which creates R_REF type entry in the relocation table for one or more symbols. | |
| virtual void | emitXCOFFCInfoSym (StringRef Name, StringRef Metadata) |
| Emit a C_INFO symbol with XCOFF embedded metadata to the .info section. | |
| virtual void | emitELFSize (MCSymbol *Symbol, const MCExpr *Value) |
| Emit an ELF .size directive. | |
| virtual void | emitELFSymverDirective (const MCSymbol *OriginalSym, StringRef Name, bool KeepOriginalSym) |
| Emit an ELF .symver directive. | |
| virtual void | emitLOHDirective (MCLOHType Kind, const MCLOHArgs &Args) |
| Emit a Linker Optimization Hint (LOH) directive. | |
| virtual void | emitGNUAttribute (unsigned Tag, unsigned Value) |
| Emit a .gnu_attribute directive. | |
| virtual void | emitCommonSymbol (MCSymbol *Symbol, uint64_t Size, Align ByteAlignment)=0 |
| Emit a common symbol. | |
| virtual void | emitLocalCommonSymbol (MCSymbol *Symbol, uint64_t Size, Align ByteAlignment) |
| Emit a local common (.lcomm) symbol. | |
| virtual void | emitZerofill (MCSection *Section, MCSymbol *Symbol=nullptr, uint64_t Size=0, Align ByteAlignment=Align(1), SMLoc Loc=SMLoc()) |
| Emit the zerofill section and an optional symbol. | |
| virtual void | emitTBSSSymbol (MCSection *Section, MCSymbol *Symbol, uint64_t Size, Align ByteAlignment=Align(1)) |
| Emit a thread local bss (.tbss) symbol. | |
| Generating Data | |
| virtual void | emitBytes (StringRef Data) |
| Emit the bytes in Data into the output. | |
| virtual void | emitBinaryData (StringRef Data) |
| Functionally identical to EmitBytes. | |
| virtual void | emitValueImpl (const MCExpr *Value, unsigned Size, SMLoc Loc=SMLoc()) |
| Emit the expression Value into the output as a native integer of the given Size bytes. | |
| void | emitValue (const MCExpr *Value, unsigned Size, SMLoc Loc=SMLoc()) |
| virtual void | emitIntValue (uint64_t Value, unsigned Size) |
| Special case of EmitValue that avoids the client having to pass in a MCExpr for constant integers. | |
| virtual void | emitIntValue (const APInt &Value) |
| virtual void | emitIntValueInHex (uint64_t Value, unsigned Size) |
| Special case of EmitValue that avoids the client having to pass in a MCExpr for constant integers & prints in Hex format for certain modes. | |
| void | emitInt8 (uint64_t Value) |
| void | emitInt16 (uint64_t Value) |
| void | emitInt32 (uint64_t Value) |
| void | emitInt64 (uint64_t Value) |
| virtual void | emitIntValueInHexWithPadding (uint64_t Value, unsigned Size) |
| Special case of EmitValue that avoids the client having to pass in a MCExpr for constant integers & prints in Hex format for certain modes, pads the field with leading zeros to Size width. | |
| virtual void | emitULEB128Value (const MCExpr *Value) |
| virtual void | emitSLEB128Value (const MCExpr *Value) |
| unsigned | emitULEB128IntValue (uint64_t Value, unsigned PadTo=0) |
| Special case of EmitULEB128Value that avoids the client having to pass in a MCExpr for constant integers. | |
| unsigned | emitSLEB128IntValue (int64_t Value) |
| Special case of EmitSLEB128Value that avoids the client having to pass in a MCExpr for constant integers. | |
| void | emitSymbolValue (const MCSymbol *Sym, unsigned Size, bool IsSectionRelative=false) |
| Special case of EmitValue that avoids the client having to pass in a MCExpr for MCSymbols. | |
| void | emitFill (uint64_t NumBytes, uint8_t FillValue) |
| Emit NumBytes bytes worth of the value specified by FillValue. | |
| virtual void | emitFill (const MCExpr &NumBytes, uint64_t FillValue, SMLoc Loc=SMLoc()) |
| Emit Size bytes worth of the value specified by FillValue. | |
| virtual void | emitFill (const MCExpr &NumValues, int64_t Size, int64_t Expr, SMLoc Loc=SMLoc()) |
| Emit NumValues copies of Size bytes. | |
| virtual void | emitNops (int64_t NumBytes, int64_t ControlledNopLength, SMLoc Loc, const MCSubtargetInfo &STI) |
| void | emitZeros (uint64_t NumBytes) |
| Emit NumBytes worth of zeros. | |
| virtual void | emitValueToAlignment (Align Alignment, int64_t Fill=0, uint8_t FillLen=1, unsigned MaxBytesToEmit=0) |
| Emit some number of copies of Value until the byte alignment ByteAlignment is reached. | |
| virtual void | emitCodeAlignment (Align Alignment, const MCSubtargetInfo *STI, unsigned MaxBytesToEmit=0) |
| Emit nops until the byte alignment ByteAlignment is reached. | |
| virtual void | emitValueToOffset (const MCExpr *Offset, unsigned char Value, SMLoc Loc) |
| Emit some number of copies of Value until the byte offset Offset is reached. |
| Protected Member Functions | |
|---|---|
| MCStreamer (MCContext &Ctx) | |
| virtual void | changeSection (MCSection *, uint32_t) |
| This is called by popSection and switchSection, if the current section changes. | |
| void | addFragment (MCFragment *F) |
| virtual void | emitCFIStartProcImpl (MCDwarfFrameInfo &Frame) |
| virtual void | emitCFIEndProcImpl (MCDwarfFrameInfo &CurFrame) |
| WinEH::FrameInfo * | getCurrentWinFrameInfo () |
| virtual void | emitWindowsUnwindTables (WinEH::FrameInfo *Frame) |
| virtual void | emitWindowsUnwindTables () |
| virtual void | emitRawTextImpl (StringRef String) |
| EmitRawText - If this file is backed by an assembly streamer, this dumps the specified string in the output .s file. | |
| bool | checkCVLocSection (unsigned FuncId, unsigned FileNo, SMLoc Loc) |
| Returns true if the .cv_loc directive is in the right section. |
Streaming machine code generation interface.
This interface is intended to provide a programmatic interface that is very similar to the level that an assembler .s file provides. It has callbacks to emit bytes, handle directives, etc. The implementation of this interface retains state to know what the current section is etc.
There are multiple implementations of this interface: one for writing out a .s file, and implementations that write out .o files of various formats.
Definition at line 220 of file MCStreamer.h.
| MCStreamer::MCStreamer ( MCContext & Ctx) | protected |
|---|
◆ MCStreamer() [2/2]
◆ ~MCStreamer()
| MCStreamer::~MCStreamer ( ) | virtualdefault |
|---|
◆ addBlankLine()
| virtual void llvm::MCStreamer::addBlankLine ( ) | inlinevirtual |
|---|
◆ AddComment()
| virtual void llvm::MCStreamer::AddComment ( const Twine & T, bool EOL = true ) | inlinevirtual |
|---|
Add a textual comment.
Typically for comments that can be emitted to the generated .s file if applicable as a QoI issue to make the output of the compiler more readable. This only affects the MCAsmStreamer, and only when verbose assembly output is enabled.
If the comment includes embedded
's, they will each get the comment prefix as appropriate. The added comment should not end with a
. By default, each comment is terminated with an end of line, i.e. the EOL param is set to true by default. If one prefers not to end the comment with a new line then the EOL param should be passed with a false value.
Reimplemented in llvm::SystemZHLASMAsmStreamer.
Definition at line 387 of file MCStreamer.h.
References T.
Referenced by addConstantComments(), emitDwarfUnitLength(), emitDwarfUnitLength(), emitGenDwarfRanges(), llvm::CodeViewContext::emitLineTableForFunction(), llvm::mcdwarf::emitListsTableHeaderStart(), llvm::BTFTypeBase::emitType(), llvm::BTFTypeEnum64::emitType(), llvm::BTFTypeInt::emitType(), llvm::BTFTypeStruct::emitType(), maybeEmitDwarf64Mark(), printBroadcast(), printExtend(), printZeroExtend(), and printZeroUpperMove().
◆ addExplicitComment()
| void MCStreamer::addExplicitComment ( const Twine & T) | virtual |
|---|
Add explicit comment T.
T is required to be a valid comment in the output and does not need to be escaped.
Definition at line 121 of file MCStreamer.cpp.
References T.
◆ addFragment()
| void MCStreamer::addFragment ( MCFragment * F) | protected |
|---|
◆ beginCOFFSymbolDef()
| void MCStreamer::beginCOFFSymbolDef ( const MCSymbol * Symbol) | virtual |
|---|
◆ changeSection()
This is called by popSection and switchSection, if the current section changes.
Reimplemented in llvm::MCELFStreamer, llvm::MCGOFFStreamer, llvm::MCObjectStreamer, llvm::MCWasmStreamer, llvm::MCWinCOFFStreamer, llvm::MCXCOFFStreamer, llvm::RISCVELFStreamer, and llvm::SystemZHLASMAsmStreamer.
Definition at line 1317 of file MCStreamer.cpp.
References CurFrag, emitLabel(), llvm::MCSection::getBeginSymbol(), getContext(), llvm::MCSection::getDummyFragment(), and llvm::MCContext::IsMachO.
Referenced by llvm::SystemZHLASMAsmStreamer::changeSection(), popSection(), switchSection(), and switchSectionNoPrint().
◆ checkCVLocSection()
◆ emitAbsoluteSymbolDiff()
Emit the absolute difference between two symbols.
Precondition
Offset of Hi is greater than the offset Lo.
Reimplemented in llvm::MCObjectStreamer.
Definition at line 1222 of file MCStreamer.cpp.
References llvm::MCSymbolRefExpr::create(), llvm::MCBinaryExpr::createSub(), llvm::MCAsmInfo::doesSetDirectiveSuppressReloc(), emitAssignment(), emitSymbolValue(), emitValue(), llvm::Hi, llvm::Lo, and Size.
Referenced by llvm::MCDwarfLineTableHeader::Emit(), llvm::MCObjectStreamer::emitAbsoluteSymbolDiff(), emitDwarfUnitLength(), and llvm::mcdwarf::emitListsTableHeaderStart().
◆ emitAbsoluteSymbolDiffAsULEB128()
◆ emitAddrsig()
| virtual void llvm::MCStreamer::emitAddrsig ( ) | inlinevirtual |
|---|
◆ emitAddrsigSym()
| virtual void llvm::MCStreamer::emitAddrsigSym ( const MCSymbol * Sym) | inlinevirtual |
|---|
◆ emitAssignment()
Emit an assignment of [Value](classllvm%5F1%5F1Value.html "LLVM Value Representation.") to Symbol.
This corresponds to an assembler statement such as: symbol = value
The assignment generates no code, but has the side effect of binding the value in the current context. For the assembly streamer, this prints the binding into the .s file.
Parameters
| Symbol | - The symbol being assigned to. |
|---|---|
| Value | - The value for the symbol. |
Reimplemented in llvm::MCObjectStreamer, and llvm::RecordStreamer.
Definition at line 1146 of file MCStreamer.cpp.
References llvm::MCTargetStreamer::emitAssignment(), getTargetStreamer(), and visitUsedExpr().
Referenced by emitAbsoluteSymbolDiff(), llvm::MCObjectStreamer::emitAssignment(), llvm::RecordStreamer::emitAssignment(), llvm::RecordStreamer::flushSymverDirectives(), forceExpAbs(), and llvm::MCContext::setSymbolValue().
◆ emitBinaryData()
| void MCStreamer::emitBinaryData ( StringRef Data) | virtual |
|---|
◆ emitBuildVersion()
◆ emitBytes()
| void MCStreamer::emitBytes ( StringRef Data) | virtual |
|---|
Emit the bytes in Data into the output.
This is used to implement assembler directives such as .byte, .ascii, etc.
Reimplemented in llvm::CSKYELFStreamer, llvm::MCObjectStreamer, llvm::RISCVELFStreamer, and llvm::SystemZHLASMAsmStreamer.
Definition at line 1331 of file MCStreamer.cpp.
References llvm::Data.
Referenced by addAllTypesFromDWP(), addAllTypesFromTypesSection(), llvm::MCDwarfLineAddr::Emit(), emitBinaryData(), emitCommonSymbol(), EmitGenDwarfInfo(), llvm::AArch64TargetStreamer::emitInst(), llvm::ARMTargetStreamer::emitInst(), emitIntValue(), emitIntValue(), llvm::AMDGPU::AMDGPUMCKernelCodeT::EmitKernelCodeT(), llvm::TargetLoweringObjectFileCOFF::emitLinkerDirectives(), llvm::TargetLoweringObjectFileELF::emitLinkerDirectives(), llvm::TargetLoweringObjectFileELF::emitModuleMetadata(), emitNop(), llvm::RISCVTargetStreamer::emitNoteGnuPropertySection(), llvm::AArch64TargetStreamer::emitNoteSection(), emitNullTerminatedSymbolName(), emitOneV5FileEntry(), llvm::TargetLoweringObjectFile::emitPseudoProbeDescMetadata(), emitSLEB128IntValue(), emitULEB128IntValue(), llvm::handleSection(), llvm::write(), and llvm::writeStringsAndOffsets().
◆ emitCFIAdjustCfaOffset()
| void MCStreamer::emitCFIAdjustCfaOffset ( int64_t Adjustment, SMLoc Loc = {} ) | virtual |
|---|
◆ emitCFIBKeyFrame()
| void MCStreamer::emitCFIBKeyFrame ( ) | virtual |
|---|
◆ emitCFIDefCfa()
| void MCStreamer::emitCFIDefCfa ( int64_t Register, int64_t Offset, SMLoc Loc = {} ) | virtual |
|---|
◆ emitCFIDefCfaOffset()
| void MCStreamer::emitCFIDefCfaOffset ( int64_t Offset, SMLoc Loc = {} ) | virtual |
|---|
◆ emitCFIDefCfaRegister()
| void MCStreamer::emitCFIDefCfaRegister ( int64_t Register, SMLoc Loc = {} ) | virtual |
|---|
◆ emitCFIEndProc()
| void MCStreamer::emitCFIEndProc | ( | ) |
|---|
◆ emitCFIEndProcImpl()
| void MCStreamer::emitCFIEndProcImpl ( MCDwarfFrameInfo & CurFrame) | protectedvirtual |
|---|
◆ emitCFIEscape()
◆ emitCFIGnuArgsSize()
| void MCStreamer::emitCFIGnuArgsSize ( int64_t Size, SMLoc Loc = {} ) | virtual |
|---|
◆ emitCFILabel()
| MCSymbol * MCStreamer::emitCFILabel ( ) | virtual |
|---|
When emitting an object file, create and emit a real label.
When emitting textual assembly, this should do nothing to avoid polluting our output.
Reimplemented in llvm::MCObjectStreamer, and llvm::MipsELFStreamer.
Definition at line 475 of file MCStreamer.cpp.
Referenced by emitCFIAdjustCfaOffset(), emitCFIDefCfa(), emitCFIDefCfaOffset(), emitCFIDefCfaRegister(), emitCFIEscape(), emitCFIGnuArgsSize(), emitCFILabelDirective(), emitCFILLVMDefAspaceCfa(), emitCFINegateRAState(), emitCFINegateRAStateWithPC(), emitCFIOffset(), emitCFIRegister(), emitCFIRelOffset(), emitCFIRememberState(), emitCFIRestore(), emitCFIRestoreState(), emitCFISameValue(), emitCFIUndefined(), emitCFIValOffset(), emitCFIWindowSave(), llvm::Win64EH::ARM64UnwindEmitter::EmitUnwindInfo(), llvm::Win64EH::ARMUnwindEmitter::EmitUnwindInfo(), emitWinCFIAllocStack(), emitWinCFIBeginEpilogue(), emitWinCFIEndChained(), emitWinCFIEndEpilogue(), emitWinCFIEndProc(), emitWinCFIEndProlog(), emitWinCFIFuncletOrFuncEnd(), emitWinCFIPushFrame(), emitWinCFIPushReg(), emitWinCFISaveReg(), emitWinCFISaveXMM(), emitWinCFISetFrame(), emitWinCFIStartProc(), and emitWinCFIUnwindV2Start().
◆ emitCFILabelDirective()
◆ emitCFILLVMDefAspaceCfa()
| void MCStreamer::emitCFILLVMDefAspaceCfa ( int64_t Register, int64_t Offset, int64_t AddressSpace, SMLoc Loc = {} ) | virtual |
|---|
◆ emitCFILsda()
◆ emitCFIMTETaggedFrame()
| void MCStreamer::emitCFIMTETaggedFrame ( ) | virtual |
|---|
◆ emitCFINegateRAState()
| void MCStreamer::emitCFINegateRAState ( SMLoc Loc = {}) | virtual |
|---|
◆ emitCFINegateRAStateWithPC()
| void MCStreamer::emitCFINegateRAStateWithPC ( SMLoc Loc = {}) | virtual |
|---|
◆ emitCFIOffset()
| void MCStreamer::emitCFIOffset ( int64_t Register, int64_t Offset, SMLoc Loc = {} ) | virtual |
|---|
◆ emitCFIPersonality()
◆ emitCFIRegister()
| void MCStreamer::emitCFIRegister ( int64_t Register1, int64_t Register2, SMLoc Loc = {} ) | virtual |
|---|
◆ emitCFIRelOffset()
| void MCStreamer::emitCFIRelOffset ( int64_t Register, int64_t Offset, SMLoc Loc ) | virtual |
|---|
◆ emitCFIRememberState()
| void MCStreamer::emitCFIRememberState ( SMLoc Loc) | virtual |
|---|
◆ emitCFIRestore()
| void MCStreamer::emitCFIRestore ( int64_t Register, SMLoc Loc = {} ) | virtual |
|---|
◆ emitCFIRestoreState()
| void MCStreamer::emitCFIRestoreState ( SMLoc Loc) | virtual |
|---|
◆ emitCFIReturnColumn()
| void MCStreamer::emitCFIReturnColumn ( int64_t Register) | virtual |
|---|
◆ emitCFISameValue()
| void MCStreamer::emitCFISameValue ( int64_t Register, SMLoc Loc = {} ) | virtual |
|---|
◆ emitCFISections()
| void MCStreamer::emitCFISections ( bool EH, bool Debug, bool SFrame ) | virtual |
|---|
◆ emitCFISignalFrame()
| void MCStreamer::emitCFISignalFrame ( ) | virtual |
|---|
◆ emitCFIStartProc()
| void MCStreamer::emitCFIStartProc | ( | bool | IsSimple, |
|---|---|---|---|
| SMLoc | Loc = SMLoc() ) |
◆ emitCFIStartProcImpl()
| void MCStreamer::emitCFIStartProcImpl ( MCDwarfFrameInfo & Frame) | protectedvirtual |
|---|
◆ emitCFIUndefined()
| void MCStreamer::emitCFIUndefined ( int64_t Register, SMLoc Loc = {} ) | virtual |
|---|
◆ emitCFIValOffset()
| void MCStreamer::emitCFIValOffset ( int64_t Register, int64_t Offset, SMLoc Loc = {} ) | virtual |
|---|
◆ emitCFIWindowSave()
| void MCStreamer::emitCFIWindowSave ( SMLoc Loc = {}) | virtual |
|---|
◆ emitCGProfileEntry()
◆ emitCodeAlignment()
◆ emitCOFFImgRel32()
| void MCStreamer::emitCOFFImgRel32 ( MCSymbol const * Symbol, int64_t Offset ) | virtual |
|---|
◆ emitCOFFSafeSEH()
| void MCStreamer::emitCOFFSafeSEH ( MCSymbol const * Symbol) | virtual |
|---|
◆ emitCOFFSecNumber()
| void MCStreamer::emitCOFFSecNumber ( MCSymbol const * Symbol) | virtual |
|---|
Emits the physical number of the section containing the given symbol as assigned during object writing (i.e., this is not a runtime relocation).
Reimplemented in llvm::MCWinCOFFStreamer.
Definition at line 1072 of file MCStreamer.cpp.
Referenced by emitSymbolAttribute().
◆ emitCOFFSecOffset()
| void MCStreamer::emitCOFFSecOffset ( MCSymbol const * Symbol) | virtual |
|---|
Emits the offset of the symbol from the beginning of the section during object writing (i.e., this is not a runtime relocation).
Reimplemented in llvm::MCWinCOFFStreamer.
Definition at line 1074 of file MCStreamer.cpp.
Referenced by emitSymbolAttribute().
◆ emitCOFFSecRel32()
◆ emitCOFFSectionIndex()
| void MCStreamer::emitCOFFSectionIndex ( MCSymbol const * Symbol) | virtual |
|---|
◆ emitCOFFSymbolIndex()
| void MCStreamer::emitCOFFSymbolIndex ( MCSymbol const * Symbol) | virtual |
|---|
◆ emitCOFFSymbolStorageClass()
| void MCStreamer::emitCOFFSymbolStorageClass ( int StorageClass) | virtual |
|---|
◆ emitCOFFSymbolType()
| void MCStreamer::emitCOFFSymbolType ( int Type) | virtual |
|---|
◆ emitCommonSymbol()
| virtual void llvm::MCStreamer::emitCommonSymbol ( MCSymbol * Symbol, uint64_t Size, Align ByteAlignment ) | pure virtual |
|---|
Emit a common symbol.
Parameters
| Symbol | - The common symbol to emit. |
|---|---|
| Size | - The size of the common symbol. |
| ByteAlignment | - The alignment of the symbol. |
Implemented in llvm::CFIFunctionFrameStreamer, llvm::MCDXContainerStreamer, llvm::MCELFStreamer, llvm::MCGOFFStreamer, llvm::MCSPIRVStreamer, llvm::MCWasmStreamer, llvm::MCWinCOFFStreamer, llvm::MCXCOFFStreamer, llvm::RecordStreamer, and llvm::SystemZHLASMAsmStreamer.
References llvm::Data, emitBinaryData(), emitBytes(), emitIntValue(), emitLocalCommonSymbol(), emitTBSSSymbol(), emitValue(), emitValueImpl(), emitZerofill(), and Size.
◆ emitConditionalAssignment()
◆ emitCVDefRangeDirective() [1/5]
◆ emitCVDefRangeDirective() [2/5]
◆ emitCVDefRangeDirective() [3/5]
◆ emitCVDefRangeDirective() [4/5]
◆ emitCVDefRangeDirective() [5/5]
◆ emitCVFileChecksumOffsetDirective()
| virtual void llvm::MCStreamer::emitCVFileChecksumOffsetDirective ( unsigned FileNo) | inlinevirtual |
|---|
◆ emitCVFileChecksumsDirective()
| virtual void llvm::MCStreamer::emitCVFileChecksumsDirective ( ) | inlinevirtual |
|---|
◆ emitCVFileDirective()
◆ emitCVFPOData()
This implements the CodeView '.cv_fpo_data' assembler directive.
Definition at line 976 of file MCStreamer.h.
◆ emitCVFuncIdDirective()
| bool MCStreamer::emitCVFuncIdDirective ( unsigned FunctionId) | virtual |
|---|
◆ emitCVInlineLinetableDirective()
◆ emitCVInlineSiteIdDirective()
◆ emitCVLinetableDirective()
◆ emitCVLocDirective()
◆ emitCVStringTableDirective()
| virtual void llvm::MCStreamer::emitCVStringTableDirective ( ) | inlinevirtual |
|---|
◆ emitDarwinTargetVariantBuildVersion()
◆ emitDataRegion()
| virtual void llvm::MCStreamer::emitDataRegion ( MCDataRegionType Kind) | inlinevirtual |
|---|
◆ emitDwarfAdvanceLineAddr()
◆ emitDwarfFile0Directive()
◆ emitDwarfFileDirective()
◆ emitDwarfLineEndEntry()
| virtual void llvm::MCStreamer::emitDwarfLineEndEntry ( MCSection * Section, MCSymbol * LastLabel, MCSymbol * EndLabel = nullptr ) | inlinevirtual |
|---|
◆ emitDwarfLineStartLabel()
| void MCStreamer::emitDwarfLineStartLabel ( MCSymbol * StartSym) | virtual |
|---|
◆ emitDwarfLocDirective()
◆ emitDwarfLocLabelDirective()
| void MCStreamer::emitDwarfLocLabelDirective ( SMLoc Loc, StringRef Name ) | virtual |
|---|
◆ emitDwarfUnitLength() [1/2]
◆ emitDwarfUnitLength() [2/2]
◆ emitEHSymAttributes()
◆ emitELFSize()
◆ emitELFSymverDirective()
◆ emitExplicitComments()
| void MCStreamer::emitExplicitComments ( ) | virtual |
|---|
◆ emitFileDirective() [1/2]
| void MCStreamer::emitFileDirective ( StringRef Filename) | virtual |
|---|
◆ emitFileDirective() [2/2]
◆ emitFill() [1/3]
◆ emitFill() [2/3]
| void MCStreamer::emitFill ( const MCExpr & NumValues, int64_t Size, int64_t Expr, SMLoc Loc = SMLoc() ) | virtual |
|---|
Emit NumValues copies of Size bytes.
Each Size bytes is taken from the lowest order 4 bytes of Expr expression.
This is used to implement assembler directives such as .fill.
Parameters
| NumValues | - The number of copies of Size bytes to emit. |
|---|---|
| Size | - The size (in bytes) of each repeated value. |
| Expr | - The expression from which Size bytes are used. |
Reimplemented in llvm::MCObjectStreamer.
Definition at line 1339 of file MCStreamer.cpp.
References Size.
◆ emitFill() [3/3]
◆ emitGNUAttribute()
| virtual void llvm::MCStreamer::emitGNUAttribute ( unsigned Tag, unsigned Value ) | inlinevirtual |
|---|
◆ emitIdent()
| virtual void llvm::MCStreamer::emitIdent ( StringRef IdentString) | inlinevirtual |
|---|
◆ emitInstruction()
Emit the given [Instruction](classllvm%5F1%5F1Instruction.html) into the current section.
Reimplemented in llvm::CFIFunctionFrameStreamer, llvm::CSKYELFStreamer, llvm::HexagonMCELFStreamer, llvm::MCObjectStreamer, llvm::MipsELFStreamer, llvm::PPCELFStreamer, llvm::PPCXCOFFStreamer, llvm::RISCVELFStreamer, and llvm::SystemZHLASMAsmStreamer.
Definition at line 1195 of file MCStreamer.cpp.
References llvm::MCOperand::getExpr(), llvm::MCInst::getNumOperands(), llvm::MCInst::getOperand(), llvm::MCOperand::isExpr(), and visitUsedExpr().
Referenced by emitAddress(), EmitBinary(), emitBinary(), emitBSIC(), EmitCall(), llvm::MipsTargetStreamer::emitII(), llvm::MCObjectStreamer::emitInstruction(), emitLEASLrri(), emitLEASLzzi(), emitLEAzii(), emitLEAzzi(), emitNop(), llvm::MipsTargetStreamer::emitR(), EmitRDPC(), llvm::MipsTargetStreamer::emitRRIII(), llvm::MipsTargetStreamer::emitRRRX(), llvm::MipsTargetStreamer::emitRRX(), llvm::MipsTargetStreamer::emitRX(), EmitSETHI(), emitSIC(), and llvm::AsmPrinter::EmitToStreamer().
◆ emitInt16()
| void llvm::MCStreamer::emitInt16 ( uint64_t Value) | inline |
|---|
◆ emitInt32()
| void llvm::MCStreamer::emitInt32 ( uint64_t Value) | inline |
|---|
Definition at line 750 of file MCStreamer.h.
References emitIntValue().
Referenced by ARM64EmitRuntimeFunction(), ARM64EmitUnwindInfoForSegment(), ARMEmitRuntimeFunction(), ARMEmitUnwindInfo(), llvm::AMDGPUTargetELFStreamer::EmitCodeEnd(), llvm::CodeViewContext::emitFileChecksums(), EmitGenDwarfAranges(), EmitGenDwarfInfo(), emitGenDwarfRanges(), llvm::CodeViewContext::emitLineTableForFunction(), llvm::mcdwarf::emitListsTableHeaderStart(), llvm::TargetLoweringObjectFileCOFF::emitModuleMetadata(), llvm::TargetLoweringObjectFileELF::emitModuleMetadata(), llvm::TargetLoweringObjectFileMachO::emitModuleMetadata(), llvm::CodeViewContext::emitStringTable(), llvm::BTFKindDataSec::emitType(), llvm::BTFKindVar::emitType(), llvm::BTFTypeArray::emitType(), llvm::BTFTypeBase::emitType(), llvm::BTFTypeDeclTag::emitType(), llvm::BTFTypeEnum64::emitType(), llvm::BTFTypeEnum::emitType(), llvm::BTFTypeFuncProto::emitType(), llvm::BTFTypeInt::emitType(), llvm::BTFTypeStruct::emitType(), EmitUnwindInfo(), maybeEmitDwarf64Mark(), and llvm::FaultMaps::serializeToFaultMapSection().
◆ emitInt64()
| void llvm::MCStreamer::emitInt64 ( uint64_t Value) | inline |
|---|
◆ emitInt8()
| void llvm::MCStreamer::emitInt8 ( uint64_t Value) | inline |
|---|
Definition at line 748 of file MCStreamer.h.
References emitIntValue().
Referenced by ARM64EmitUnwindCode(), ARM64EmitUnwindInfoForSegment(), ARMEmitUnwindCode(), ARMEmitUnwindInfo(), llvm::MCDwarfLineTableHeader::Emit(), llvm::MCPseudoProbe::emit(), emitEncodingByte(), llvm::CodeViewContext::emitFileChecksums(), EmitGenDwarfAbbrev(), EmitGenDwarfAranges(), EmitGenDwarfInfo(), emitGenDwarfRanges(), llvm::MCELFStreamer::emitIdent(), llvm::TargetLoweringObjectFileELF::emitLinkerDirectives(), llvm::mcdwarf::emitListsTableHeaderStart(), llvm::TargetLoweringObjectFileELF::emitModuleMetadata(), llvm::MCDwarfLineTable::emitOne(), EmitUnwindCode(), and EmitUnwindInfo().
◆ emitIntValue() [1/2]
| void MCStreamer::emitIntValue ( const APInt & Value) | virtual |
|---|
◆ emitIntValue() [2/2]
Special case of EmitValue that avoids the client having to pass in a MCExpr for constant integers.
EmitIntValue - Special case of EmitValue that avoids the client having to pass in a MCExpr for constant integers.
Reimplemented in llvm::MipsELFStreamer.
Definition at line 132 of file MCStreamer.cpp.
References assert(), llvm::big, llvm::support::endian::byte_swap(), emitBytes(), llvm::isIntN(), llvm::isUIntN(), llvm::little, and Size.
Referenced by llvm::MCObjectStreamer::emitAbsoluteSymbolDiff(), emitCommonSymbol(), llvm::MipsTargetELFStreamer::emitDirectiveEnd(), emitDwarfSetLineAddr(), emitDwarfUnitLength(), llvm::MCObjectStreamer::emitFill(), EmitGenDwarfAranges(), EmitGenDwarfInfo(), emitGenDwarfRanges(), emitInt16(), emitInt32(), emitInt64(), emitInt8(), emitIntValue(), llvm::MipsELFStreamer::emitIntValue(), emitIntValueInHex(), emitIntValueInHexWithPadding(), llvm::AMDGPU::AMDGPUMCKernelCodeT::EmitKernelCodeT(), emitNonLazySymbolPointer(), emitNonLazySymbolPointer(), llvm::RISCVTargetStreamer::emitNoteGnuPropertySection(), llvm::AArch64TargetStreamer::emitNoteSection(), llvm::MCDwarfLineStr::emitRef(), llvm::MCObjectStreamer::emitValueImpl(), llvm::operator<<(), llvm::FaultMaps::serializeToFaultMapSection(), smallData(), llvm::writeIndex(), llvm::writeIndexTable(), llvm::writeNewOffsetsTo(), and llvm::writeStringsAndOffsets().
◆ emitIntValueInHex()
| virtual void llvm::MCStreamer::emitIntValueInHex ( uint64_t Value, unsigned Size ) | inlinevirtual |
|---|
Special case of EmitValue that avoids the client having to pass in a MCExpr for constant integers & prints in Hex format for certain modes.
Definition at line 744 of file MCStreamer.h.
References emitIntValue(), and Size.
◆ emitIntValueInHexWithPadding()
| virtual void llvm::MCStreamer::emitIntValueInHexWithPadding ( uint64_t Value, unsigned Size ) | inlinevirtual |
|---|
Special case of EmitValue that avoids the client having to pass in a MCExpr for constant integers & prints in Hex format for certain modes, pads the field with leading zeros to Size width.
Definition at line 756 of file MCStreamer.h.
References emitIntValue(), and Size.
◆ emitLabel()
Emit a label for Symbol into the current section.
This corresponds to an assembler statement such as: foo:
Parameters
| Symbol | - The symbol to emit. A given symbol should only be emitted as a label once, and symbols emitted as a label should never be used in an assignment. |
|---|
Reimplemented in llvm::MCELFStreamer, llvm::MCObjectStreamer, llvm::MCWasmStreamer, llvm::MCWinCOFFStreamer, llvm::MipsELFStreamer, llvm::PPCELFStreamer, llvm::RecordStreamer, and llvm::SystemZHLASMAsmStreamer.
Definition at line 395 of file MCStreamer.cpp.
References assert(), llvm::MCTargetStreamer::emitLabel(), getContext(), getCurrentSectionOnly(), getTargetStreamer(), and llvm::MCContext::reportError().
Referenced by ARM64EmitUnwindInfoForSegment(), ARMEmitUnwindInfo(), changeSection(), llvm::MCDwarfDwoLineTable::Emit(), llvm::MCDwarfLineTableHeader::Emit(), llvm::MCGenDwarfInfo::Emit(), llvm::CSKYConstantPool::emitAll(), emitAuthenticatedPointer(), llvm::MCDwarfLineTable::emitCU(), llvm::MipsTargetELFStreamer::emitDirectiveEnd(), emitDirectiveRelocJalr(), emitDwarfLineStartLabel(), emitDwarfUnitLength(), llvm::ConstantPool::emitEntries(), EmitGenDwarfInfo(), emitGenDwarfRanges(), llvm::MCObjectStreamer::emitLabel(), llvm::RecordStreamer::emitLabel(), llvm::SystemZHLASMAsmStreamer::emitLabel(), llvm::MCObjectStreamer::emitLabelAtPos(), llvm::mcdwarf::emitListsTableHeaderStart(), llvm::XtensaTargetELFStreamer::emitLiteral(), llvm::TargetLoweringObjectFileCOFF::emitModuleMetadata(), llvm::TargetLoweringObjectFileELF::emitModuleMetadata(), llvm::TargetLoweringObjectFileMachO::emitModuleMetadata(), emitNonLazySymbolPointer(), emitNonLazySymbolPointer(), llvm::MCDwarfLineTable::emitOne(), llvm::TargetLoweringObjectFileELF::emitPersonalityValue(), emitPseudoProbe(), EmitUnwindInfo(), llvm::MCDwarfLineTable::endCurrentSeqAndEmitLineStreamLabel(), endSection(), llvm::MCAsmInfo::getExprForFDESymbol(), llvm::AArch64MCAsmInfoDarwin::getExprForPersonalitySymbol(), llvm::AArch64_MachoTargetObjectFile::getIndirectSymViaGOTPCRel(), llvm::AArch64_MachoTargetObjectFile::getTTypeGlobalReference(), llvm::TargetLoweringObjectFile::getTTypeReference(), llvm::MCGenDwarfLabelEntry::Make(), llvm::MCDwarfLineEntry::make(), llvm::FaultMaps::serializeToFaultMapSection(), llvm::StackMaps::serializeToStackMapSection(), and smallData().
◆ emitLineTableLabel()
| MCSymbol * MCStreamer::emitLineTableLabel | ( | ) |
|---|
◆ emitLinkerOptions()
| virtual void llvm::MCStreamer::emitLinkerOptions ( ArrayRef< std::string > Kind) | inlinevirtual |
|---|
◆ emitLocalCommonSymbol()
◆ emitLOHDirective()
Emit a Linker Optimization Hint (LOH) directive.
Parameters
| Args | - Arguments of the LOH. |
|---|
Definition at line 667 of file MCStreamer.h.
◆ emitNops()
◆ emitPseudoProbe()
◆ emitRawComment()
| void MCStreamer::emitRawComment ( const Twine & T, bool TabPrefix = true ) | virtual |
|---|
Print T and prefix it with the comment string (normally #) and optionally a tab.
This prints the comment immediately, not at the end of the current line. It is basically a safe version of EmitRawText: since it only prints comments, the object streamer ignores it instead of asserting.
Definition at line 119 of file MCStreamer.cpp.
References T.
Referenced by emitVGPRBlockComment().
◆ emitRawText()
| void MCStreamer::emitRawText | ( | const Twine & | String | ) |
|---|
◆ emitRawTextImpl()
| void MCStreamer::emitRawTextImpl ( StringRef String) | protectedvirtual |
|---|
◆ emitRelocDirective()
◆ emitSLEB128IntValue()
| unsigned MCStreamer::emitSLEB128IntValue | ( | int64_t | Value | ) |
|---|
◆ emitSLEB128Value()
| void MCStreamer::emitSLEB128Value ( const MCExpr * Value) | virtual |
|---|
◆ emitSubsectionsViaSymbols()
| void MCStreamer::emitSubsectionsViaSymbols ( ) | virtual |
|---|
◆ emitSymbolAttribute()
Add the given [Attribute](classllvm%5F1%5F1Attribute.html "Functions, function parameters, and return types can have attributes to indicate how they should be t...") to Symbol.
Implemented in llvm::CFIFunctionFrameStreamer, llvm::MCDXContainerStreamer, llvm::MCELFStreamer, llvm::MCGOFFStreamer, llvm::MCSPIRVStreamer, llvm::MCWasmStreamer, llvm::MCWinCOFFStreamer, llvm::MCXCOFFStreamer, llvm::RecordStreamer, and llvm::SystemZHLASMAsmStreamer.
References beginCOFFSymbolDef(), emitCOFFImgRel32(), emitCOFFSafeSEH(), emitCOFFSecNumber(), emitCOFFSecOffset(), emitCOFFSecRel32(), emitCOFFSectionIndex(), emitCOFFSymbolIndex(), emitCOFFSymbolStorageClass(), emitCOFFSymbolType(), emitELFSize(), emitELFSymverDirective(), emitSymbolDesc(), emitXCOFFCInfoSym(), emitXCOFFExceptDirective(), emitXCOFFLocalCommonSymbol(), emitXCOFFRefDirective(), emitXCOFFRenameDirective(), emitXCOFFSymbolLinkageWithVisibility(), endCOFFSymbolDef(), Linkage, llvm::Offset, Size, and Trap.
Referenced by emitNonLazySymbolPointer(), emitNonLazySymbolPointer(), llvm::TargetLoweringObjectFileELF::emitPersonalityValue(), and smallData().
◆ emitSymbolDesc()
Set the DescValue for the Symbol.
Parameters
| Symbol | - The symbol to have its n_desc field set. |
|---|---|
| DescValue | - The value to set into the n_desc field. |
Reimplemented in llvm::MCWinCOFFStreamer.
Definition at line 1255 of file MCStreamer.cpp.
Referenced by emitSymbolAttribute().
◆ emitSymbolValue()
Special case of EmitValue that avoids the client having to pass in a MCExpr for MCSymbols.
Definition at line 182 of file MCStreamer.cpp.
References assert(), llvm::MCSymbolRefExpr::create(), emitCOFFSecRel32(), emitValueImpl(), getContext(), and Size.
Referenced by emitAbsoluteSymbolDiff(), emitDwarfSetLineAddr(), llvm::CodeViewContext::emitFileChecksumOffset(), EmitGenDwarfAranges(), EmitGenDwarfInfo(), and llvm::TargetLoweringObjectFileELF::emitPersonalityValueImpl().
◆ emitSyntaxDirective()
| void MCStreamer::emitSyntaxDirective ( ) | virtual |
|---|
◆ emitTBSSSymbol()
Emit a thread local bss (.tbss) symbol.
Parameters
| Section | - The thread local common section. |
|---|---|
| Symbol | - The thread local common symbol to emit. |
| Size | - The size of the symbol. |
| ByteAlignment | - The alignment of the thread local common symbol. |
Definition at line 1314 of file MCStreamer.cpp.
References Size.
Referenced by emitCommonSymbol().
◆ emitULEB128IntValue()
Special case of EmitULEB128Value that avoids the client having to pass in a MCExpr for constant integers.
EmitULEB128IntValue - Special case of EmitULEB128Value that avoids the client having to pass in a MCExpr for constant integers.
Definition at line 160 of file MCStreamer.cpp.
References emitBytes(), llvm::encodeULEB128(), llvm::SmallVectorTemplateCommon< T, typename >::size(), and llvm::raw_svector_ostream::str().
Referenced by llvm::MCPseudoProbe::emit(), llvm::MCPseudoProbeInlineTree::emit(), EmitAbbrev(), llvm::MCObjectStreamer::emitAbsoluteSymbolDiffAsULEB128(), emitDwarfSetLineAddr(), EmitGenDwarfAbbrev(), EmitGenDwarfInfo(), llvm::TargetLoweringObjectFileELF::emitModuleMetadata(), llvm::MCDwarfLineTable::emitOne(), emitOneV5FileEntry(), llvm::TargetLoweringObjectFile::emitPseudoProbeDescMetadata(), and llvm::MCObjectStreamer::emitULEB128Value().
◆ emitULEB128Value()
| void MCStreamer::emitULEB128Value ( const MCExpr * Value) | virtual |
|---|
◆ emitValue()
Definition at line 178 of file MCStreamer.cpp.
References emitValueImpl(), and Size.
Referenced by ARM64EmitRuntimeFunction(), ARM64EmitUnwindInfoForSegment(), ARMEmitRuntimeFunction(), ARMEmitUnwindInfo(), EmitAbsDifference(), emitAbsoluteSymbolDiff(), emitAbsValue(), llvm::CSKYConstantPool::emitAll(), emitAuthenticatedPointer(), emitCommonSymbol(), llvm::ConstantPool::emitEntries(), emitFDESymbol(), EmitGenDwarfAranges(), EmitGenDwarfInfo(), emitGenDwarfRanges(), llvm::AMDGPU::AMDGPUMCKernelCodeT::EmitKernelCodeT(), llvm::XtensaTargetELFStreamer::emitLiteral(), emitNonLazySymbolPointer(), emitNonLazySymbolPointer(), EmitPersonality(), llvm::MCDwarfLineStr::emitRef(), EmitRuntimeFunction(), EmitSymbolRefWithOfs(), EmitSymbolRefWithOfs(), EmitUnwindInfo(), llvm::AVRMCELFStreamer::emitValueForModiferKind(), and smallData().
◆ emitValueImpl()
Emit the expression [Value](classllvm%5F1%5F1Value.html "LLVM Value Representation.") into the output as a native integer of the given Size bytes.
This is used to implement assembler directives such as .word, .quad, etc.
Parameters
| Value | - The value to emit. |
|---|---|
| Size | - The size of the integer (in bytes) to emit. This must match a native machine width. |
| Loc | - The location of the expression for error reporting. |
Reimplemented in llvm::CSKYELFStreamer, llvm::MCObjectStreamer, llvm::MipsELFStreamer, llvm::RISCVELFStreamer, and llvm::SystemZHLASMAsmStreamer.
Definition at line 1333 of file MCStreamer.cpp.
References Size, and visitUsedExpr().
Referenced by emitCommonSymbol(), llvm::MipsTargetELFStreamer::emitDirectiveEnd(), emitSymbolValue(), emitValue(), and llvm::MCObjectStreamer::emitValueImpl().
◆ emitValueToAlignment()
| void MCStreamer::emitValueToAlignment ( Align Alignment, int64_t Fill = 0, uint8_t FillLen = 1, unsigned MaxBytesToEmit = 0 ) | virtual |
|---|
Emit some number of copies of [Value](classllvm%5F1%5F1Value.html "LLVM Value Representation.") until the byte alignment ByteAlignment is reached.
If the number of bytes need to emit for the alignment is not a multiple of ValueSize, then the contents of the emitted fill bytes is undefined.
This used to implement the .align assembler directive.
Parameters
| Alignment | - The alignment to reach. |
|---|---|
| Fill | - The value to use when filling bytes. |
| FillLen | - The size of the integer (in bytes) to emit for Value. This must match a native machine width. |
| MaxBytesToEmit | - The maximum numbers of bytes to emit, or 0. If the alignment cannot be reached in this many bytes, no bytes are emitted. |
Reimplemented in llvm::MCObjectStreamer, and llvm::SystemZHLASMAsmStreamer.
Definition at line 1341 of file MCStreamer.cpp.
Referenced by ARM64EmitRuntimeFunction(), ARM64EmitUnwindInfoForSegment(), ARMEmitRuntimeFunction(), ARMEmitUnwindInfo(), llvm::AMDGPUTargetELFStreamer::EmitCodeEnd(), llvm::ConstantPool::emitEntries(), llvm::RISCVTargetStreamer::emitNoteGnuPropertySection(), llvm::AArch64TargetStreamer::emitNoteSection(), llvm::TargetLoweringObjectFileELF::emitPersonalityValue(), EmitRuntimeFunction(), and EmitUnwindInfo().
◆ emitValueToOffset()
◆ emitVersionForTarget()
Definition at line 1505 of file MCStreamer.cpp.
References assert(), llvm::Triple::BridgeOS, llvm::Triple::Darwin, llvm::Triple::DriverKit, emitBuildVersion(), emitDarwinTargetVariantBuildVersion(), emitVersionForTarget(), emitVersionMin(), getMachoBuildVersionPlatformType(), getMachoBuildVersionSupportedOS(), getMachoVersionMinLoadCommandType(), llvm::Triple::IOS, llvm::Triple::isMacOSX(), llvm_unreachable, llvm::Triple::MacOSX, targetVersionOrMinimumSupportedOSVersion(), llvm::Triple::TvOS, llvm::Version, llvm::Triple::WatchOS, and llvm::Triple::XROS.
Referenced by emitVersionForTarget().
◆ emitVersionMin()
◆ emitWeakReference()
◆ emitWinCFIAllocStack()
◆ emitWinCFIBeginEpilogue()
| void MCStreamer::emitWinCFIBeginEpilogue ( SMLoc Loc = SMLoc()) | virtual |
|---|
◆ emitWinCFIEndChained()
| void MCStreamer::emitWinCFIEndChained ( SMLoc Loc = SMLoc()) | virtual |
|---|
◆ emitWinCFIEndEpilogue()
| void MCStreamer::emitWinCFIEndEpilogue ( SMLoc Loc = SMLoc()) | virtual |
|---|
◆ emitWinCFIEndProc()
| void MCStreamer::emitWinCFIEndProc ( SMLoc Loc = SMLoc()) | virtual |
|---|
Definition at line 748 of file MCStreamer.cpp.
References llvm::WinEH::FrameInfo::ChainedParent, emitCFILabel(), emitWindowsUnwindTables(), llvm::WinEH::FrameInfo::End, EnsureValidWinFrameInfo(), llvm::WinEH::FrameInfo::FuncletOrFuncEnd, llvm::get(), getContext(), I, llvm::MCContext::reportError(), switchSection(), and llvm::WinEH::FrameInfo::TextSection.
◆ emitWinCFIEndProlog()
| void MCStreamer::emitWinCFIEndProlog ( SMLoc Loc = SMLoc()) | virtual |
|---|
◆ emitWinCFIFuncletOrFuncEnd()
| void MCStreamer::emitWinCFIFuncletOrFuncEnd ( SMLoc Loc = SMLoc()) | virtual |
|---|
◆ emitWinCFIPushFrame()
| void MCStreamer::emitWinCFIPushFrame ( bool Code, SMLoc Loc = SMLoc() ) | virtual |
|---|
◆ emitWinCFIPushReg()
◆ emitWinCFISaveReg()
◆ emitWinCFISaveXMM()
◆ emitWinCFISetFrame()
◆ emitWinCFIStartChained()
| void MCStreamer::emitWinCFIStartChained ( SMLoc Loc = SMLoc()) | virtual |
|---|
◆ emitWinCFIStartProc()
◆ emitWinCFIUnwindV2Start()
| void MCStreamer::emitWinCFIUnwindV2Start ( SMLoc Loc = SMLoc()) | virtual |
|---|
◆ emitWinCFIUnwindVersion()
◆ emitWindowsUnwindTables() [1/2]
| void MCStreamer::emitWindowsUnwindTables ( ) | protectedvirtual |
|---|
◆ emitWindowsUnwindTables() [2/2]
| void MCStreamer::emitWindowsUnwindTables ( WinEH::FrameInfo * Frame) | protectedvirtual |
|---|
◆ emitWinEHHandler()
◆ emitWinEHHandlerData()
| void MCStreamer::emitWinEHHandlerData ( SMLoc Loc = SMLoc()) | virtual |
|---|
◆ emitXCOFFCInfoSym()
◆ emitXCOFFExceptDirective()
Emit an XCOFF .except directive which adds information about a trap instruction to the object file exception section.
Parameters
| Symbol | - The function containing the trap. |
|---|---|
| Lang | - The language code for the exception entry. |
| Reason | - The reason code for the exception entry. |
Reimplemented in llvm::MCXCOFFStreamer.
Definition at line 1293 of file MCStreamer.cpp.
References llvm::report_fatal_error(), and Trap.
Referenced by emitSymbolAttribute().
◆ emitXCOFFLocalCommonSymbol()
Emits an lcomm directive with XCOFF csect information.
Parameters
| LabelSym | - Label on the block of storage. |
|---|---|
| Size | - The size of the block of storage. |
| CsectSym | - Csect name for the block of storage. |
| Alignment | - The alignment of the symbol in bytes. |
Reimplemented in llvm::MCXCOFFStreamer.
Definition at line 1273 of file MCStreamer.cpp.
References llvm_unreachable, and Size.
Referenced by emitSymbolAttribute().
◆ emitXCOFFRefDirective()
| void MCStreamer::emitXCOFFRefDirective ( const MCSymbol * Symbol) | virtual |
|---|
◆ emitXCOFFRenameDirective()
Emit a XCOFF .rename directive which creates a synonym for an illegal or undesirable name.
Parameters
| Name | - The name used internally in the assembly for references to the symbol. |
|---|---|
| Rename | - The value to which the Name parameter is changed at the end of assembly. |
Reimplemented in llvm::MCXCOFFStreamer.
Definition at line 1286 of file MCStreamer.cpp.
Referenced by emitSymbolAttribute().
◆ emitXCOFFSymbolLinkageWithVisibility()
◆ emitZerofill()
Emit the zerofill section and an optional symbol.
Parameters
| Section | - The zerofill section to create and or to put the symbol |
|---|---|
| Symbol | - The zerofill symbol to emit, if non-NULL. |
| Size | - The size of the zerofill symbol. |
| ByteAlignment | - The alignment of the zerofill symbol. |
Reimplemented in llvm::RecordStreamer, and llvm::SystemZHLASMAsmStreamer.
Definition at line 1312 of file MCStreamer.cpp.
Referenced by emitCommonSymbol().
◆ emitZeros()
| void MCStreamer::emitZeros | ( | uint64_t | NumBytes | ) |
|---|
◆ endCOFFSymbolDef()
| void MCStreamer::endCOFFSymbolDef ( ) | virtual |
|---|
◆ endSection()
◆ EnsureValidWinFrameInfo()
Retrieve the current frame info if one is available and it is not yet closed.
Otherwise, issue an error and return null.
Definition at line 714 of file MCStreamer.cpp.
References getContext(), llvm::MCContext::reportError(), and llvm::MCAsmInfo::usesWindowsCFI().
Referenced by emitWinCFIAllocStack(), emitWinCFIBeginEpilogue(), emitWinCFIEndChained(), emitWinCFIEndEpilogue(), emitWinCFIEndProc(), emitWinCFIEndProlog(), emitWinCFIFuncletOrFuncEnd(), emitWinCFIPushFrame(), emitWinCFIPushReg(), emitWinCFISaveReg(), emitWinCFISaveXMM(), emitWinCFISetFrame(), emitWinCFIStartChained(), emitWinCFIUnwindV2Start(), emitWinCFIUnwindVersion(), emitWinEHHandler(), and emitWinEHHandlerData().
◆ finish()
◆ finishImpl()
| void MCStreamer::finishImpl ( ) | virtual |
|---|
◆ generateCompactUnwindEncodings()
| void MCStreamer::generateCompactUnwindEncodings | ( | MCAsmBackend * | MAB | ) |
|---|
◆ getAllowAutoPadding()
| bool llvm::MCStreamer::getAllowAutoPadding ( ) const | inline |
|---|
◆ getAssemblerPtr()
| virtual MCAssembler * llvm::MCStreamer::getAssemblerPtr ( ) | inlinevirtual |
|---|
◆ getAssociatedPDataSection()
◆ getAssociatedXDataSection()
◆ getCommentOS()
Return a raw_ostream that comments can be written to.
Unlike AddComment, you are required to terminate comments with
if you use this method.
Definition at line 109 of file MCStreamer.cpp.
References llvm::nulls().
◆ getContext()
| MCContext & llvm::MCStreamer::getContext ( ) const | inline |
|---|
Definition at line 314 of file MCStreamer.h.
Referenced by llvm::AssemblerConstantPools::addEntry(), llvm::CSKYConstantPool::addEntry(), llvm::CodeViewContext::addFile(), ARM64EmitRuntimeFunction(), ARM64EmitUnwindInfo(), ARM64EmitUnwindInfoForSegment(), ARMEmitRuntimeFunction(), ARMEmitUnwindInfo(), buildSymbolDiff(), buildSymbolDiff(), llvm::MCObjectStreamer::changeSection(), changeSection(), llvm::NVPTXTargetStreamer::changeSection(), llvm::SystemZHLASMAsmStreamer::changeSection(), checkARM64Instructions(), checkARMInstructions(), checkCVLocSection(), createAsmTargetStreamer(), createObjectTargetStreamer(), llvm::MCDwarfFrameEmitter::Emit(), llvm::MCDwarfLineAddr::Emit(), llvm::MCDwarfLineTableHeader::Emit(), llvm::MCGenDwarfInfo::Emit(), llvm::MCDwarfLineTable::emit(), llvm::MCPseudoProbeSections::emit(), llvm::MCPseudoProbeTable::emit(), llvm::MCSFrameEmitter::emit(), EmitAbsDifference(), emitAddress(), llvm::CSKYConstantPool::emitAll(), llvm::AMDGPUTargetELFStreamer::EmitAMDGPUSymbolType(), llvm::MipsELFStreamer::emitCFIEndProcImpl(), llvm::MCObjectStreamer::emitCFILabel(), llvm::MipsELFStreamer::emitCFILabel(), emitCFILabelDirective(), emitCFIStartProc(), llvm::MipsELFStreamer::emitCFIStartProcImpl(), llvm::MCWinCOFFStreamer::emitCOFFImgRel32(), llvm::MCWinCOFFStreamer::emitCOFFSafeSEH(), llvm::MCWinCOFFStreamer::emitCOFFSecNumber(), llvm::MCWinCOFFStreamer::emitCOFFSecOffset(), llvm::MCWinCOFFStreamer::emitCOFFSecRel32(), llvm::MCWinCOFFStreamer::emitCOFFSectionIndex(), llvm::MCELFStreamer::emitCommonSymbol(), llvm::MCWinCOFFStreamer::emitCommonSymbol(), llvm::MCObjectStreamer::emitCVDefRangeDirective(), llvm::MCObjectStreamer::emitCVFileChecksumOffsetDirective(), llvm::MCObjectStreamer::emitCVFileChecksumsDirective(), emitCVFileDirective(), emitCVFuncIdDirective(), llvm::MCObjectStreamer::emitCVInlineLinetableDirective(), emitCVInlineSiteIdDirective(), llvm::MCObjectStreamer::emitCVLinetableDirective(), llvm::MCObjectStreamer::emitCVLocDirective(), llvm::MCObjectStreamer::emitCVStringTableDirective(), llvm::MipsTargetAsmStreamer::emitDTPRel32Value(), llvm::MipsTargetAsmStreamer::emitDTPRel64Value(), llvm::MCObjectStreamer::emitDwarfAdvanceLineAddr(), emitDwarfFile0Directive(), llvm::MCObjectStreamer::emitDwarfLineEndEntry(), emitDwarfLocDirective(), emitDwarfLocLabelDirective(), emitFDESymbol(), llvm::CodeViewContext::emitFileChecksumOffset(), llvm::CodeViewContext::emitFileChecksums(), llvm::MCObjectStreamer::emitFill(), emitFill(), llvm::MCObjectStreamer::emitFrames(), llvm::AMDGPUAsmPrinter::emitFunctionBodyEnd(), EmitGenDwarfAbbrev(), EmitGenDwarfAranges(), EmitGenDwarfInfo(), emitGenDwarfRanges(), llvm::MipsTargetAsmStreamer::emitGPRel32Value(), llvm::MipsTargetAsmStreamer::emitGPRel64Value(), llvm::SystemZHLASMAsmStreamer::emitHLASMValueImpl(), llvm::HexagonMCELFStreamer::emitInstruction(), llvm::MipsELFStreamer::emitInstruction(), emitLabel(), llvm::CodeViewContext::emitLineTableForFunction(), emitLineTableLabel(), llvm::mcdwarf::emitListsTableHeaderStart(), llvm::XtensaTargetELFStreamer::emitLiteral(), llvm::MCWinCOFFStreamer::emitLocalCommonSymbol(), emitNonLazySymbolPointer(), emitNonLazySymbolPointer(), llvm::RISCVTargetStreamer::emitNoteGnuPropertySection(), llvm::AArch64TargetStreamer::emitNoteSection(), llvm::MCDwarfLineTable::emitOne(), EmitPersonality(), emitPseudoProbe(), llvm::MCDwarfLineStr::emitRef(), llvm::MCObjectStreamer::emitRelocDirective(), EmitRuntimeFunction(), llvm::MCDwarfLineStr::emitSection(), llvm::CodeViewContext::emitStringTable(), llvm::MCELFStreamer::emitSymbolAttribute(), EmitSymbolRefWithOfs(), EmitSymbolRefWithOfs(), emitSymbolValue(), llvm::MipsTargetAsmStreamer::emitTPRel32Value(), llvm::MipsTargetAsmStreamer::emitTPRel64Value(), EmitUnwindInfo(), llvm::AVRMCELFStreamer::emitValueForModiferKind(), llvm::MCObjectStreamer::emitValueImpl(), llvm::MCELFStreamer::emitWeakReference(), llvm::MCWinCOFFStreamer::emitWeakReference(), emitWinCFIAllocStack(), emitWinCFIBeginEpilogue(), emitWinCFIEndChained(), emitWinCFIEndEpilogue(), emitWinCFIEndProc(), emitWinCFIFuncletOrFuncEnd(), emitWinCFIPushFrame(), emitWinCFISaveReg(), emitWinCFISaveXMM(), emitWinCFISetFrame(), emitWinCFIStartProc(), emitWinCFIUnwindV2Start(), emitWinCFIUnwindVersion(), emitWinEHHandler(), emitWinEHHandlerData(), llvm::MCXCOFFStreamer::emitXCOFFRefDirective(), llvm::MCDwarfLineTable::endCurrentSeqAndEmitLineStreamLabel(), EnsureValidWinFrameInfo(), finish(), llvm::MCObjectStreamer::finishImpl(), llvm::MCWinCOFFStreamer::finishImpl(), llvm::RecordStreamer::flushSymverDirectives(), forceExpAbs(), getAssociatedPDataSection(), getAssociatedXDataSection(), getDataAlignmentFactor(), getDwarfLineTableSymbol(), llvm::MCAsmInfo::getExprForFDESymbol(), llvm::RISCVMCAsmInfo::getExprForFDESymbol(), llvm::SparcELFMCAsmInfo::getExprForFDESymbol(), llvm::AArch64MCAsmInfoDarwin::getExprForPersonalitySymbol(), llvm::SparcELFMCAsmInfo::getExprForPersonalitySymbol(), llvm::X86_64MCAsmInfoDarwin::getExprForPersonalitySymbol(), getSizeForEncoding(), GetSubDivExpr(), llvm::HexagonMCELFStreamer::HexagonMCEmitCommonSymbol(), llvm::MCELFStreamer::initSections(), initSections(), llvm::MCWinCOFFStreamer::initSections(), llvm::MCGenDwarfLabelEntry::Make(), llvm::MCDwarfLineEntry::make(), llvm::MSP430TargetELFStreamer::MSP430TargetELFStreamer(), llvm::MCObjectStreamer::reset(), smallData(), llvm::XtensaTargetELFStreamer::startLiteralSection(), switchSection(), tryEmitDwarfFileDirective(), and llvm::write().
◆ getCurFragSize()
| size_t llvm::MCStreamer::getCurFragSize ( ) const | inline |
|---|
◆ getCurrentFragment()
| MCFragment * llvm::MCStreamer::getCurrentFragment ( ) const | inline |
|---|
Definition at line 432 of file MCStreamer.h.
References assert(), CurFrag, llvm::MCFragment::FT_Data, and getCurrentSection().
Referenced by llvm::MCPseudoProbe::emit(), llvm::MCObjectStreamer::emitCodeAlignment(), llvm::MCObjectStreamer::emitDwarfAdvanceFrameAddr(), llvm::MCObjectStreamer::emitDwarfAdvanceLineAddr(), llvm::MCObjectStreamer::emitInstToFragment(), llvm::MCObjectStreamer::emitSFrameCalculateFuncOffset(), llvm::MCObjectStreamer::emitSLEB128Value(), llvm::CodeViewContext::emitStringTable(), llvm::MCObjectStreamer::emitULEB128Value(), llvm::MCObjectStreamer::emitValueToAlignment(), and getCurFragSize().
◆ getCurrentSection()
◆ getCurrentSectionOnly()
| MCSection * llvm::MCStreamer::getCurrentSectionOnly ( ) const | inline |
|---|
Definition at line 421 of file MCStreamer.h.
References CurFrag.
Referenced by llvm::AssemblerConstantPools::addEntry(), llvm::CSKYConstantPool::addEntry(), checkCVLocSection(), llvm::AssemblerConstantPools::clearCacheForCurrentSection(), llvm::MCObjectStreamer::emitBytes(), llvm::SystemZHLASMAsmStreamer::emitBytes(), emitCFIStartProc(), llvm::MCWinCOFFStreamer::emitCOFFSymbolIndex(), llvm::MCObjectStreamer::emitDwarfLocDirective(), llvm::MCObjectStreamer::emitFill(), llvm::MCObjectStreamer::emitFill(), llvm::AssemblerConstantPools::emitForCurrentSection(), llvm::MCObjectStreamer::emitInstruction(), llvm::MCELFStreamer::emitLabel(), emitLabel(), llvm::MCWasmStreamer::emitLabel(), llvm::MCELFStreamer::emitLabelAtPos(), llvm::MCObjectStreamer::emitLabelAtPos(), llvm::MCWasmStreamer::emitLabelAtPos(), emitLineTableLabel(), llvm::XtensaTargetELFStreamer::emitLiteral(), llvm::TargetLoweringObjectFileCOFF::emitModuleMetadata(), llvm::MCObjectStreamer::emitNops(), llvm::AArch64TargetStreamer::emitNoteSection(), llvm::MCObjectStreamer::emitRelocDirective(), llvm::MCObjectStreamer::emitValueImpl(), llvm::SystemZHLASMAsmStreamer::emitValueImpl(), emitWinCFIStartProc(), llvm::MCDwarfLineTable::endCurrentSeqAndEmitLineStreamLabel(), and llvm::MCGenDwarfLabelEntry::Make().
◆ getCurrentWinEpilog()
◆ getCurrentWinFrameInfo()
◆ getDwarfFrameInfos()
◆ getDwarfLineTableSymbol()
◆ getMnemonic()
Returns the mnemonic for MI, if the streamer has access to a instruction printer and returns an empty string otherwise.
Definition at line 471 of file MCStreamer.h.
References MI.
Referenced by getMIMnemonic().
◆ getNumFrameInfos()
| unsigned MCStreamer::getNumFrameInfos | ( | ) |
|---|
◆ getNumWinFrameInfos()
| unsigned llvm::MCStreamer::getNumWinFrameInfos ( ) | inline |
|---|
◆ getPreviousSection()
◆ getStartTokLoc()
| SMLoc llvm::MCStreamer::getStartTokLoc ( ) const | inline |
|---|
◆ getTargetStreamer()
◆ getUseAssemblerInfoForParsing()
| bool llvm::MCStreamer::getUseAssemblerInfoForParsing ( ) | inline |
|---|
◆ getWinFrameInfos()
◆ hasRawTextSupport()
| virtual bool llvm::MCStreamer::hasRawTextSupport ( ) const | inlinevirtual |
|---|
◆ hasUnfinishedDwarfFrameInfo()
| bool MCStreamer::hasUnfinishedDwarfFrameInfo | ( | ) |
|---|
◆ initSections()
◆ isInEpilogCFI()
| bool llvm::MCStreamer::isInEpilogCFI ( ) const | inline |
|---|
◆ isIntegratedAssemblerRequired()
| virtual bool llvm::MCStreamer::isIntegratedAssemblerRequired ( ) const | inlinevirtual |
|---|
◆ isObj()
| bool llvm::MCStreamer::isObj ( ) const | inline |
|---|
◆ isVerboseAsm()
| virtual bool llvm::MCStreamer::isVerboseAsm ( ) const | inlinevirtual |
|---|
◆ maybeEmitDwarf64Mark()
| void MCStreamer::maybeEmitDwarf64Mark | ( | ) |
|---|
◆ mayHaveInstructions()
| virtual bool llvm::MCStreamer::mayHaveInstructions ( MCSection & Sec) const | inlinevirtual |
|---|
◆ operator=()
◆ popSection()
| bool MCStreamer::popSection ( ) | virtual |
|---|
◆ pushSection()
| void llvm::MCStreamer::pushSection ( ) | inline |
|---|
◆ reset()
| void MCStreamer::reset ( ) | virtual |
|---|
◆ setAllowAutoPadding()
| void llvm::MCStreamer::setAllowAutoPadding ( bool v) | inline |
|---|
◆ setStartTokLocPtr()
| void llvm::MCStreamer::setStartTokLocPtr ( const SMLoc * Loc) | inline |
|---|
◆ setTargetStreamer()
◆ setUseAssemblerInfoForParsing()
| void llvm::MCStreamer::setUseAssemblerInfoForParsing ( bool v) | inline |
|---|
◆ switchSection() [1/2]
◆ switchSection() [2/2]
Set the current section where code is being emitted to Section.
This is required to update CurSection.
This corresponds to assembler directives like .section, .text, etc.
Reimplemented in llvm::MipsELFStreamer.
Definition at line 1363 of file MCStreamer.cpp.
References assert(), and changeSection().
Referenced by addAllTypesFromDWP(), addAllTypesFromTypesSection(), llvm::MCDwarfDwoLineTable::Emit(), llvm::MCDwarfFrameEmitter::Emit(), llvm::MCGenDwarfInfo::Emit(), llvm::Win64EH::ARM64UnwindEmitter::Emit(), llvm::Win64EH::ARMUnwindEmitter::Emit(), llvm::Win64EH::UnwindEmitter::Emit(), llvm::MCDwarfLineTable::emit(), llvm::MCPseudoProbeSections::emit(), llvm::MCSFrameEmitter::emit(), llvm::CSKYConstantPool::emitAll(), llvm::MCWinCOFFStreamer::emitCOFFSafeSEH(), llvm::MCELFStreamer::emitCommonSymbol(), llvm::MCWinCOFFStreamer::emitCommonSymbol(), emitConstantPool(), llvm::MipsTargetELFStreamer::emitDirectiveEnd(), llvm::MCObjectStreamer::emitDwarfLineEndEntry(), EmitGenDwarfAbbrev(), EmitGenDwarfAranges(), EmitGenDwarfInfo(), emitGenDwarfRanges(), llvm::MCELFStreamer::emitIdent(), llvm::TargetLoweringObjectFileCOFF::emitLinkerDirectives(), llvm::TargetLoweringObjectFileELF::emitLinkerDirectives(), llvm::XtensaTargetELFStreamer::emitLiteral(), llvm::MCWinCOFFStreamer::emitLocalCommonSymbol(), llvm::MipsTargetELFStreamer::emitMipsAbiFlags(), llvm::TargetLoweringObjectFileCOFF::emitModuleMetadata(), llvm::TargetLoweringObjectFileELF::emitModuleMetadata(), llvm::TargetLoweringObjectFileMachO::emitModuleMetadata(), emitNonLazyStubs(), llvm::RISCVTargetStreamer::emitNoteGnuPropertySection(), llvm::AArch64TargetStreamer::emitNoteSection(), llvm::TargetLoweringObjectFileELF::emitPersonalityValue(), llvm::TargetLoweringObjectFile::emitPseudoProbeDescMetadata(), llvm::MCDwarfLineStr::emitSection(), llvm::Win64EH::ARM64UnwindEmitter::EmitUnwindInfo(), llvm::Win64EH::ARMUnwindEmitter::EmitUnwindInfo(), llvm::Win64EH::UnwindEmitter::EmitUnwindInfo(), emitWinCFIEndProc(), endSection(), llvm::MipsTargetELFStreamer::finish(), llvm::MCWinCOFFStreamer::finishImpl(), llvm::handleSection(), llvm::HexagonMCELFStreamer::HexagonMCEmitCommonSymbol(), llvm::MCELFStreamer::initSections(), llvm::MCWinCOFFStreamer::initSections(), llvm::FaultMaps::serializeToFaultMapSection(), llvm::StackMaps::serializeToStackMapSection(), smallData(), switchSection(), llvm::MipsELFStreamer::switchSection(), llvm::write(), llvm::writeIndex(), and llvm::writeStringsAndOffsets().
◆ switchSectionNoPrint()
| void MCStreamer::switchSectionNoPrint | ( | MCSection * | Section | ) |
|---|
◆ tryEmitDwarfFileDirective()
Associate a filename with a specified logical file number.
Also associate a directory, optional checksum, and optional source text with the logical file. This implements the DWARF2 '.file 4 "dir/foo.c"' assembler directive, and the DWARF5 '.file 4 "dir/foo.c" md5 "..." source "..."' assembler directive.
Definition at line 206 of file MCStreamer.cpp.
References getContext(), and llvm::MCContext::getDwarfFile().
Referenced by emitDwarfFileDirective().
◆ visitUsedExpr()
Definition at line 1165 of file MCStreamer.cpp.
References llvm::MCExpr::Binary, llvm::cast(), llvm::MCExpr::Constant, llvm::MCExpr::getKind(), llvm::MCBinaryExpr::getLHS(), llvm::MCBinaryExpr::getRHS(), llvm::MCExpr::Specifier, llvm::MCExpr::SymbolRef, llvm::MCExpr::Target, llvm::MCExpr::Unary, visitUsedExpr(), and visitUsedSymbol().
Referenced by emitAssignment(), emitInstruction(), llvm::MCObjectStreamer::emitRelocDirective(), llvm::HexagonMCELFStreamer::EmitSymbol(), emitValueImpl(), llvm::AMDGPUMCExpr::visitUsedExpr(), llvm::HexagonMCExpr::visitUsedExpr(), visitUsedExpr(), and ~MCStreamer().
◆ visitUsedSymbol()
◆ CurFrag
Definition at line 267 of file MCStreamer.h.
Referenced by llvm::MCObjectStreamer::addFixup(), addFragment(), llvm::MCObjectStreamer::appendContents(), llvm::MCObjectStreamer::appendContents(), llvm::MCObjectStreamer::changeSection(), changeSection(), llvm::MCXCOFFStreamer::changeSection(), llvm::MCObjectStreamer::emitLabel(), llvm::MCObjectStreamer::getCurFragEnd(), getCurrentFragment(), getCurrentSectionOnly(), and reset().
◆ CurrentWinEpilog
◆ IsObj
| bool llvm::MCStreamer::IsObj = false | protected |
|---|
The documentation for this class was generated from the following files:
- include/llvm/MC/MCStreamer.h
- lib/MC/MCStreamer.cpp