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