X-Git-Url: http://demsky.eecs.uci.edu/git/?a=blobdiff_plain;f=include%2Fllvm%2FCodeGen%2FAsmPrinter.h;h=11f98ca6b94fe539c62b8906e022fd6769e09498;hb=405cc64eace384f436e7ea7cf6a3e1491cdc4093;hp=222468c754a4f0876649fc39a932dfbe57eaceb9;hpb=84e6358ea0706e516f32139c990feb97f9738beb;p=oota-llvm.git diff --git a/include/llvm/CodeGen/AsmPrinter.h b/include/llvm/CodeGen/AsmPrinter.h index 222468c754a..11f98ca6b94 100644 --- a/include/llvm/CodeGen/AsmPrinter.h +++ b/include/llvm/CodeGen/AsmPrinter.h @@ -108,6 +108,7 @@ public: private: MCSymbol *CurrentFnBegin; MCSymbol *CurrentFnEnd; + MCSymbol *CurExceptionSym; // The garbage collection metadata printer table. void *GCMetadataPrinters; // Really a DenseMap. @@ -139,7 +140,7 @@ protected: explicit AsmPrinter(TargetMachine &TM, std::unique_ptr Streamer); public: - virtual ~AsmPrinter(); + ~AsmPrinter() override; DwarfDebug *getDwarfDebug() { return DD; } DwarfDebug *getDwarfDebug() const { return DD; } @@ -154,6 +155,7 @@ public: MCSymbol *getFunctionBegin() const { return CurrentFnBegin; } MCSymbol *getFunctionEnd() const { return CurrentFnEnd; } + MCSymbol *getCurExceptionSym(); /// Return information about object file lowering. const TargetLoweringObjectFile &getObjFileLowering() const; @@ -196,7 +198,6 @@ public: /// Emit the specified function out to the OutStreamer. bool runOnMachineFunction(MachineFunction &MF) override { SetupMachineFunction(MF); - EmitFunctionHeader(); EmitFunctionBody(); return false; } @@ -209,9 +210,6 @@ public: /// runOnMachineFunction. void SetupMachineFunction(MachineFunction &MF); - /// This method emits the header for the current function. - void EmitFunctionHeader(); - /// This method emits the body and trailer for a function. void EmitFunctionBody(); @@ -333,14 +331,7 @@ public: // Symbol Lowering Routines. //===------------------------------------------------------------------===// public: - /// Return the MCSymbol corresponding to the assembler temporary label with - /// the specified stem and unique ID. - MCSymbol *GetTempSymbol(const Twine &Name, unsigned ID) const; - - /// Return an assembler temporary label with the specified stem. - MCSymbol *GetTempSymbol(const Twine &Name) const; - - MCSymbol *createTempSymbol(const Twine &Name, unsigned ID) const; + MCSymbol *createTempSymbol(const Twine &Name) const; /// Return the MCSymbol for a private symbol with global value name as its /// base, with the specified suffix. @@ -431,7 +422,7 @@ public: void emitSectionOffset(const MCSymbol *Label) const; /// Get the value for DW_AT_APPLE_isa. Zero if no isa encoding specified. - virtual unsigned getISAEncoding(const Function *) { return 0; } + virtual unsigned getISAEncoding() { return 0; } /// EmitDwarfRegOp - Emit a dwarf register operation. virtual void EmitDwarfRegOp(ByteStreamer &BS, @@ -500,11 +491,14 @@ private: mutable const MachineInstr *LastMI; mutable unsigned LastFn; mutable unsigned Counter; - mutable unsigned SetCounter; + + /// This method emits the header for the current function. + void EmitFunctionHeader(); /// Emit a blob of inline asm to the output streamer. void - EmitInlineAsm(StringRef Str, const MDNode *LocMDNode = nullptr, + EmitInlineAsm(StringRef Str, const MCSubtargetInfo &STI, + const MDNode *LocMDNode = nullptr, InlineAsm::AsmDialect AsmDialect = InlineAsm::AD_ATT) const; /// This method formats and emits the specified machine instruction that is an