Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-05-10 08:44:16

0001 //===- MCXCOFFObjectStreamer.h - MCStreamer XCOFF Object File Interface ---===//
0002 //
0003 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
0004 // See https://llvm.org/LICENSE.txt for license information.
0005 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
0006 //
0007 //===----------------------------------------------------------------------===//
0008 
0009 #ifndef LLVM_MC_MCXCOFFSTREAMER_H
0010 #define LLVM_MC_MCXCOFFSTREAMER_H
0011 
0012 #include "llvm/MC/MCObjectStreamer.h"
0013 
0014 namespace llvm {
0015 class XCOFFObjectWriter;
0016 
0017 class MCXCOFFStreamer : public MCObjectStreamer {
0018 public:
0019   MCXCOFFStreamer(MCContext &Context, std::unique_ptr<MCAsmBackend> MAB,
0020                   std::unique_ptr<MCObjectWriter> OW,
0021                   std::unique_ptr<MCCodeEmitter> Emitter);
0022 
0023   XCOFFObjectWriter &getWriter();
0024 
0025   bool emitSymbolAttribute(MCSymbol *Symbol, MCSymbolAttr Attribute) override;
0026   void emitCommonSymbol(MCSymbol *Symbol, uint64_t Size,
0027                         Align ByteAlignment) override;
0028   void emitZerofill(MCSection *Section, MCSymbol *Symbol = nullptr,
0029                     uint64_t Size = 0, Align ByteAlignment = Align(1),
0030                     SMLoc Loc = SMLoc()) override;
0031   void emitInstToData(const MCInst &Inst, const MCSubtargetInfo &) override;
0032   void emitXCOFFLocalCommonSymbol(MCSymbol *LabelSym, uint64_t Size,
0033                                   MCSymbol *CsectSym, Align Alignment) override;
0034   void emitXCOFFSymbolLinkageWithVisibility(MCSymbol *Symbol,
0035                                             MCSymbolAttr Linkage,
0036                                             MCSymbolAttr Visibility) override;
0037   void emitXCOFFRefDirective(const MCSymbol *Symbol) override;
0038   void emitXCOFFRenameDirective(const MCSymbol *Name,
0039                                 StringRef Rename) override;
0040   void emitXCOFFExceptDirective(const MCSymbol *Symbol, const MCSymbol *Trap,
0041                                 unsigned Lang, unsigned Reason,
0042                                 unsigned FunctionSize, bool hasDebug) override;
0043   void emitXCOFFCInfoSym(StringRef Name, StringRef Metadata) override;
0044 };
0045 
0046 } // end namespace llvm
0047 
0048 #endif // LLVM_MC_MCXCOFFSTREAMER_H