LLVM  14.0.0git
MCStreamer.h
Go to the documentation of this file.
1 //===- MCStreamer.h - High-level Streaming Machine Code Output --*- C++ -*-===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 //
9 // This file declares the MCStreamer class.
10 //
11 //===----------------------------------------------------------------------===//
12 
13 #ifndef LLVM_MC_MCSTREAMER_H
14 #define LLVM_MC_MCSTREAMER_H
15 
16 #include "llvm/ADT/APInt.h"
17 #include "llvm/ADT/ArrayRef.h"
18 #include "llvm/ADT/DenseMap.h"
19 #include "llvm/ADT/Optional.h"
20 #include "llvm/ADT/SmallVector.h"
21 #include "llvm/ADT/StringRef.h"
22 #include "llvm/MC/MCDirectives.h"
24 #include "llvm/MC/MCPseudoProbe.h"
25 #include "llvm/MC/MCSymbol.h"
26 #include "llvm/MC/MCWinEH.h"
27 #include "llvm/Support/Error.h"
28 #include "llvm/Support/MD5.h"
29 #include "llvm/Support/SMLoc.h"
32 #include <cassert>
33 #include <cstdint>
34 #include <memory>
35 #include <string>
36 #include <utility>
37 #include <vector>
38 
39 namespace llvm {
40 
41 class AssemblerConstantPools;
42 class MCAsmBackend;
43 class MCCodeEmitter;
44 class MCContext;
45 struct MCDwarfFrameInfo;
46 class MCExpr;
47 class MCInst;
48 class MCInstPrinter;
49 class MCRegister;
50 class MCSection;
51 class MCStreamer;
52 class MCSymbolRefExpr;
53 class MCSubtargetInfo;
54 class raw_ostream;
55 class Twine;
56 
57 namespace codeview {
58 struct DefRangeRegisterRelHeader;
59 struct DefRangeSubfieldRegisterHeader;
60 struct DefRangeRegisterHeader;
61 struct DefRangeFramePointerRelHeader;
62 }
63 
64 using MCSectionSubPair = std::pair<MCSection *, const MCExpr *>;
65 
66 /// Target specific streamer interface. This is used so that targets can
67 /// implement support for target specific assembly directives.
68 ///
69 /// If target foo wants to use this, it should implement 3 classes:
70 /// * FooTargetStreamer : public MCTargetStreamer
71 /// * FooTargetAsmStreamer : public FooTargetStreamer
72 /// * FooTargetELFStreamer : public FooTargetStreamer
73 ///
74 /// FooTargetStreamer should have a pure virtual method for each directive. For
75 /// example, for a ".bar symbol_name" directive, it should have
76 /// virtual emitBar(const MCSymbol &Symbol) = 0;
77 ///
78 /// The FooTargetAsmStreamer and FooTargetELFStreamer classes implement the
79 /// method. The assembly streamer just prints ".bar symbol_name". The object
80 /// streamer does whatever is needed to implement .bar in the object file.
81 ///
82 /// In the assembly printer and parser the target streamer can be used by
83 /// calling getTargetStreamer and casting it to FooTargetStreamer:
84 ///
85 /// MCTargetStreamer &TS = OutStreamer.getTargetStreamer();
86 /// FooTargetStreamer &ATS = static_cast<FooTargetStreamer &>(TS);
87 ///
88 /// The base classes FooTargetAsmStreamer and FooTargetELFStreamer should
89 /// *never* be treated differently. Callers should always talk to a
90 /// FooTargetStreamer.
92 protected:
94 
95 public:
97  virtual ~MCTargetStreamer();
98 
100 
101  // Allow a target to add behavior to the EmitLabel of MCStreamer.
102  virtual void emitLabel(MCSymbol *Symbol);
103  // Allow a target to add behavior to the emitAssignment of MCStreamer.
104  virtual void emitAssignment(MCSymbol *Symbol, const MCExpr *Value);
105 
106  virtual void prettyPrintAsm(MCInstPrinter &InstPrinter, uint64_t Address,
107  const MCInst &Inst, const MCSubtargetInfo &STI,
108  raw_ostream &OS);
109 
111 
112  /// Update streamer for a new active section.
113  ///
114  /// This is called by PopSection and SwitchSection, if the current
115  /// section changes.
116  virtual void changeSection(const MCSection *CurSection, MCSection *Section,
117  const MCExpr *SubSection, raw_ostream &OS);
118 
119  virtual void emitValue(const MCExpr *Value);
120 
121  /// Emit the bytes in \p Data into the output.
122  ///
123  /// This is used to emit bytes in \p Data as sequence of .byte directives.
124  virtual void emitRawBytes(StringRef Data);
125 
126  virtual void emitConstantPools();
127 
128  virtual void finish();
129 };
130 
131 // FIXME: declared here because it is used from
132 // lib/CodeGen/AsmPrinter/ARMException.cpp.
134 public:
136  ~ARMTargetStreamer() override;
137 
138  virtual void emitFnStart();
139  virtual void emitFnEnd();
140  virtual void emitCantUnwind();
141  virtual void emitPersonality(const MCSymbol *Personality);
142  virtual void emitPersonalityIndex(unsigned Index);
143  virtual void emitHandlerData();
144  virtual void emitSetFP(unsigned FpReg, unsigned SpReg,
145  int64_t Offset = 0);
146  virtual void emitMovSP(unsigned Reg, int64_t Offset = 0);
147  virtual void emitPad(int64_t Offset);
148  virtual void emitRegSave(const SmallVectorImpl<unsigned> &RegList,
149  bool isVector);
150  virtual void emitUnwindRaw(int64_t StackOffset,
151  const SmallVectorImpl<uint8_t> &Opcodes);
152 
153  virtual void switchVendor(StringRef Vendor);
154  virtual void emitAttribute(unsigned Attribute, unsigned Value);
155  virtual void emitTextAttribute(unsigned Attribute, StringRef String);
156  virtual void emitIntTextAttribute(unsigned Attribute, unsigned IntValue,
157  StringRef StringValue = "");
158  virtual void emitFPU(unsigned FPU);
159  virtual void emitArch(ARM::ArchKind Arch);
160  virtual void emitArchExtension(uint64_t ArchExt);
161  virtual void emitObjectArch(ARM::ArchKind Arch);
162  void emitTargetAttributes(const MCSubtargetInfo &STI);
163  virtual void finishAttributeSection();
164  virtual void emitInst(uint32_t Inst, char Suffix = '\0');
165 
166  virtual void AnnotateTLSDescriptorSequence(const MCSymbolRefExpr *SRE);
167 
168  virtual void emitThumbSet(MCSymbol *Symbol, const MCExpr *Value);
169 
170  void emitConstantPools() override;
171 
172  /// Reset any state between object emissions, i.e. the equivalent of
173  /// MCStreamer's reset method.
174  virtual void reset();
175 
176  /// Callback used to implement the ldr= pseudo.
177  /// Add a new entry to the constant pool for the current section and return an
178  /// MCExpr that can be used to refer to the constant pool location.
179  const MCExpr *addConstantPoolEntry(const MCExpr *, SMLoc Loc);
180 
181  /// Callback used to implement the .ltorg directive.
182  /// Emit contents of constant pool for the current section.
184 
185 private:
186  std::unique_ptr<AssemblerConstantPools> ConstantPools;
187 };
188 
189 /// Streaming machine code generation interface.
190 ///
191 /// This interface is intended to provide a programmatic interface that is very
192 /// similar to the level that an assembler .s file provides. It has callbacks
193 /// to emit bytes, handle directives, etc. The implementation of this interface
194 /// retains state to know what the current section is etc.
195 ///
196 /// There are multiple implementations of this interface: one for writing out
197 /// a .s file, and implementations that write out .o files of various formats.
198 ///
199 class MCStreamer {
200  MCContext &Context;
201  std::unique_ptr<MCTargetStreamer> TargetStreamer;
202 
203  std::vector<MCDwarfFrameInfo> DwarfFrameInfos;
204  MCDwarfFrameInfo *getCurrentDwarfFrameInfo();
205 
206  /// Similar to DwarfFrameInfos, but for SEH unwind info. Chained frames may
207  /// refer to each other, so use std::unique_ptr to provide pointer stability.
208  std::vector<std::unique_ptr<WinEH::FrameInfo>> WinFrameInfos;
209 
210  WinEH::FrameInfo *CurrentWinFrameInfo;
211  size_t CurrentProcWinFrameInfoStartIndex;
212 
213  /// Tracks an index to represent the order a symbol was emitted in.
214  /// Zero means we did not emit that symbol.
216 
217  /// This is stack of current and previous section values saved by
218  /// PushSection.
220 
221  /// Pointer to the parser's SMLoc if available. This is used to provide
222  /// locations for diagnostics.
223  const SMLoc *StartTokLocPtr = nullptr;
224 
225  /// The next unique ID to use when creating a WinCFI-related section (.pdata
226  /// or .xdata). This ID ensures that we have a one-to-one mapping from
227  /// code section to unwind info section, which MSVC's incremental linker
228  /// requires.
229  unsigned NextWinCFIID = 0;
230 
231  bool UseAssemblerInfoForParsing;
232 
233  /// Is the assembler allowed to insert padding automatically? For
234  /// correctness reasons, we sometimes need to ensure instructions aren't
235  /// separated in unexpected ways. At the moment, this feature is only
236  /// useable from an integrated assembler, but assembly syntax is under
237  /// discussion for future inclusion.
238  bool AllowAutoPadding = false;
239 
240 protected:
241  MCStreamer(MCContext &Ctx);
242 
243  virtual void emitCFIStartProcImpl(MCDwarfFrameInfo &Frame);
244  virtual void emitCFIEndProcImpl(MCDwarfFrameInfo &CurFrame);
245 
247  return CurrentWinFrameInfo;
248  }
249 
250  virtual void EmitWindowsUnwindTables(WinEH::FrameInfo *Frame);
251 
252  virtual void EmitWindowsUnwindTables();
253 
254  virtual void emitRawTextImpl(StringRef String);
255 
256  /// Returns true if the the .cv_loc directive is in the right section.
257  bool checkCVLocSection(unsigned FuncId, unsigned FileNo, SMLoc Loc);
258 
259 public:
260  MCStreamer(const MCStreamer &) = delete;
261  MCStreamer &operator=(const MCStreamer &) = delete;
262  virtual ~MCStreamer();
263 
264  void visitUsedExpr(const MCExpr &Expr);
265  virtual void visitUsedSymbol(const MCSymbol &Sym);
266 
268  TargetStreamer.reset(TS);
269  }
270 
271  void setStartTokLocPtr(const SMLoc *Loc) { StartTokLocPtr = Loc; }
273  return StartTokLocPtr ? *StartTokLocPtr : SMLoc();
274  }
275 
276  /// State management
277  ///
278  virtual void reset();
279 
280  MCContext &getContext() const { return Context; }
281 
282  virtual MCAssembler *getAssemblerPtr() { return nullptr; }
283 
284  void setUseAssemblerInfoForParsing(bool v) { UseAssemblerInfoForParsing = v; }
285  bool getUseAssemblerInfoForParsing() { return UseAssemblerInfoForParsing; }
286 
288  return TargetStreamer.get();
289  }
290 
291  void setAllowAutoPadding(bool v) { AllowAutoPadding = v; }
292  bool getAllowAutoPadding() const { return AllowAutoPadding; }
293 
294  /// When emitting an object file, create and emit a real label. When emitting
295  /// textual assembly, this should do nothing to avoid polluting our output.
296  virtual MCSymbol *emitCFILabel();
297 
298  /// Retrieve the current frame info if one is available and it is not yet
299  /// closed. Otherwise, issue an error and return null.
301 
302  unsigned getNumFrameInfos();
304 
306 
307  unsigned getNumWinFrameInfos() { return WinFrameInfos.size(); }
309  return WinFrameInfos;
310  }
311 
313 
314  /// \name Assembly File Formatting.
315  /// @{
316 
317  /// Return true if this streamer supports verbose assembly and if it is
318  /// enabled.
319  virtual bool isVerboseAsm() const { return false; }
320 
321  /// Return true if this asm streamer supports emitting unformatted text
322  /// to the .s file with EmitRawText.
323  virtual bool hasRawTextSupport() const { return false; }
324 
325  /// Is the integrated assembler required for this streamer to function
326  /// correctly?
327  virtual bool isIntegratedAssemblerRequired() const { return false; }
328 
329  /// Add a textual comment.
330  ///
331  /// Typically for comments that can be emitted to the generated .s
332  /// file if applicable as a QoI issue to make the output of the compiler
333  /// more readable. This only affects the MCAsmStreamer, and only when
334  /// verbose assembly output is enabled.
335  ///
336  /// If the comment includes embedded \n's, they will each get the comment
337  /// prefix as appropriate. The added comment should not end with a \n.
338  /// By default, each comment is terminated with an end of line, i.e. the
339  /// EOL param is set to true by default. If one prefers not to end the
340  /// comment with a new line then the EOL param should be passed
341  /// with a false value.
342  virtual void AddComment(const Twine &T, bool EOL = true) {}
343 
344  /// Return a raw_ostream that comments can be written to. Unlike
345  /// AddComment, you are required to terminate comments with \n if you use this
346  /// method.
347  virtual raw_ostream &GetCommentOS();
348 
349  /// Print T and prefix it with the comment string (normally #) and
350  /// optionally a tab. This prints the comment immediately, not at the end of
351  /// the current line. It is basically a safe version of EmitRawText: since it
352  /// only prints comments, the object streamer ignores it instead of asserting.
353  virtual void emitRawComment(const Twine &T, bool TabPrefix = true);
354 
355  /// Add explicit comment T. T is required to be a valid
356  /// comment in the output and does not need to be escaped.
357  virtual void addExplicitComment(const Twine &T);
358 
359  /// Emit added explicit comments.
360  virtual void emitExplicitComments();
361 
362  /// AddBlankLine - Emit a blank line to a .s file to pretty it up.
363  virtual void AddBlankLine() {}
364 
365  /// @}
366 
367  /// \name Symbol & Section Management
368  /// @{
369 
370  /// Return the current section that the streamer is emitting code to.
372  if (!SectionStack.empty())
373  return SectionStack.back().first;
374  return MCSectionSubPair();
375  }
376  MCSection *getCurrentSectionOnly() const { return getCurrentSection().first; }
377 
378  /// Return the previous section that the streamer is emitting code to.
380  if (!SectionStack.empty())
381  return SectionStack.back().second;
382  return MCSectionSubPair();
383  }
384 
385  /// Returns an index to represent the order a symbol was emitted in.
386  /// (zero if we did not emit that symbol)
387  unsigned GetSymbolOrder(const MCSymbol *Sym) const {
388  return SymbolOrdering.lookup(Sym);
389  }
390 
391  /// Update streamer for a new active section.
392  ///
393  /// This is called by PopSection and SwitchSection, if the current
394  /// section changes.
395  virtual void changeSection(MCSection *, const MCExpr *);
396 
397  /// Save the current and previous section on the section stack.
398  void PushSection() {
399  SectionStack.push_back(
400  std::make_pair(getCurrentSection(), getPreviousSection()));
401  }
402 
403  /// Restore the current and previous section from the section stack.
404  /// Calls changeSection as needed.
405  ///
406  /// Returns false if the stack was empty.
407  bool PopSection() {
408  if (SectionStack.size() <= 1)
409  return false;
410  auto I = SectionStack.end();
411  --I;
412  MCSectionSubPair OldSection = I->first;
413  --I;
414  MCSectionSubPair NewSection = I->first;
415 
416  if (NewSection.first && OldSection != NewSection)
417  changeSection(NewSection.first, NewSection.second);
418  SectionStack.pop_back();
419  return true;
420  }
421 
422  bool SubSection(const MCExpr *Subsection) {
423  if (SectionStack.empty())
424  return false;
425 
426  SwitchSection(SectionStack.back().first.first, Subsection);
427  return true;
428  }
429 
430  /// Set the current section where code is being emitted to \p Section. This
431  /// is required to update CurSection.
432  ///
433  /// This corresponds to assembler directives like .section, .text, etc.
434  virtual void SwitchSection(MCSection *Section,
435  const MCExpr *Subsection = nullptr);
436 
437  /// Set the current section where code is being emitted to \p Section.
438  /// This is required to update CurSection. This version does not call
439  /// changeSection.
441  const MCExpr *Subsection = nullptr) {
442  assert(Section && "Cannot switch to a null section!");
443  MCSectionSubPair curSection = SectionStack.back().first;
444  SectionStack.back().second = curSection;
445  if (MCSectionSubPair(Section, Subsection) != curSection)
446  SectionStack.back().first = MCSectionSubPair(Section, Subsection);
447  }
448 
449  /// Create the default sections and set the initial one.
450  virtual void initSections(bool NoExecStack, const MCSubtargetInfo &STI);
451 
453 
454  /// Sets the symbol's section.
455  ///
456  /// Each emitted symbol will be tracked in the ordering table,
457  /// so we can sort on them later.
458  void AssignFragment(MCSymbol *Symbol, MCFragment *Fragment);
459 
460  /// Returns the mnemonic for \p MI, if the streamer has access to a
461  /// instruction printer and returns an empty string otherwise.
462  virtual StringRef getMnemonic(MCInst &MI) { return ""; }
463 
464  /// Emit a label for \p Symbol into the current section.
465  ///
466  /// This corresponds to an assembler statement such as:
467  /// foo:
468  ///
469  /// \param Symbol - The symbol to emit. A given symbol should only be
470  /// emitted as a label once, and symbols emitted as a label should never be
471  /// used in an assignment.
472  // FIXME: These emission are non-const because we mutate the symbol to
473  // add the section we're emitting it to later.
474  virtual void emitLabel(MCSymbol *Symbol, SMLoc Loc = SMLoc());
475 
476  virtual void emitEHSymAttributes(const MCSymbol *Symbol, MCSymbol *EHSymbol);
477 
478  /// Note in the output the specified \p Flag.
479  virtual void emitAssemblerFlag(MCAssemblerFlag Flag);
480 
481  /// Emit the given list \p Options of strings as linker
482  /// options into the output.
484 
485  /// Note in the output the specified region \p Kind.
487 
488  /// Specify the Mach-O minimum deployment target version.
489  virtual void emitVersionMin(MCVersionMinType Type, unsigned Major,
490  unsigned Minor, unsigned Update,
491  VersionTuple SDKVersion) {}
492 
493  /// Emit/Specify Mach-O build version command.
494  /// \p Platform should be one of MachO::PlatformType.
495  virtual void emitBuildVersion(unsigned Platform, unsigned Major,
496  unsigned Minor, unsigned Update,
497  VersionTuple SDKVersion) {}
498 
499  void emitVersionForTarget(const Triple &Target,
500  const VersionTuple &SDKVersion);
501 
502  /// Note in the output that the specified \p Func is a Thumb mode
503  /// function (ARM target only).
504  virtual void emitThumbFunc(MCSymbol *Func);
505 
506  /// Emit an assignment of \p Value to \p Symbol.
507  ///
508  /// This corresponds to an assembler statement such as:
509  /// symbol = value
510  ///
511  /// The assignment generates no code, but has the side effect of binding the
512  /// value in the current context. For the assembly streamer, this prints the
513  /// binding into the .s file.
514  ///
515  /// \param Symbol - The symbol being assigned to.
516  /// \param Value - The value for the symbol.
517  virtual void emitAssignment(MCSymbol *Symbol, const MCExpr *Value);
518 
519  /// Emit an weak reference from \p Alias to \p Symbol.
520  ///
521  /// This corresponds to an assembler statement such as:
522  /// .weakref alias, symbol
523  ///
524  /// \param Alias - The alias that is being created.
525  /// \param Symbol - The symbol being aliased.
526  virtual void emitWeakReference(MCSymbol *Alias, const MCSymbol *Symbol);
527 
528  /// Add the given \p Attribute to \p Symbol.
529  virtual bool emitSymbolAttribute(MCSymbol *Symbol,
530  MCSymbolAttr Attribute) = 0;
531 
532  /// Set the \p DescValue for the \p Symbol.
533  ///
534  /// \param Symbol - The symbol to have its n_desc field set.
535  /// \param DescValue - The value to set into the n_desc field.
536  virtual void emitSymbolDesc(MCSymbol *Symbol, unsigned DescValue);
537 
538  /// Start emitting COFF symbol definition
539  ///
540  /// \param Symbol - The symbol to have its External & Type fields set.
541  virtual void BeginCOFFSymbolDef(const MCSymbol *Symbol);
542 
543  /// Emit the storage class of the symbol.
544  ///
545  /// \param StorageClass - The storage class the symbol should have.
546  virtual void EmitCOFFSymbolStorageClass(int StorageClass);
547 
548  /// Emit the type of the symbol.
549  ///
550  /// \param Type - A COFF type identifier (see COFF::SymbolType in X86COFF.h)
551  virtual void EmitCOFFSymbolType(int Type);
552 
553  /// Marks the end of the symbol definition.
554  virtual void EndCOFFSymbolDef();
555 
556  virtual void EmitCOFFSafeSEH(MCSymbol const *Symbol);
557 
558  /// Emits the symbol table index of a Symbol into the current section.
559  virtual void EmitCOFFSymbolIndex(MCSymbol const *Symbol);
560 
561  /// Emits a COFF section index.
562  ///
563  /// \param Symbol - Symbol the section number relocation should point to.
564  virtual void EmitCOFFSectionIndex(MCSymbol const *Symbol);
565 
566  /// Emits a COFF section relative relocation.
567  ///
568  /// \param Symbol - Symbol the section relative relocation should point to.
569  virtual void EmitCOFFSecRel32(MCSymbol const *Symbol, uint64_t Offset);
570 
571  /// Emits a COFF image relative relocation.
572  ///
573  /// \param Symbol - Symbol the image relative relocation should point to.
574  virtual void EmitCOFFImgRel32(MCSymbol const *Symbol, int64_t Offset);
575 
576  /// Emits an lcomm directive with XCOFF csect information.
577  ///
578  /// \param LabelSym - Label on the block of storage.
579  /// \param Size - The size of the block of storage.
580  /// \param CsectSym - Csect name for the block of storage.
581  /// \param ByteAlignment - The alignment of the symbol in bytes. Must be a
582  /// power of 2.
583  virtual void emitXCOFFLocalCommonSymbol(MCSymbol *LabelSym, uint64_t Size,
584  MCSymbol *CsectSym,
585  unsigned ByteAlignment);
586 
587  /// Emit a symbol's linkage and visibility with a linkage directive for XCOFF.
588  ///
589  /// \param Symbol - The symbol to emit.
590  /// \param Linkage - The linkage of the symbol to emit.
591  /// \param Visibility - The visibility of the symbol to emit or MCSA_Invalid
592  /// if the symbol does not have an explicit visibility.
595  MCSymbolAttr Visibility);
596 
597  /// Emit a XCOFF .rename directive which creates a synonym for an illegal or
598  /// undesirable name.
599  ///
600  /// \param Name - The name used internally in the assembly for references to
601  /// the symbol.
602  /// \param Rename - The value to which the Name parameter is
603  /// changed at the end of assembly.
604  virtual void emitXCOFFRenameDirective(const MCSymbol *Name, StringRef Rename);
605 
606  /// Emit an ELF .size directive.
607  ///
608  /// This corresponds to an assembler statement such as:
609  /// .size symbol, expression
610  virtual void emitELFSize(MCSymbol *Symbol, const MCExpr *Value);
611 
612  /// Emit an ELF .symver directive.
613  ///
614  /// This corresponds to an assembler statement such as:
615  /// .symver _start, foo@@SOME_VERSION
616  virtual void emitELFSymverDirective(const MCSymbol *OriginalSym,
617  StringRef Name, bool KeepOriginalSym);
618 
619  /// Emit a Linker Optimization Hint (LOH) directive.
620  /// \param Args - Arguments of the LOH.
621  virtual void emitLOHDirective(MCLOHType Kind, const MCLOHArgs &Args) {}
622 
623  /// Emit a .gnu_attribute directive.
624  virtual void emitGNUAttribute(unsigned Tag, unsigned Value) {}
625 
626  /// Emit a common symbol.
627  ///
628  /// \param Symbol - The common symbol to emit.
629  /// \param Size - The size of the common symbol.
630  /// \param ByteAlignment - The alignment of the symbol if
631  /// non-zero. This must be a power of 2.
633  unsigned ByteAlignment) = 0;
634 
635  /// Emit a local common (.lcomm) symbol.
636  ///
637  /// \param Symbol - The common symbol to emit.
638  /// \param Size - The size of the common symbol.
639  /// \param ByteAlignment - The alignment of the common symbol in bytes.
641  unsigned ByteAlignment);
642 
643  /// Emit the zerofill section and an optional symbol.
644  ///
645  /// \param Section - The zerofill section to create and or to put the symbol
646  /// \param Symbol - The zerofill symbol to emit, if non-NULL.
647  /// \param Size - The size of the zerofill symbol.
648  /// \param ByteAlignment - The alignment of the zerofill symbol if
649  /// non-zero. This must be a power of 2 on some targets.
650  virtual void emitZerofill(MCSection *Section, MCSymbol *Symbol = nullptr,
651  uint64_t Size = 0, unsigned ByteAlignment = 0,
652  SMLoc Loc = SMLoc()) = 0;
653 
654  /// Emit a thread local bss (.tbss) symbol.
655  ///
656  /// \param Section - The thread local common section.
657  /// \param Symbol - The thread local common symbol to emit.
658  /// \param Size - The size of the symbol.
659  /// \param ByteAlignment - The alignment of the thread local common symbol
660  /// if non-zero. This must be a power of 2 on some targets.
662  uint64_t Size, unsigned ByteAlignment = 0);
663 
664  /// @}
665  /// \name Generating Data
666  /// @{
667 
668  /// Emit the bytes in \p Data into the output.
669  ///
670  /// This is used to implement assembler directives such as .byte, .ascii,
671  /// etc.
672  virtual void emitBytes(StringRef Data);
673 
674  /// Functionally identical to EmitBytes. When emitting textual assembly, this
675  /// method uses .byte directives instead of .ascii or .asciz for readability.
676  virtual void emitBinaryData(StringRef Data);
677 
678  /// Emit the expression \p Value into the output as a native
679  /// integer of the given \p Size bytes.
680  ///
681  /// This is used to implement assembler directives such as .word, .quad,
682  /// etc.
683  ///
684  /// \param Value - The value to emit.
685  /// \param Size - The size of the integer (in bytes) to emit. This must
686  /// match a native machine width.
687  /// \param Loc - The location of the expression for error reporting.
688  virtual void emitValueImpl(const MCExpr *Value, unsigned Size,
689  SMLoc Loc = SMLoc());
690 
691  void emitValue(const MCExpr *Value, unsigned Size, SMLoc Loc = SMLoc());
692 
693  /// Special case of EmitValue that avoids the client having
694  /// to pass in a MCExpr for constant integers.
695  virtual void emitIntValue(uint64_t Value, unsigned Size);
696  virtual void emitIntValue(APInt Value);
697 
698  /// Special case of EmitValue that avoids the client having to pass
699  /// in a MCExpr for constant integers & prints in Hex format for certain
700  /// modes.
701  virtual void emitIntValueInHex(uint64_t Value, unsigned Size) {
703  }
704 
709 
710  /// Special case of EmitValue that avoids the client having to pass
711  /// in a MCExpr for constant integers & prints in Hex format for certain
712  /// modes, pads the field with leading zeros to Size width
715  }
716 
717  virtual void emitULEB128Value(const MCExpr *Value);
718 
719  virtual void emitSLEB128Value(const MCExpr *Value);
720 
721  /// Special case of EmitULEB128Value that avoids the client having to
722  /// pass in a MCExpr for constant integers.
723  void emitULEB128IntValue(uint64_t Value, unsigned PadTo = 0);
724 
725  /// Special case of EmitSLEB128Value that avoids the client having to
726  /// pass in a MCExpr for constant integers.
727  void emitSLEB128IntValue(int64_t Value);
728 
729  /// Special case of EmitValue that avoids the client having to pass in
730  /// a MCExpr for MCSymbols.
731  void emitSymbolValue(const MCSymbol *Sym, unsigned Size,
732  bool IsSectionRelative = false);
733 
734  /// Emit the expression \p Value into the output as a dtprel
735  /// (64-bit DTP relative) value.
736  ///
737  /// This is used to implement assembler directives such as .dtpreldword on
738  /// targets that support them.
739  virtual void emitDTPRel64Value(const MCExpr *Value);
740 
741  /// Emit the expression \p Value into the output as a dtprel
742  /// (32-bit DTP relative) value.
743  ///
744  /// This is used to implement assembler directives such as .dtprelword on
745  /// targets that support them.
746  virtual void emitDTPRel32Value(const MCExpr *Value);
747 
748  /// Emit the expression \p Value into the output as a tprel
749  /// (64-bit TP relative) value.
750  ///
751  /// This is used to implement assembler directives such as .tpreldword on
752  /// targets that support them.
753  virtual void emitTPRel64Value(const MCExpr *Value);
754 
755  /// Emit the expression \p Value into the output as a tprel
756  /// (32-bit TP relative) value.
757  ///
758  /// This is used to implement assembler directives such as .tprelword on
759  /// targets that support them.
760  virtual void emitTPRel32Value(const MCExpr *Value);
761 
762  /// Emit the expression \p Value into the output as a gprel64 (64-bit
763  /// GP relative) value.
764  ///
765  /// This is used to implement assembler directives such as .gpdword on
766  /// targets that support them.
767  virtual void emitGPRel64Value(const MCExpr *Value);
768 
769  /// Emit the expression \p Value into the output as a gprel32 (32-bit
770  /// GP relative) value.
771  ///
772  /// This is used to implement assembler directives such as .gprel32 on
773  /// targets that support them.
774  virtual void emitGPRel32Value(const MCExpr *Value);
775 
776  /// Emit NumBytes bytes worth of the value specified by FillValue.
777  /// This implements directives such as '.space'.
778  void emitFill(uint64_t NumBytes, uint8_t FillValue);
779 
780  /// Emit \p Size bytes worth of the value specified by \p FillValue.
781  ///
782  /// This is used to implement assembler directives such as .space or .skip.
783  ///
784  /// \param NumBytes - The number of bytes to emit.
785  /// \param FillValue - The value to use when filling bytes.
786  /// \param Loc - The location of the expression for error reporting.
787  virtual void emitFill(const MCExpr &NumBytes, uint64_t FillValue,
788  SMLoc Loc = SMLoc());
789 
790  /// Emit \p NumValues copies of \p Size bytes. Each \p Size bytes is
791  /// taken from the lowest order 4 bytes of \p Expr expression.
792  ///
793  /// This is used to implement assembler directives such as .fill.
794  ///
795  /// \param NumValues - The number of copies of \p Size bytes to emit.
796  /// \param Size - The size (in bytes) of each repeated value.
797  /// \param Expr - The expression from which \p Size bytes are used.
798  virtual void emitFill(const MCExpr &NumValues, int64_t Size, int64_t Expr,
799  SMLoc Loc = SMLoc());
800 
801  virtual void emitNops(int64_t NumBytes, int64_t ControlledNopLength,
802  SMLoc Loc, const MCSubtargetInfo& STI);
803 
804  /// Emit NumBytes worth of zeros.
805  /// This function properly handles data in virtual sections.
806  void emitZeros(uint64_t NumBytes);
807 
808  /// Emit some number of copies of \p Value until the byte alignment \p
809  /// ByteAlignment is reached.
810  ///
811  /// If the number of bytes need to emit for the alignment is not a multiple
812  /// of \p ValueSize, then the contents of the emitted fill bytes is
813  /// undefined.
814  ///
815  /// This used to implement the .align assembler directive.
816  ///
817  /// \param ByteAlignment - The alignment to reach. This must be a power of
818  /// two on some targets.
819  /// \param Value - The value to use when filling bytes.
820  /// \param ValueSize - The size of the integer (in bytes) to emit for
821  /// \p Value. This must match a native machine width.
822  /// \param MaxBytesToEmit - The maximum numbers of bytes to emit, or 0. If
823  /// the alignment cannot be reached in this many bytes, no bytes are
824  /// emitted.
825  virtual void emitValueToAlignment(unsigned ByteAlignment, int64_t Value = 0,
826  unsigned ValueSize = 1,
827  unsigned MaxBytesToEmit = 0);
828 
829  /// Emit nops until the byte alignment \p ByteAlignment is reached.
830  ///
831  /// This used to align code where the alignment bytes may be executed. This
832  /// can emit different bytes for different sizes to optimize execution.
833  ///
834  /// \param ByteAlignment - The alignment to reach. This must be a power of
835  /// two on some targets.
836  /// \param STI - The MCSubtargetInfo in operation when padding is emitted.
837  /// \param MaxBytesToEmit - The maximum numbers of bytes to emit, or 0. If
838  /// the alignment cannot be reached in this many bytes, no bytes are
839  /// emitted.
840  virtual void emitCodeAlignment(unsigned ByteAlignment,
841  const MCSubtargetInfo *STI,
842  unsigned MaxBytesToEmit = 0);
843 
844  /// Emit some number of copies of \p Value until the byte offset \p
845  /// Offset is reached.
846  ///
847  /// This is used to implement assembler directives such as .org.
848  ///
849  /// \param Offset - The offset to reach. This may be an expression, but the
850  /// expression must be associated with the current section.
851  /// \param Value - The value to use when filling bytes.
852  virtual void emitValueToOffset(const MCExpr *Offset, unsigned char Value,
853  SMLoc Loc);
854 
855  /// @}
856 
857  /// Switch to a new logical file. This is used to implement the '.file
858  /// "foo.c"' assembler directive.
859  virtual void emitFileDirective(StringRef Filename);
860 
861  /// Emit ".file assembler diretive with additioal info.
862  virtual void emitFileDirective(StringRef Filename, StringRef CompilerVerion,
863  StringRef TimeStamp, StringRef Description);
864 
865  /// Emit the "identifiers" directive. This implements the
866  /// '.ident "version foo"' assembler directive.
867  virtual void emitIdent(StringRef IdentString) {}
868 
869  /// Associate a filename with a specified logical file number. This
870  /// implements the DWARF2 '.file 4 "foo.c"' assembler directive.
871  unsigned emitDwarfFileDirective(unsigned FileNo, StringRef Directory,
872  StringRef Filename,
873  Optional<MD5::MD5Result> Checksum = None,
875  unsigned CUID = 0) {
876  return cantFail(
877  tryEmitDwarfFileDirective(FileNo, Directory, Filename, Checksum,
878  Source, CUID));
879  }
880 
881  /// Associate a filename with a specified logical file number.
882  /// Also associate a directory, optional checksum, and optional source
883  /// text with the logical file. This implements the DWARF2
884  /// '.file 4 "dir/foo.c"' assembler directive, and the DWARF5
885  /// '.file 4 "dir/foo.c" md5 "..." source "..."' assembler directive.
887  unsigned FileNo, StringRef Directory, StringRef Filename,
889  unsigned CUID = 0);
890 
891  /// Specify the "root" file of the compilation, using the ".file 0" extension.
892  virtual void emitDwarfFile0Directive(StringRef Directory, StringRef Filename,
893  Optional<MD5::MD5Result> Checksum,
895  unsigned CUID = 0);
896 
897  virtual void emitCFIBKeyFrame();
898 
899  /// This implements the DWARF2 '.loc fileno lineno ...' assembler
900  /// directive.
901  virtual void emitDwarfLocDirective(unsigned FileNo, unsigned Line,
902  unsigned Column, unsigned Flags,
903  unsigned Isa, unsigned Discriminator,
904  StringRef FileName);
905 
906  /// Associate a filename with a specified logical file number, and also
907  /// specify that file's checksum information. This implements the '.cv_file 4
908  /// "foo.c"' assembler directive. Returns true on success.
909  virtual bool EmitCVFileDirective(unsigned FileNo, StringRef Filename,
910  ArrayRef<uint8_t> Checksum,
911  unsigned ChecksumKind);
912 
913  /// Introduces a function id for use with .cv_loc.
914  virtual bool EmitCVFuncIdDirective(unsigned FunctionId);
915 
916  /// Introduces an inline call site id for use with .cv_loc. Includes
917  /// extra information for inline line table generation.
918  virtual bool EmitCVInlineSiteIdDirective(unsigned FunctionId, unsigned IAFunc,
919  unsigned IAFile, unsigned IALine,
920  unsigned IACol, SMLoc Loc);
921 
922  /// This implements the CodeView '.cv_loc' assembler directive.
923  virtual void emitCVLocDirective(unsigned FunctionId, unsigned FileNo,
924  unsigned Line, unsigned Column,
925  bool PrologueEnd, bool IsStmt,
926  StringRef FileName, SMLoc Loc);
927 
928  /// This implements the CodeView '.cv_linetable' assembler directive.
929  virtual void emitCVLinetableDirective(unsigned FunctionId,
930  const MCSymbol *FnStart,
931  const MCSymbol *FnEnd);
932 
933  /// This implements the CodeView '.cv_inline_linetable' assembler
934  /// directive.
935  virtual void emitCVInlineLinetableDirective(unsigned PrimaryFunctionId,
936  unsigned SourceFileId,
937  unsigned SourceLineNum,
938  const MCSymbol *FnStartSym,
939  const MCSymbol *FnEndSym);
940 
941  /// This implements the CodeView '.cv_def_range' assembler
942  /// directive.
943  virtual void emitCVDefRangeDirective(
944  ArrayRef<std::pair<const MCSymbol *, const MCSymbol *>> Ranges,
945  StringRef FixedSizePortion);
946 
947  virtual void emitCVDefRangeDirective(
948  ArrayRef<std::pair<const MCSymbol *, const MCSymbol *>> Ranges,
950 
951  virtual void emitCVDefRangeDirective(
952  ArrayRef<std::pair<const MCSymbol *, const MCSymbol *>> Ranges,
954 
955  virtual void emitCVDefRangeDirective(
956  ArrayRef<std::pair<const MCSymbol *, const MCSymbol *>> Ranges,
958 
959  virtual void emitCVDefRangeDirective(
960  ArrayRef<std::pair<const MCSymbol *, const MCSymbol *>> Ranges,
962 
963  /// This implements the CodeView '.cv_stringtable' assembler directive.
964  virtual void emitCVStringTableDirective() {}
965 
966  /// This implements the CodeView '.cv_filechecksums' assembler directive.
968 
969  /// This implements the CodeView '.cv_filechecksumoffset' assembler
970  /// directive.
971  virtual void emitCVFileChecksumOffsetDirective(unsigned FileNo) {}
972 
973  /// This implements the CodeView '.cv_fpo_data' assembler directive.
974  virtual void EmitCVFPOData(const MCSymbol *ProcSym, SMLoc Loc = {}) {}
975 
976  /// Emit the absolute difference between two symbols.
977  ///
978  /// \pre Offset of \c Hi is greater than the offset \c Lo.
979  virtual void emitAbsoluteSymbolDiff(const MCSymbol *Hi, const MCSymbol *Lo,
980  unsigned Size);
981 
982  /// Emit the absolute difference between two symbols encoded with ULEB128.
983  virtual void emitAbsoluteSymbolDiffAsULEB128(const MCSymbol *Hi,
984  const MCSymbol *Lo);
985 
986  virtual MCSymbol *getDwarfLineTableSymbol(unsigned CUID);
987  virtual void emitCFISections(bool EH, bool Debug);
988  void emitCFIStartProc(bool IsSimple, SMLoc Loc = SMLoc());
989  void emitCFIEndProc();
990  virtual void emitCFIDefCfa(int64_t Register, int64_t Offset);
991  virtual void emitCFIDefCfaOffset(int64_t Offset);
992  virtual void emitCFIDefCfaRegister(int64_t Register);
993  virtual void emitCFILLVMDefAspaceCfa(int64_t Register, int64_t Offset,
994  int64_t AddressSpace);
995  virtual void emitCFIOffset(int64_t Register, int64_t Offset);
996  virtual void emitCFIPersonality(const MCSymbol *Sym, unsigned Encoding);
997  virtual void emitCFILsda(const MCSymbol *Sym, unsigned Encoding);
998  virtual void emitCFIRememberState();
999  virtual void emitCFIRestoreState();
1000  virtual void emitCFISameValue(int64_t Register);
1001  virtual void emitCFIRestore(int64_t Register);
1002  virtual void emitCFIRelOffset(int64_t Register, int64_t Offset);
1003  virtual void emitCFIAdjustCfaOffset(int64_t Adjustment);
1004  virtual void emitCFIEscape(StringRef Values);
1005  virtual void emitCFIReturnColumn(int64_t Register);
1006  virtual void emitCFIGnuArgsSize(int64_t Size);
1007  virtual void emitCFISignalFrame();
1008  virtual void emitCFIUndefined(int64_t Register);
1009  virtual void emitCFIRegister(int64_t Register1, int64_t Register2);
1010  virtual void emitCFIWindowSave();
1011  virtual void emitCFINegateRAState();
1012 
1013  virtual void EmitWinCFIStartProc(const MCSymbol *Symbol, SMLoc Loc = SMLoc());
1014  virtual void EmitWinCFIEndProc(SMLoc Loc = SMLoc());
1015  /// This is used on platforms, such as Windows on ARM64, that require function
1016  /// or funclet sizes to be emitted in .xdata before the End marker is emitted
1017  /// for the frame. We cannot use the End marker, as it is not set at the
1018  /// point of emitting .xdata, in order to indicate that the frame is active.
1019  virtual void EmitWinCFIFuncletOrFuncEnd(SMLoc Loc = SMLoc());
1020  virtual void EmitWinCFIStartChained(SMLoc Loc = SMLoc());
1021  virtual void EmitWinCFIEndChained(SMLoc Loc = SMLoc());
1022  virtual void EmitWinCFIPushReg(MCRegister Register, SMLoc Loc = SMLoc());
1023  virtual void EmitWinCFISetFrame(MCRegister Register, unsigned Offset,
1024  SMLoc Loc = SMLoc());
1025  virtual void EmitWinCFIAllocStack(unsigned Size, SMLoc Loc = SMLoc());
1026  virtual void EmitWinCFISaveReg(MCRegister Register, unsigned Offset,
1027  SMLoc Loc = SMLoc());
1028  virtual void EmitWinCFISaveXMM(MCRegister Register, unsigned Offset,
1029  SMLoc Loc = SMLoc());
1030  virtual void EmitWinCFIPushFrame(bool Code, SMLoc Loc = SMLoc());
1031  virtual void EmitWinCFIEndProlog(SMLoc Loc = SMLoc());
1032  virtual void EmitWinEHHandler(const MCSymbol *Sym, bool Unwind, bool Except,
1033  SMLoc Loc = SMLoc());
1034  virtual void EmitWinEHHandlerData(SMLoc Loc = SMLoc());
1035 
1036  virtual void emitCGProfileEntry(const MCSymbolRefExpr *From,
1037  const MCSymbolRefExpr *To, uint64_t Count);
1038 
1039  /// Get the .pdata section used for the given section. Typically the given
1040  /// section is either the main .text section or some other COMDAT .text
1041  /// section, but it may be any section containing code.
1042  MCSection *getAssociatedPDataSection(const MCSection *TextSec);
1043 
1044  /// Get the .xdata section used for the given section.
1045  MCSection *getAssociatedXDataSection(const MCSection *TextSec);
1046 
1047  virtual void emitSyntaxDirective();
1048 
1049  /// Record a relocation described by the .reloc directive. Return None if
1050  /// succeeded. Otherwise, return a pair (Name is invalid, error message).
1051  virtual Optional<std::pair<bool, std::string>>
1053  SMLoc Loc, const MCSubtargetInfo &STI) {
1054  return None;
1055  }
1056 
1057  virtual void emitAddrsig() {}
1058  virtual void emitAddrsigSym(const MCSymbol *Sym) {}
1059 
1060  /// Emit the given \p Instruction into the current section.
1061  virtual void emitInstruction(const MCInst &Inst, const MCSubtargetInfo &STI);
1062 
1063  /// Emit the a pseudo probe into the current section.
1064  virtual void emitPseudoProbe(uint64_t Guid, uint64_t Index, uint64_t Type,
1065  uint64_t Attr,
1066  const MCPseudoProbeInlineStack &InlineStack);
1067 
1068  /// Set the bundle alignment mode from now on in the section.
1069  /// The argument is the power of 2 to which the alignment is set. The
1070  /// value 0 means turn the bundle alignment off.
1071  virtual void emitBundleAlignMode(unsigned AlignPow2);
1072 
1073  /// The following instructions are a bundle-locked group.
1074  ///
1075  /// \param AlignToEnd - If true, the bundle-locked group will be aligned to
1076  /// the end of a bundle.
1077  virtual void emitBundleLock(bool AlignToEnd);
1078 
1079  /// Ends a bundle-locked group.
1080  virtual void emitBundleUnlock();
1081 
1082  /// If this file is backed by a assembly streamer, this dumps the
1083  /// specified string in the output .s file. This capability is indicated by
1084  /// the hasRawTextSupport() predicate. By default this aborts.
1085  void emitRawText(const Twine &String);
1086 
1087  /// Streamer specific finalization.
1088  virtual void finishImpl();
1089  /// Finish emission of machine code.
1090  void Finish(SMLoc EndLoc = SMLoc());
1091 
1092  virtual bool mayHaveInstructions(MCSection &Sec) const { return true; }
1093 
1094  /// Emit a special value of 0xffffffff if producing 64-bit debugging info.
1095  void maybeEmitDwarf64Mark();
1096 
1097  /// Emit a unit length field. The actual format, DWARF32 or DWARF64, is chosen
1098  /// according to the settings.
1099  virtual void emitDwarfUnitLength(uint64_t Length, const Twine &Comment);
1100 
1101  /// Emit a unit length field. The actual format, DWARF32 or DWARF64, is chosen
1102  /// according to the settings.
1103  /// Return the end symbol generated inside, the caller needs to emit it.
1104  virtual MCSymbol *emitDwarfUnitLength(const Twine &Prefix,
1105  const Twine &Comment);
1106 
1107  /// Emit the debug line start label.
1108  virtual void emitDwarfLineStartLabel(MCSymbol *StartSym);
1109 
1110  /// Emit the debug line end entry.
1111  virtual void emitDwarfLineEndEntry(MCSection *Section, MCSymbol *LastLabel) {}
1112 
1113  /// If targets does not support representing debug line section by .loc/.file
1114  /// directives in assembly output, we need to populate debug line section with
1115  /// raw debug line contents.
1116  virtual void emitDwarfAdvanceLineAddr(int64_t LineDelta,
1117  const MCSymbol *LastLabel,
1118  const MCSymbol *Label,
1119  unsigned PointerSize) {}
1120 
1121  /// Do finalization for the streamer at the end of a section.
1123 };
1124 
1125 /// Create a dummy machine code streamer, which does nothing. This is useful for
1126 /// timing the assembler front end.
1127 MCStreamer *createNullStreamer(MCContext &Ctx);
1128 
1129 } // end namespace llvm
1130 
1131 #endif // LLVM_MC_MCSTREAMER_H
llvm::Check::Size
@ Size
Definition: FileCheck.h:73
llvm::MCStreamer::setUseAssemblerInfoForParsing
void setUseAssemblerInfoForParsing(bool v)
Definition: MCStreamer.h:284
llvm::MCStreamer::emitCVInlineLinetableDirective
virtual void emitCVInlineLinetableDirective(unsigned PrimaryFunctionId, unsigned SourceFileId, unsigned SourceLineNum, const MCSymbol *FnStartSym, const MCSymbol *FnEndSym)
This implements the CodeView '.cv_inline_linetable' assembler directive.
Definition: MCStreamer.cpp:342
llvm::MCTargetStreamer::getStreamer
MCStreamer & getStreamer()
Definition: MCStreamer.h:99
llvm::ARMTargetStreamer::emitCantUnwind
virtual void emitCantUnwind()
Definition: ARMTargetStreamer.cpp:92
llvm::MCStreamer::EmitCOFFSymbolIndex
virtual void EmitCOFFSymbolIndex(MCSymbol const *Symbol)
Emits the symbol table index of a Symbol into the current section.
Definition: MCStreamer.cpp:962
llvm::MCStreamer::emitCVFileChecksumsDirective
virtual void emitCVFileChecksumsDirective()
This implements the CodeView '.cv_filechecksums' assembler directive.
Definition: MCStreamer.h:967
llvm::MCStreamer::emitCFIDefCfaOffset
virtual void emitCFIDefCfaOffset(int64_t Offset)
Definition: MCStreamer.cpp:492
llvm::MCVersionMinType
MCVersionMinType
Definition: MCDirectives.h:66
llvm::MCStreamer::emitDataRegion
virtual void emitDataRegion(MCDataRegionType Kind)
Note in the output the specified region Kind.
Definition: MCStreamer.h:486
llvm::MCStreamer::getAssociatedXDataSection
MCSection * getAssociatedXDataSection(const MCSection *TextSec)
Get the .xdata section used for the given section.
Definition: MCStreamer.cpp:841
llvm::MCStreamer::visitUsedExpr
void visitUsedExpr(const MCExpr &Expr)
Definition: MCStreamer.cpp:1061
llvm::MCTargetStreamer::changeSection
virtual void changeSection(const MCSection *CurSection, MCSection *Section, const MCExpr *SubSection, raw_ostream &OS)
Update streamer for a new active section.
Definition: MCStreamer.cpp:58
MI
IRTranslator LLVM IR MI
Definition: IRTranslator.cpp:105
llvm
This file implements support for optimizing divisions by a constant.
Definition: AllocatorList.h:23
llvm::MCStreamer::EmitCOFFSymbolStorageClass
virtual void EmitCOFFSymbolStorageClass(int StorageClass)
Emit the storage class of the symbol.
Definition: MCStreamer.cpp:1155
llvm::MCDataRegionType
MCDataRegionType
Definition: MCDirectives.h:58
Reg
unsigned Reg
Definition: MachineSink.cpp:1566
llvm::MCTargetStreamer::emitLabel
virtual void emitLabel(MCSymbol *Symbol)
Definition: MCStreamer.cpp:52
llvm::MCStreamer::emitCFILLVMDefAspaceCfa
virtual void emitCFILLVMDefAspaceCfa(int64_t Register, int64_t Offset, int64_t AddressSpace)
Definition: MCStreamer.cpp:523
llvm::MCSymbol
MCSymbol - Instances of this class represent a symbol name in the MC file, and MCSymbols are created ...
Definition: MCSymbol.h:41
llvm::MCStreamer::setTargetStreamer
void setTargetStreamer(MCTargetStreamer *TS)
Definition: MCStreamer.h:267
llvm::ARMTargetStreamer::emitFnEnd
virtual void emitFnEnd()
Definition: ARMTargetStreamer.cpp:91
Optional.h
llvm::MCStreamer::EndCOFFSymbolDef
virtual void EndCOFFSymbolDef()
Marks the end of the symbol definition.
Definition: MCStreamer.cpp:1148
llvm::MCStreamer::emitCFIOffset
virtual void emitCFIOffset(int64_t Register, int64_t Offset)
Definition: MCStreamer.cpp:535
llvm::MCStreamer::EmitWinEHHandlerData
virtual void EmitWinEHHandlerData(SMLoc Loc=SMLoc())
Definition: MCStreamer.cpp:789
llvm::MCStreamer::EmitCVFileDirective
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 info...
Definition: MCStreamer.cpp:286
llvm::MCStreamer::emitAbsoluteSymbolDiffAsULEB128
virtual void emitAbsoluteSymbolDiffAsULEB128(const MCSymbol *Hi, const MCSymbol *Lo)
Emit the absolute difference between two symbols encoded with ULEB128.
Definition: MCStreamer.cpp:1132
llvm::cl::Prefix
@ Prefix
Definition: CommandLine.h:164
llvm::MCStreamer::getUseAssemblerInfoForParsing
bool getUseAssemblerInfoForParsing()
Definition: MCStreamer.h:285
llvm::MCTargetStreamer::emitRawBytes
virtual void emitRawBytes(StringRef Data)
Emit the bytes in Data into the output.
Definition: MCStreamer.cpp:79
llvm::MCContext
Context object for machine code objects.
Definition: MCContext.h:72
llvm::Attribute
Definition: Attributes.h:52
llvm::MCLOHType
MCLOHType
Linker Optimization Hint Type.
Definition: MCLinkerOptimizationHint.h:33
llvm::DenseMapBase::lookup
ValueT lookup(const_arg_type_t< KeyT > Val) const
lookup - Return the entry for the specified key, or a default constructed value if no such entry exis...
Definition: DenseMap.h:197
llvm::ARMTargetStreamer
Definition: MCStreamer.h:133
llvm::MCStreamer::emitTPRel32Value
virtual void emitTPRel32Value(const MCExpr *Value)
Emit the expression Value into the output as a tprel (32-bit TP relative) value.
Definition: MCStreamer.cpp:204
llvm::MCStreamer::emitELFSize
virtual void emitELFSize(MCSymbol *Symbol, const MCExpr *Value)
Emit an ELF .size directive.
Definition: MCStreamer.cpp:1180
StringRef.h
llvm::MCStreamer::EmitWinCFISaveReg
virtual void EmitWinCFISaveReg(MCRegister Register, unsigned Offset, SMLoc Loc=SMLoc())
Definition: MCStreamer.cpp:904
llvm::ARMTargetStreamer::emitPersonality
virtual void emitPersonality(const MCSymbol *Personality)
Definition: ARMTargetStreamer.cpp:93
llvm::MCStreamer::EmitWinCFISaveXMM
virtual void EmitWinCFISaveXMM(MCRegister Register, unsigned Offset, SMLoc Loc=SMLoc())
Definition: MCStreamer.cpp:921
llvm::MCStreamer::emitCFISections
virtual void emitCFISections(bool EH, bool Debug)
Definition: MCStreamer.cpp:434
llvm::MCStreamer::emitInt64
void emitInt64(uint64_t Value)
Definition: MCStreamer.h:708
MCDirectives.h
llvm::Target
Target - Wrapper for Target specific information.
Definition: TargetRegistry.h:137
llvm::MCStreamer::hasRawTextSupport
virtual bool hasRawTextSupport() const
Return true if this asm streamer supports emitting unformatted text to the .s file with EmitRawText.
Definition: MCStreamer.h:323
llvm::codeview::DefRangeFramePointerRelHeader
Definition: SymbolRecord.h:525
llvm::MCStreamer::emitInt8
void emitInt8(uint64_t Value)
Definition: MCStreamer.h:705
llvm::SmallVector
This is a 'vector' (really, a variable-sized array), optimized for the case when the array is small.
Definition: SmallVector.h:1168
llvm::MCStreamer::emitCFIStartProc
void emitCFIStartProc(bool IsSimple, SMLoc Loc=SMLoc())
Definition: MCStreamer.cpp:436
llvm::MipsISD::Lo
@ Lo
Definition: MipsISelLowering.h:79
VersionTuple.h
llvm::MCStreamer::emitVersionMin
virtual void emitVersionMin(MCVersionMinType Type, unsigned Major, unsigned Minor, unsigned Update, VersionTuple SDKVersion)
Specify the Mach-O minimum deployment target version.
Definition: MCStreamer.h:489
llvm::MCStreamer::emitAddrsigSym
virtual void emitAddrsigSym(const MCSymbol *Sym)
Definition: MCStreamer.h:1058
llvm::MCStreamer::EmitCOFFSecRel32
virtual void EmitCOFFSecRel32(MCSymbol const *Symbol, uint64_t Offset)
Emits a COFF section relative relocation.
Definition: MCStreamer.cpp:966
llvm::MCTargetStreamer::finish
virtual void finish()
Definition: MCStreamer.cpp:54
llvm::MCStreamer::Finish
void Finish(SMLoc EndLoc=SMLoc())
Finish emission of machine code.
Definition: MCStreamer.cpp:993
llvm::MCStreamer::emitCFIRegister
virtual void emitCFIRegister(int64_t Register1, int64_t Register2)
Definition: MCStreamer.cpp:647
Error.h
llvm::Triple
Triple - Helper class for working with autoconf configuration names.
Definition: Triple.h:45
llvm::MCStreamer::emitXCOFFSymbolLinkageWithVisibility
virtual void emitXCOFFSymbolLinkageWithVisibility(MCSymbol *Symbol, MCSymbolAttr Linkage, MCSymbolAttr Visibility)
Emit a symbol's linkage and visibility with a linkage directive for XCOFF.
Definition: MCStreamer.cpp:1167
llvm::MCStreamer::emitCVLinetableDirective
virtual void emitCVLinetableDirective(unsigned FunctionId, const MCSymbol *FnStart, const MCSymbol *FnEnd)
This implements the CodeView '.cv_linetable' assembler directive.
Definition: MCStreamer.cpp:338
llvm::MCStreamer::emitValue
void emitValue(const MCExpr *Value, unsigned Size, SMLoc Loc=SMLoc())
Definition: MCStreamer.cpp:177
APInt.h
llvm::MCStreamer::emitValueImpl
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.
Definition: MCStreamer.cpp:1191
llvm::MCStreamer::EmitWinCFIEndProc
virtual void EmitWinCFIEndProc(SMLoc Loc=SMLoc())
Definition: MCStreamer.cpp:716
llvm::Type
The instances of the Type class are immutable: once they are created, they are never changed.
Definition: Type.h:45
llvm::MCStreamer::emitCFISignalFrame
virtual void emitCFISignalFrame()
Definition: MCStreamer.cpp:630
DenseMap.h
llvm::MCStreamer::emitXCOFFRenameDirective
virtual void emitXCOFFRenameDirective(const MCSymbol *Name, StringRef Rename)
Emit a XCOFF .rename directive which creates a synonym for an illegal or undesirable name.
Definition: MCStreamer.cpp:1174
llvm::MCStreamer::emitCFILabel
virtual MCSymbol * emitCFILabel()
When emitting an object file, create and emit a real label.
Definition: MCStreamer.cpp:475
llvm::MCStreamer::EmitCVInlineSiteIdDirective
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.
Definition: MCStreamer.cpp:297
llvm::MCStreamer::emitPseudoProbe
virtual void emitPseudoProbe(uint64_t Guid, uint64_t Index, uint64_t Type, uint64_t Attr, const MCPseudoProbeInlineStack &InlineStack)
Emit the a pseudo probe into the current section.
Definition: MCStreamer.cpp:1094
llvm::MCStreamer::emitInt32
void emitInt32(uint64_t Value)
Definition: MCStreamer.h:707
MCPseudoProbe.h
llvm::MCStreamer::setAllowAutoPadding
void setAllowAutoPadding(bool v)
Definition: MCStreamer.h:291
llvm::ARMTargetStreamer::ARMTargetStreamer
ARMTargetStreamer(MCStreamer &S)
Definition: ARMTargetStreamer.cpp:29
llvm::Optional
Definition: APInt.h:33
llvm::MCStreamer::AddBlankLine
virtual void AddBlankLine()
AddBlankLine - Emit a blank line to a .s file to pretty it up.
Definition: MCStreamer.h:363
Offset
uint64_t Offset
Definition: ELFObjHandler.cpp:81
llvm::MCTargetStreamer::MCTargetStreamer
MCTargetStreamer(MCStreamer &S)
Definition: MCStreamer.cpp:45
llvm::MCStreamer::emitCVLocDirective
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.
Definition: MCStreamer.cpp:311
llvm::MCStreamer::emitDTPRel32Value
virtual void emitDTPRel32Value(const MCExpr *Value)
Emit the expression Value into the output as a dtprel (32-bit DTP relative) value.
Definition: MCStreamer.cpp:196
llvm::MCStreamer::emitLinkerOptions
virtual void emitLinkerOptions(ArrayRef< std::string > Kind)
Emit the given list Options of strings as linker options into the output.
Definition: MCStreamer.h:483
llvm::MCStreamer::getCurrentSection
MCSectionSubPair getCurrentSection() const
Return the current section that the streamer is emitting code to.
Definition: MCStreamer.h:371
llvm::Expected
Tagged union holding either a T or a Error.
Definition: APFloat.h:42
llvm::MCInst
Instances of this class represent a single low-level machine instruction.
Definition: MCInst.h:184
TargetParser.h
llvm::MCAssemblerFlag
MCAssemblerFlag
Definition: MCDirectives.h:50
llvm::ARMTargetStreamer::reset
virtual void reset()
Reset any state between object emissions, i.e.
Definition: ARMTargetStreamer.cpp:51
llvm::MCStreamer::getAllowAutoPadding
bool getAllowAutoPadding() const
Definition: MCStreamer.h:292
llvm::MCStreamer::emitAddrsig
virtual void emitAddrsig()
Definition: MCStreamer.h:1057
llvm::Data
@ Data
Definition: SIMachineScheduler.h:55
llvm::ARMTargetStreamer::emitPad
virtual void emitPad(int64_t Offset)
Definition: ARMTargetStreamer.cpp:99
llvm::MCStreamer::emitDwarfUnitLength
virtual void emitDwarfUnitLength(uint64_t Length, const Twine &Comment)
Emit a unit length field.
Definition: MCStreamer.cpp:1014
llvm::MCStreamer::emitCFIDefCfaRegister
virtual void emitCFIDefCfaRegister(int64_t Register)
Definition: MCStreamer.cpp:512
llvm::MCStreamer::emitCFIAdjustCfaOffset
virtual void emitCFIAdjustCfaOffset(int64_t Adjustment)
Definition: MCStreamer.cpp:502
llvm::MCSymbolAttr
MCSymbolAttr
Definition: MCDirectives.h:18
llvm::MCStreamer::MCStreamer
MCStreamer(MCContext &Ctx)
Definition: MCStreamer.cpp:93
llvm::MCStreamer::emitCFIPersonality
virtual void emitCFIPersonality(const MCSymbol *Sym, unsigned Encoding)
Definition: MCStreamer.cpp:555
llvm::MCStreamer::changeSection
virtual void changeSection(MCSection *, const MCExpr *)
Update streamer for a new active section.
Definition: MCStreamer.cpp:1187
llvm::MCStreamer::EnsureValidWinFrameInfo
WinEH::FrameInfo * EnsureValidWinFrameInfo(SMLoc Loc)
Retrieve the current frame info if one is available and it is not yet closed.
Definition: MCStreamer.cpp:683
llvm::MipsISD::Hi
@ Hi
Definition: MipsISelLowering.h:75
llvm::MCStreamer::emitDTPRel64Value
virtual void emitDTPRel64Value(const MCExpr *Value)
Emit the expression Value into the output as a dtprel (64-bit DTP relative) value.
Definition: MCStreamer.cpp:192
llvm::MCStreamer::emitBundleLock
virtual void emitBundleLock(bool AlignToEnd)
The following instructions are a bundle-locked group.
Definition: MCStreamer.cpp:1208
Context
LLVMContext & Context
Definition: NVVMIntrRange.cpp:66
llvm::ARMBuildAttrs::Section
@ Section
Legacy Tags.
Definition: ARMBuildAttributes.h:78
llvm::MCStreamer::emitCFIEndProcImpl
virtual void emitCFIEndProcImpl(MCDwarfFrameInfo &CurFrame)
Definition: MCStreamer.cpp:469
llvm::MCFragment
Definition: MCFragment.h:31
llvm::MCStreamer
Streaming machine code generation interface.
Definition: MCStreamer.h:199
llvm::MCStreamer::emitULEB128Value
virtual void emitULEB128Value(const MCExpr *Value)
Definition: MCStreamer.cpp:1194
llvm::MCStreamer::emitGPRel64Value
virtual void emitGPRel64Value(const MCExpr *Value)
Emit the expression Value into the output as a gprel64 (64-bit GP relative) value.
Definition: MCStreamer.cpp:208
llvm::ARMTargetStreamer::emitRegSave
virtual void emitRegSave(const SmallVectorImpl< unsigned > &RegList, bool isVector)
Definition: ARMTargetStreamer.cpp:100
llvm::MCStreamer::emitCFIUndefined
virtual void emitCFIUndefined(int64_t Register)
Definition: MCStreamer.cpp:637
llvm::MCStreamer::getPreviousSection
MCSectionSubPair getPreviousSection() const
Return the previous section that the streamer is emitting code to.
Definition: MCStreamer.h:379
llvm::MCAsmBackend
Generic interface to target specific assembler backends.
Definition: MCAsmBackend.h:36
llvm::ARMTargetStreamer::AnnotateTLSDescriptorSequence
virtual void AnnotateTLSDescriptorSequence(const MCSymbolRefExpr *SRE)
Definition: ARMTargetStreamer.cpp:118
llvm::SMLoc
Represents a location in source code.
Definition: SMLoc.h:23
llvm::MCStreamer::emitCFIRelOffset
virtual void emitCFIRelOffset(int64_t Register, int64_t Offset)
Definition: MCStreamer.cpp:545
llvm::ARMTargetStreamer::emitInst
virtual void emitInst(uint32_t Inst, char Suffix='\0')
Definition: ARMTargetStreamer.cpp:53
llvm::MCStreamer::emitCFISameValue
virtual void emitCFISameValue(int64_t Register)
Definition: MCStreamer.cpp:591
MD5.h
llvm::MCStreamer::SubSection
bool SubSection(const MCExpr *Subsection)
Definition: MCStreamer.h:422
llvm::MCStreamer::getMnemonic
virtual StringRef getMnemonic(MCInst &MI)
Returns the mnemonic for MI, if the streamer has access to a instruction printer and returns an empty...
Definition: MCStreamer.h:462
llvm::MCStreamer::getAssociatedPDataSection
MCSection * getAssociatedPDataSection(const MCSection *TextSec)
Get the .pdata section used for the given section.
Definition: MCStreamer.cpp:835
llvm::MCStreamer::EmitCOFFSectionIndex
virtual void EmitCOFFSectionIndex(MCSymbol const *Symbol)
Emits a COFF section index.
Definition: MCStreamer.cpp:964
llvm::MCStreamer::emitCFIStartProcImpl
virtual void emitCFIStartProcImpl(MCDwarfFrameInfo &Frame)
Definition: MCStreamer.cpp:459
llvm::MCStreamer::emitRelocDirective
virtual Optional< std::pair< bool, std::string > > emitRelocDirective(const MCExpr &Offset, StringRef Name, const MCExpr *Expr, SMLoc Loc, const MCSubtargetInfo &STI)
Record a relocation described by the .reloc directive.
Definition: MCStreamer.h:1052
llvm::MCStreamer::operator=
MCStreamer & operator=(const MCStreamer &)=delete
llvm::MCStreamer::emitLabel
virtual void emitLabel(MCSymbol *Symbol, SMLoc Loc=SMLoc())
Emit a label for Symbol into the current section.
Definition: MCStreamer.cpp:415
MCSymbol.h
llvm::MCStreamer::emitSymbolValue
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.
Definition: MCStreamer.cpp:181
llvm::MCStreamer::emitIntValueInHexWithPadding
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 & p...
Definition: MCStreamer.h:713
llvm::ARMTargetStreamer::emitArch
virtual void emitArch(ARM::ArchKind Arch)
Definition: ARMTargetStreamer.cpp:112
llvm::MCStreamer::emitBuildVersion
virtual void emitBuildVersion(unsigned Platform, unsigned Major, unsigned Minor, unsigned Update, VersionTuple SDKVersion)
Emit/Specify Mach-O build version command.
Definition: MCStreamer.h:495
llvm::MCStreamer::emitAssemblerFlag
virtual void emitAssemblerFlag(MCAssemblerFlag Flag)
Note in the output the specified Flag.
Definition: MCStreamer.cpp:1142
llvm::MCStreamer::hasUnfinishedDwarfFrameInfo
bool hasUnfinishedDwarfFrameInfo()
Definition: MCStreamer.cpp:272
llvm::MCStreamer::finishImpl
virtual void finishImpl()
Streamer specific finalization.
Definition: MCStreamer.cpp:1209
llvm::MCTargetStreamer::emitConstantPools
virtual void emitConstantPools()
Definition: MCStreamer.cpp:56
llvm::MCID::Flag
Flag
These should be considered private to the implementation of the MCInstrDesc class.
Definition: MCInstrDesc.h:146
llvm::MCStreamer::emitAssignment
virtual void emitAssignment(MCSymbol *Symbol, const MCExpr *Value)
Emit an assignment of Value to Symbol.
Definition: MCStreamer.cpp:1042
SMLoc.h
llvm::MCStreamer::emitRawComment
virtual void emitRawComment(const Twine &T, bool TabPrefix=true)
Print T and prefix it with the comment string (normally #) and optionally a tab.
Definition: MCStreamer.cpp:120
llvm::raw_ostream
This class implements an extremely fast bulk output stream that can only output to a stream.
Definition: raw_ostream.h:53
llvm::MCStreamer::EmitWinCFIEndProlog
virtual void EmitWinCFIEndProlog(SMLoc Loc=SMLoc())
Definition: MCStreamer.cpp:950
llvm::MCStreamer::emitCVFileChecksumOffsetDirective
virtual void emitCVFileChecksumOffsetDirective(unsigned FileNo)
This implements the CodeView '.cv_filechecksumoffset' assembler directive.
Definition: MCStreamer.h:971
llvm::MCStreamer::maybeEmitDwarf64Mark
void maybeEmitDwarf64Mark()
Emit a special value of 0xffffffff if producing 64-bit debugging info.
Definition: MCStreamer.cpp:1007
llvm::VersionTuple
Represents a version number in the form major[.minor[.subminor[.build]]].
Definition: VersionTuple.h:29
llvm::MCTargetStreamer
Target specific streamer interface.
Definition: MCStreamer.h:91
llvm::MCStreamer::EmitWinCFIPushReg
virtual void EmitWinCFIPushReg(MCRegister Register, SMLoc Loc=SMLoc())
Definition: MCStreamer.cpp:853
llvm::MCTargetStreamer::~MCTargetStreamer
virtual ~MCTargetStreamer()
llvm::MCStreamer::EmitWinCFIStartProc
virtual void EmitWinCFIStartProc(const MCSymbol *Symbol, SMLoc Loc=SMLoc())
Definition: MCStreamer.cpp:698
llvm::MCStreamer::emitGPRel32Value
virtual void emitGPRel32Value(const MCExpr *Value)
Emit the expression Value into the output as a gprel32 (32-bit GP relative) value.
Definition: MCStreamer.cpp:212
llvm::MCStreamer::emitTPRel64Value
virtual void emitTPRel64Value(const MCExpr *Value)
Emit the expression Value into the output as a tprel (64-bit TP relative) value.
Definition: MCStreamer.cpp:200
llvm::MCStreamer::visitUsedSymbol
virtual void visitUsedSymbol(const MCSymbol &Sym)
Definition: MCStreamer.cpp:1058
llvm::MCStreamer::getCurrentSectionOnly
MCSection * getCurrentSectionOnly() const
Definition: MCStreamer.h:376
llvm::AddressSpace
AddressSpace
Definition: NVPTXBaseInfo.h:21
llvm::MCTargetStreamer::emitAssignment
virtual void emitAssignment(MCSymbol *Symbol, const MCExpr *Value)
Definition: MCStreamer.cpp:91
llvm::None
const NoneType None
Definition: None.h:23
llvm::lltok::Kind
Kind
Definition: LLToken.h:18
llvm::MCStreamer::emitNops
virtual void emitNops(int64_t NumBytes, int64_t ControlledNopLength, SMLoc Loc, const MCSubtargetInfo &STI)
Definition: MCStreamer.cpp:222
llvm::MCStreamer::GetSymbolOrder
unsigned GetSymbolOrder(const MCSymbol *Sym) const
Returns an index to represent the order a symbol was emitted in.
Definition: MCStreamer.h:387
llvm::MCStreamer::emitBinaryData
virtual void emitBinaryData(StringRef Data)
Functionally identical to EmitBytes.
Definition: MCStreamer.cpp:1190
llvm::MCStreamer::emitCGProfileEntry
virtual void emitCGProfileEntry(const MCSymbolRefExpr *From, const MCSymbolRefExpr *To, uint64_t Count)
Definition: MCStreamer.cpp:797
llvm::MCStreamer::emitSymbolDesc
virtual void emitSymbolDesc(MCSymbol *Symbol, unsigned DescValue)
Set the DescValue for the Symbol.
Definition: MCStreamer.cpp:1144
llvm::MCStreamer::emitDwarfFile0Directive
virtual void emitDwarfFile0Directive(StringRef Directory, StringRef Filename, Optional< MD5::MD5Result > Checksum, Optional< StringRef > Source, unsigned CUID=0)
Specify the "root" file of the compilation, using the ".file 0" extension.
Definition: MCStreamer.cpp:238
llvm::ARMTargetStreamer::emitSetFP
virtual void emitSetFP(unsigned FpReg, unsigned SpReg, int64_t Offset=0)
Definition: ARMTargetStreamer.cpp:96
llvm::MCStreamer::endSection
MCSymbol * endSection(MCSection *Section)
Definition: MCStreamer.cpp:1226
llvm::codeview::DefRangeSubfieldRegisterHeader
Definition: SymbolRecord.h:501
llvm::XCOFF::StorageClass
StorageClass
Definition: XCOFF.h:113
llvm::MCStreamer::emitInt16
void emitInt16(uint64_t Value)
Definition: MCStreamer.h:706
llvm::MCStreamer::emitFileDirective
virtual void emitFileDirective(StringRef Filename)
Switch to a new logical file.
Definition: MCStreamer.cpp:1151
llvm::MCStreamer::EmitWinEHHandler
virtual void EmitWinEHHandler(const MCSymbol *Sym, bool Unwind, bool Except, SMLoc Loc=SMLoc())
Definition: MCStreamer.cpp:772
llvm::MCStreamer::emitValueToOffset
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.
Definition: MCStreamer.cpp:1205
llvm::MCAssembler
Definition: MCAssembler.h:60
llvm::ARMTargetStreamer::emitObjectArch
virtual void emitObjectArch(ARM::ArchKind Arch)
Definition: ARMTargetStreamer.cpp:114
llvm::MCStreamer::emitEHSymAttributes
virtual void emitEHSymAttributes(const MCSymbol *Symbol, MCSymbol *EHSymbol)
Definition: MCStreamer.cpp:398
Index
uint32_t Index
Definition: ELFObjHandler.cpp:84
llvm::MCStreamer::addExplicitComment
virtual void addExplicitComment(const Twine &T)
Add explicit comment T.
Definition: MCStreamer.cpp:122
uint64_t
llvm::MCTargetStreamer::Streamer
MCStreamer & Streamer
Definition: MCStreamer.h:93
llvm::MCInstPrinter
This is an instance of a target assembly language printer that converts an MCInst to valid target ass...
Definition: MCInstPrinter.h:43
llvm::MCStreamer::emitCFIBKeyFrame
virtual void emitCFIBKeyFrame()
Definition: MCStreamer.cpp:247
llvm::MCStreamer::emitRawText
void emitRawText(const Twine &String)
If this file is backed by a assembly streamer, this dumps the specified string in the output ....
Definition: MCStreamer.cpp:982
llvm::MCStreamer::emitSyntaxDirective
virtual void emitSyntaxDirective()
Definition: MCStreamer.cpp:847
llvm::MCStreamer::emitDwarfAdvanceLineAddr
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 outp...
Definition: MCStreamer.h:1116
llvm::MCStreamer::emitIdent
virtual void emitIdent(StringRef IdentString)
Emit the "identifiers" directive.
Definition: MCStreamer.h:867
llvm::DenseMap< const MCSymbol *, unsigned >
llvm::MCStreamer::emitInstruction
virtual void emitInstruction(const MCInst &Inst, const MCSubtargetInfo &STI)
Emit the given Instruction into the current section.
Definition: MCStreamer.cpp:1087
llvm::ARMTargetStreamer::emitHandlerData
virtual void emitHandlerData()
Definition: ARMTargetStreamer.cpp:95
llvm::ARMTargetStreamer::addConstantPoolEntry
const MCExpr * addConstantPoolEntry(const MCExpr *, SMLoc Loc)
Callback used to implement the ldr= pseudo.
Definition: ARMTargetStreamer.cpp:36
I
#define I(x, y, z)
Definition: MD5.cpp:59
Debug
bool Debug
Definition: PassBuilderBindings.cpp:51
FuncId
Profile::FuncID FuncId
Definition: Profile.cpp:321
llvm::createNullStreamer
MCStreamer * createNullStreamer(MCContext &Ctx)
Create a dummy machine code streamer, which does nothing.
Definition: MCNullStreamer.cpp:47
llvm::codeview::DefRangeRegisterHeader
Definition: SymbolRecord.h:479
llvm::MCStreamer::getAssemblerPtr
virtual MCAssembler * getAssemblerPtr()
Definition: MCStreamer.h:282
ArrayRef.h
llvm::MCStreamer::EmitWinCFIPushFrame
virtual void EmitWinCFIPushFrame(bool Code, SMLoc Loc=SMLoc())
Definition: MCStreamer.cpp:936
llvm::MCStreamer::getStartTokLoc
SMLoc getStartTokLoc() const
Definition: MCStreamer.h:272
llvm::MCStreamer::PopSection
bool PopSection()
Restore the current and previous section from the section stack.
Definition: MCStreamer.h:407
llvm::MCStreamer::EmitWindowsUnwindTables
virtual void EmitWindowsUnwindTables()
Definition: MCStreamer.cpp:987
llvm::MCStreamer::EmitWinCFIAllocStack
virtual void EmitWinCFIAllocStack(unsigned Size, SMLoc Loc=SMLoc())
Definition: MCStreamer.cpp:887
assert
assert(ImpDefSCC.getReg()==AMDGPU::SCC &&ImpDefSCC.isDef())
llvm::MCStreamer::emitLOHDirective
virtual void emitLOHDirective(MCLOHType Kind, const MCLOHArgs &Args)
Emit a Linker Optimization Hint (LOH) directive.
Definition: MCStreamer.h:621
llvm::MCStreamer::emitCFIEscape
virtual void emitCFIEscape(StringRef Values)
Definition: MCStreamer.cpp:611
llvm::MCStreamer::emitIntValue
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.
Definition: MCStreamer.cpp:133
llvm::MCStreamer::emitCFIRestore
virtual void emitCFIRestore(int64_t Register)
Definition: MCStreamer.cpp:601
llvm::MCStreamer::EmitCVFuncIdDirective
virtual bool EmitCVFuncIdDirective(unsigned FunctionId)
Introduces a function id for use with .cv_loc.
Definition: MCStreamer.cpp:293
llvm::ARMTargetStreamer::switchVendor
virtual void switchVendor(StringRef Vendor)
Definition: ARMTargetStreamer.cpp:105
llvm::MCStreamer::emitTBSSSymbol
virtual void emitTBSSSymbol(MCSection *Section, MCSymbol *Symbol, uint64_t Size, unsigned ByteAlignment=0)
Emit a thread local bss (.tbss) symbol.
Definition: MCStreamer.cpp:1185
llvm::MCStreamer::GetCommentOS
virtual raw_ostream & GetCommentOS()
Return a raw_ostream that comments can be written to.
Definition: MCStreamer.cpp:110
llvm::ARMTargetStreamer::emitThumbSet
virtual void emitThumbSet(MCSymbol *Symbol, const MCExpr *Value)
Definition: ARMTargetStreamer.cpp:119
llvm::ARMTargetStreamer::emitIntTextAttribute
virtual void emitIntTextAttribute(unsigned Attribute, unsigned IntValue, StringRef StringValue="")
Definition: ARMTargetStreamer.cpp:109
llvm::MCSymbolRefExpr
Represent a reference to a symbol from inside an expression.
Definition: MCExpr.h:192
llvm::MCStreamer::getNumFrameInfos
unsigned getNumFrameInfos()
Definition: MCStreamer.cpp:115
llvm::APInt
Class for arbitrary precision integers.
Definition: APInt.h:75
llvm::codeview::DefRangeRegisterRelHeader
Definition: SymbolRecord.h:551
llvm::MCStreamer::EmitWinCFIFuncletOrFuncEnd
virtual void EmitWinCFIFuncletOrFuncEnd(SMLoc Loc=SMLoc())
This is used on platforms, such as Windows on ARM64, that require function or funclet sizes to be emi...
Definition: MCStreamer.cpp:734
llvm::MCStreamer::EmitWinCFISetFrame
virtual void EmitWinCFISetFrame(MCRegister Register, unsigned Offset, SMLoc Loc=SMLoc())
Definition: MCStreamer.cpp:865
llvm::Sched::Source
@ Source
Definition: TargetLowering.h:100
llvm::MCStreamer::EmitCOFFSymbolType
virtual void EmitCOFFSymbolType(int Type)
Emit the type of the symbol.
Definition: MCStreamer.cpp:1158
llvm::MCStreamer::initSections
virtual void initSections(bool NoExecStack, const MCSubtargetInfo &STI)
Create the default sections and set the initial one.
Definition: MCStreamer.cpp:402
llvm::ArrayRef
ArrayRef - Represent a constant reference to an array (0 or more elements consecutively in memory),...
Definition: APInt.h:32
llvm::ARMTargetStreamer::emitPersonalityIndex
virtual void emitPersonalityIndex(unsigned Index)
Definition: ARMTargetStreamer.cpp:94
llvm::StringRef
StringRef - Represent a constant reference to a string, i.e.
Definition: StringRef.h:58
llvm::cantFail
void cantFail(Error Err, const char *Msg=nullptr)
Report a fatal error if Err is a failure value.
Definition: Error.h:737
uint32_t
llvm::StackOffset
StackOffset is a class to represent an offset with 2 dimensions, named fixed and scalable,...
Definition: TypeSize.h:134
llvm::MCStreamer::getDwarfFrameInfos
ArrayRef< MCDwarfFrameInfo > getDwarfFrameInfos() const
Definition: MCStreamer.cpp:116
llvm::MCStreamer::emitBundleAlignMode
virtual void emitBundleAlignMode(unsigned AlignPow2)
Set the bundle alignment mode from now on in the section.
Definition: MCStreamer.cpp:1207
llvm::MCSection
Instances of this class represent a uniqued identifier for a section in the current translation unit.
Definition: MCSection.h:39
llvm::MCStreamer::EmitCOFFImgRel32
virtual void EmitCOFFImgRel32(MCSymbol const *Symbol, int64_t Offset)
Emits a COFF image relative relocation.
Definition: MCStreamer.cpp:968
S
add sub stmia L5 ldr r0 bl L_printf $stub Instead of a and a wouldn t it be better to do three moves *Return an aggregate type is even return S
Definition: README.txt:210
llvm::MCStreamer::emitCFIGnuArgsSize
virtual void emitCFIGnuArgsSize(int64_t Size)
Definition: MCStreamer.cpp:620
llvm::MCStreamer::emitWeakReference
virtual void emitWeakReference(MCSymbol *Alias, const MCSymbol *Symbol)
Emit an weak reference from Alias to Symbol.
Definition: MCStreamer.cpp:1188
llvm::MCStreamer::emitCFIDefCfa
virtual void emitCFIDefCfa(int64_t Register, int64_t Offset)
Definition: MCStreamer.cpp:481
llvm::MCStreamer::EmitWinCFIStartChained
virtual void EmitWinCFIStartChained(SMLoc Loc=SMLoc())
Definition: MCStreamer.cpp:745
llvm::MCStreamer::setStartTokLocPtr
void setStartTokLocPtr(const SMLoc *Loc)
Definition: MCStreamer.h:271
llvm::ARMTargetStreamer::emitTargetAttributes
void emitTargetAttributes(const MCSubtargetInfo &STI)
Emit the build attributes that only depend on the hardware that we expect.
Definition: ARMTargetStreamer.cpp:164
llvm::MCStreamer::emitDwarfLineStartLabel
virtual void emitDwarfLineStartLabel(MCSymbol *StartSym)
Emit the debug line start label.
Definition: MCStreamer.cpp:1037
llvm::Twine
Twine - A lightweight data structure for efficiently representing the concatenation of temporary valu...
Definition: Twine.h:83
llvm::MCStreamer::getNumWinFrameInfos
unsigned getNumWinFrameInfos()
Definition: MCStreamer.h:307
llvm::ARMTargetStreamer::emitTextAttribute
virtual void emitTextAttribute(unsigned Attribute, StringRef String)
Definition: ARMTargetStreamer.cpp:107
llvm::GraphProgram::Name
Name
Definition: GraphWriter.h:52
MCWinEH.h
llvm::ARM::ArchKind
ArchKind
Definition: ARMTargetParser.h:104
llvm::MCStreamer::emitELFSymverDirective
virtual void emitELFSymverDirective(const MCSymbol *OriginalSym, StringRef Name, bool KeepOriginalSym)
Emit an ELF .symver directive.
Definition: MCStreamer.cpp:1181
llvm::ARMTargetStreamer::emitUnwindRaw
virtual void emitUnwindRaw(int64_t StackOffset, const SmallVectorImpl< uint8_t > &Opcodes)
Definition: ARMTargetStreamer.cpp:102
llvm::MCStreamer::emitSLEB128IntValue
void emitSLEB128IntValue(int64_t Value)
Special case of EmitSLEB128Value that avoids the client having to pass in a MCExpr for constant integ...
Definition: MCStreamer.cpp:170
llvm::ARMTargetStreamer::emitMovSP
virtual void emitMovSP(unsigned Reg, int64_t Offset=0)
Definition: ARMTargetStreamer.cpp:98
llvm::MCStreamer::emitSymbolAttribute
virtual bool emitSymbolAttribute(MCSymbol *Symbol, MCSymbolAttr Attribute)=0
Add the given Attribute to Symbol.
llvm::MCStreamer::emitDwarfLineEndEntry
virtual void emitDwarfLineEndEntry(MCSection *Section, MCSymbol *LastLabel)
Emit the debug line end entry.
Definition: MCStreamer.h:1111
llvm::MCStreamer::emitIntValueInHex
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 & p...
Definition: MCStreamer.h:701
llvm::MCStreamer::AssignFragment
void AssignFragment(MCSymbol *Symbol, MCFragment *Fragment)
Sets the symbol's section.
Definition: MCStreamer.cpp:406
llvm::MCStreamer::PushSection
void PushSection()
Save the current and previous section on the section stack.
Definition: MCStreamer.h:398
llvm::MCStreamer::doFinalizationAtSectionEnd
virtual void doFinalizationAtSectionEnd(MCSection *Section)
Do finalization for the streamer at the end of a section.
Definition: MCStreamer.h:1122
llvm::MCStreamer::emitCVDefRangeDirective
virtual void emitCVDefRangeDirective(ArrayRef< std::pair< const MCSymbol *, const MCSymbol * >> Ranges, StringRef FixedSizePortion)
This implements the CodeView '.cv_def_range' assembler directive.
Definition: MCStreamer.cpp:360
llvm::MCStreamer::emitCFIWindowSave
virtual void emitCFIWindowSave()
Definition: MCStreamer.cpp:657
llvm::MCStreamer::emitCFILsda
virtual void emitCFILsda(const MCSymbol *Sym, unsigned Encoding)
Definition: MCStreamer.cpp:564
llvm::MCStreamer::isIntegratedAssemblerRequired
virtual bool isIntegratedAssemblerRequired() const
Is the integrated assembler required for this streamer to function correctly?
Definition: MCStreamer.h:327
llvm::MCStreamer::emitAbsoluteSymbolDiff
virtual void emitAbsoluteSymbolDiff(const MCSymbol *Hi, const MCSymbol *Lo, unsigned Size)
Emit the absolute difference between two symbols.
Definition: MCStreamer.cpp:1113
llvm::MCStreamer::emitExplicitComments
virtual void emitExplicitComments()
Emit added explicit comments.
Definition: MCStreamer.cpp:123
llvm::MCStreamer::emitCVStringTableDirective
virtual void emitCVStringTableDirective()
This implements the CodeView '.cv_stringtable' assembler directive.
Definition: MCStreamer.h:964
llvm::MCStreamer::emitSLEB128Value
virtual void emitSLEB128Value(const MCExpr *Value)
Definition: MCStreamer.cpp:1195
llvm::MCStreamer::getWinFrameInfos
ArrayRef< std::unique_ptr< WinEH::FrameInfo > > getWinFrameInfos() const
Definition: MCStreamer.h:308
llvm::MCStreamer::emitBundleUnlock
virtual void emitBundleUnlock()
Ends a bundle-locked group.
Definition: MCStreamer.cpp:1210
llvm::ARMTargetStreamer::emitAttribute
virtual void emitAttribute(unsigned Attribute, unsigned Value)
Definition: ARMTargetStreamer.cpp:106
llvm::MCStreamer::EmitCOFFSafeSEH
virtual void EmitCOFFSafeSEH(MCSymbol const *Symbol)
Definition: MCStreamer.cpp:960
llvm::MCStreamer::emitCFIRememberState
virtual void emitCFIRememberState()
Definition: MCStreamer.cpp:572
llvm::LCOMM::ByteAlignment
@ ByteAlignment
Definition: MCAsmInfo.h:50
llvm::ARMTargetStreamer::~ARMTargetStreamer
~ARMTargetStreamer() override
llvm::MCStreamer::EmitCVFPOData
virtual void EmitCVFPOData(const MCSymbol *ProcSym, SMLoc Loc={})
This implements the CodeView '.cv_fpo_data' assembler directive.
Definition: MCStreamer.h:974
llvm::MCStreamer::BeginCOFFSymbolDef
virtual void BeginCOFFSymbolDef(const MCSymbol *Symbol)
Start emitting COFF symbol definition.
Definition: MCStreamer.cpp:1145
llvm::MCStreamer::checkCVLocSection
bool checkCVLocSection(unsigned FuncId, unsigned FileNo, SMLoc Loc)
Returns true if the the .cv_loc directive is in the right section.
Definition: MCStreamer.cpp:316
llvm::WinEH::FrameInfo
Definition: MCWinEH.h:39
llvm::ARMBuildAttrs::Symbol
@ Symbol
Definition: ARMBuildAttributes.h:79
llvm::MCStreamer::emitCFIEndProc
void emitCFIEndProc()
Definition: MCStreamer.cpp:462
llvm::MCStreamer::getCurrentWinFrameInfo
WinEH::FrameInfo * getCurrentWinFrameInfo()
Definition: MCStreamer.h:246
MCLinkerOptimizationHint.h
llvm::ARMTargetStreamer::emitFnStart
virtual void emitFnStart()
Definition: ARMTargetStreamer.cpp:90
llvm::MCStreamer::~MCStreamer
virtual ~MCStreamer()
Definition: MCStreamer.cpp:99
llvm::LegalityPredicates::isVector
LegalityPredicate isVector(unsigned TypeIdx)
True iff the specified type index is a vector.
Definition: LegalityPredicates.cpp:73
llvm::MCStreamer::emitULEB128IntValue
void emitULEB128IntValue(uint64_t Value, unsigned PadTo=0)
Special case of EmitULEB128Value that avoids the client having to pass in a MCExpr for constant integ...
Definition: MCStreamer.cpp:161
llvm::MCStreamer::getContext
MCContext & getContext() const
Definition: MCStreamer.h:280
llvm::MCStreamer::emitCodeAlignment
virtual void emitCodeAlignment(unsigned ByteAlignment, const MCSubtargetInfo *STI, unsigned MaxBytesToEmit=0)
Emit nops until the byte alignment ByteAlignment is reached.
Definition: MCStreamer.cpp:1202
llvm::MCStreamer::emitXCOFFLocalCommonSymbol
virtual void emitXCOFFLocalCommonSymbol(MCSymbol *LabelSym, uint64_t Size, MCSymbol *CsectSym, unsigned ByteAlignment)
Emits an lcomm directive with XCOFF csect information.
Definition: MCStreamer.cpp:1161
llvm::MCStreamer::emitFill
void emitFill(uint64_t NumBytes, uint8_t FillValue)
Emit NumBytes bytes worth of the value specified by FillValue.
Definition: MCStreamer.cpp:218
SmallVector.h
llvm::MCStreamer::getTargetStreamer
MCTargetStreamer * getTargetStreamer()
Definition: MCStreamer.h:287
llvm::MCStreamer::emitCFIReturnColumn
virtual void emitCFIReturnColumn(int64_t Register)
Definition: MCStreamer.cpp:676
llvm::MCSectionSubPair
std::pair< MCSection *, const MCExpr * > MCSectionSubPair
Definition: MCStreamer.h:64
llvm::MCStreamer::emitDwarfLocDirective
virtual void emitDwarfLocDirective(unsigned FileNo, unsigned Line, unsigned Column, unsigned Flags, unsigned Isa, unsigned Discriminator, StringRef FileName)
This implements the DWARF2 '.loc fileno lineno ...' assembler directive.
Definition: MCStreamer.cpp:254
llvm::MCStreamer::isVerboseAsm
virtual bool isVerboseAsm() const
Return true if this streamer supports verbose assembly and if it is enabled.
Definition: MCStreamer.h:319
llvm::MCStreamer::mayHaveInstructions
virtual bool mayHaveInstructions(MCSection &Sec) const
Definition: MCStreamer.h:1092
llvm::MCStreamer::emitValueToAlignment
virtual void emitValueToAlignment(unsigned ByteAlignment, int64_t Value=0, unsigned ValueSize=1, unsigned MaxBytesToEmit=0)
Emit some number of copies of Value until the byte alignment ByteAlignment is reached.
Definition: MCStreamer.cpp:1199
llvm::ARMTargetStreamer::emitArchExtension
virtual void emitArchExtension(uint64_t ArchExt)
Definition: ARMTargetStreamer.cpp:113
llvm::MCTargetStreamer::emitValue
virtual void emitValue(const MCExpr *Value)
Definition: MCStreamer.cpp:71
llvm::MCStreamer::emitZerofill
virtual void emitZerofill(MCSection *Section, MCSymbol *Symbol=nullptr, uint64_t Size=0, unsigned ByteAlignment=0, SMLoc Loc=SMLoc())=0
Emit the zerofill section and an optional symbol.
llvm::MCStreamer::SwitchSectionNoChange
void SwitchSectionNoChange(MCSection *Section, const MCExpr *Subsection=nullptr)
Set the current section where code is being emitted to Section.
Definition: MCStreamer.h:440
llvm::MCStreamer::emitBytes
virtual void emitBytes(StringRef Data)
Emit the bytes in Data into the output.
Definition: MCStreamer.cpp:1189
llvm::SmallVectorImpl< unsigned >
llvm::MCTargetStreamer::prettyPrintAsm
virtual void prettyPrintAsm(MCInstPrinter &InstPrinter, uint64_t Address, const MCInst &Inst, const MCSubtargetInfo &STI, raw_ostream &OS)
Definition: MCStreamer.cpp:1051
llvm::ARMTargetStreamer::finishAttributeSection
virtual void finishAttributeSection()
Definition: ARMTargetStreamer.cpp:116
llvm::MCTargetStreamer::emitDwarfFileDirective
virtual void emitDwarfFileDirective(StringRef Directive)
Definition: MCStreamer.cpp:67
llvm::MCStreamer::emitRawTextImpl
virtual void emitRawTextImpl(StringRef String)
EmitRawText - If this file is backed by an assembly streamer, this dumps the specified string in the ...
Definition: MCStreamer.cpp:973
From
BlockVerifier::State From
Definition: BlockVerifier.cpp:55
llvm::AMDGPU::HSAMD::Kernel::Key::Args
constexpr char Args[]
Key for Kernel::Metadata::mArgs.
Definition: AMDGPUMetadata.h:389
llvm::lltok::ChecksumKind
@ ChecksumKind
Definition: LLToken.h:490
llvm::ARMTargetStreamer::emitCurrentConstantPool
void emitCurrentConstantPool()
Callback used to implement the .ltorg directive.
Definition: ARMTargetStreamer.cpp:40
llvm::MCStreamer::generateCompactUnwindEncodings
void generateCompactUnwindEncodings(MCAsmBackend *MAB)
Definition: MCStreamer.cpp:125
llvm::MCStreamer::getDwarfLineTableSymbol
virtual MCSymbol * getDwarfLineTableSymbol(unsigned CUID)
Definition: MCStreamer.cpp:262
llvm::MCStreamer::emitCFIRestoreState
virtual void emitCFIRestoreState()
Definition: MCStreamer.cpp:581
llvm::MCStreamer::SwitchSection
virtual void SwitchSection(MCSection *Section, const MCExpr *Subsection=nullptr)
Set the current section where code is being emitted to Section.
Definition: MCStreamer.cpp:1212
llvm::MCDwarfFrameInfo
Definition: MCDwarf.h:660
llvm::MCSubtargetInfo
Generic base class for all target subtargets.
Definition: MCSubtargetInfo.h:75
llvm::MCStreamer::emitCommonSymbol
virtual void emitCommonSymbol(MCSymbol *Symbol, uint64_t Size, unsigned ByteAlignment)=0
Emit a common symbol.
llvm::MCStreamer::emitThumbFunc
virtual void emitThumbFunc(MCSymbol *Func)
Note in the output that the specified Func is a Thumb mode function (ARM target only).
Definition: MCStreamer.cpp:1143
llvm::ARMTargetStreamer::emitFPU
virtual void emitFPU(unsigned FPU)
Definition: ARMTargetStreamer.cpp:115
llvm::MCStreamer::EmitWinCFIEndChained
virtual void EmitWinCFIEndChained(SMLoc Loc=SMLoc())
Definition: MCStreamer.cpp:758
llvm::Value
LLVM Value Representation.
Definition: Value.h:75
llvm::ARMTargetStreamer::emitConstantPools
void emitConstantPools() override
Definition: ARMTargetStreamer.cpp:46
llvm::Directive
Definition: DirectiveEmitter.h:100
llvm::MCExpr
Base class for the full range of assembler expressions which are needed for parsing.
Definition: MCExpr.h:35
llvm::MCStreamer::emitVersionForTarget
void emitVersionForTarget(const Triple &Target, const VersionTuple &SDKVersion)
Definition: MCStreamer.cpp:1311
llvm::MCStreamer::reset
virtual void reset()
State management.
Definition: MCStreamer.cpp:101
llvm::MCStreamer::tryEmitDwarfFileDirective
virtual Expected< unsigned > tryEmitDwarfFileDirective(unsigned FileNo, StringRef Directory, StringRef Filename, Optional< MD5::MD5Result > Checksum=None, Optional< StringRef > Source=None, unsigned CUID=0)
Associate a filename with a specified logical file number.
Definition: MCStreamer.cpp:229
llvm::MCStreamer::AddComment
virtual void AddComment(const Twine &T, bool EOL=true)
Add a textual comment.
Definition: MCStreamer.h:342
llvm::MCStreamer::emitCFINegateRAState
virtual void emitCFINegateRAState()
Definition: MCStreamer.cpp:667
llvm::MCStreamer::emitLocalCommonSymbol
virtual void emitLocalCommonSymbol(MCSymbol *Symbol, uint64_t Size, unsigned ByteAlignment)
Emit a local common (.lcomm) symbol.
Definition: MCStreamer.cpp:1183
llvm::ISD::MCSymbol
@ MCSymbol
Definition: ISDOpcodes.h:172
llvm::MCStreamer::emitDwarfFileDirective
unsigned emitDwarfFileDirective(unsigned FileNo, StringRef Directory, StringRef Filename, Optional< MD5::MD5Result > Checksum=None, Optional< StringRef > Source=None, unsigned CUID=0)
Associate a filename with a specified logical file number.
Definition: MCStreamer.h:871
llvm::MCStreamer::emitGNUAttribute
virtual void emitGNUAttribute(unsigned Tag, unsigned Value)
Emit a .gnu_attribute directive.
Definition: MCStreamer.h:624
llvm::MCStreamer::emitZeros
void emitZeros(uint64_t NumBytes)
Emit NumBytes worth of zeros.
Definition: MCStreamer.cpp:226