[C++11] Add 'override' keyword to virtual methods that override their base class.
authorCraig Topper <craig.topper@gmail.com>
Sat, 8 Mar 2014 06:31:39 +0000 (06:31 +0000)
committerCraig Topper <craig.topper@gmail.com>
Sat, 8 Mar 2014 06:31:39 +0000 (06:31 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203339 91177308-0d34-0410-b5e6-96231b3b80d8

19 files changed:
include/llvm/CodeGen/ResourcePriorityQueue.h
include/llvm/CodeGen/SelectionDAGISel.h
include/llvm/MC/MCParser/AsmLexer.h
lib/CodeGen/AsmPrinter/ByteStreamer.h
lib/CodeGen/AsmPrinter/DIE.h
lib/CodeGen/AsmPrinter/DwarfDebug.h
lib/CodeGen/AsmPrinter/DwarfException.h
lib/CodeGen/AsmPrinter/ErlangGCPrinter.cpp
lib/CodeGen/AsmPrinter/OcamlGCPrinter.cpp
lib/CodeGen/AsmPrinter/WinCodeViewLineTables.h
lib/CodeGen/SelectionDAG/DAGCombiner.cpp
lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
lib/CodeGen/SelectionDAG/LegalizeTypes.cpp
lib/CodeGen/SelectionDAG/ScheduleDAGFast.cpp
lib/CodeGen/SelectionDAG/ScheduleDAGRRList.cpp
lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.h
lib/CodeGen/SelectionDAG/ScheduleDAGVLIW.cpp
lib/CodeGen/SelectionDAG/SelectionDAG.cpp
lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp

index f20a9fce2ae8c5e556ec6d3ed7e20c1e91631e26..7ae9111028e5c437b3b7912ffb1cd79685906a32 100644 (file)
@@ -81,17 +81,17 @@ namespace llvm {
       delete ResourcesModel;
     }
 
-    bool isBottomUp() const { return false; }
+    bool isBottomUp() const override { return false; }
 
-    void initNodes(std::vector<SUnit> &sunits);
+    void initNodes(std::vector<SUnit> &sunits) override;
 
-    void addNode(const SUnit *SU) {
+    void addNode(const SUnit *SU) override {
       NumNodesSolelyBlocking.resize(SUnits->size(), 0);
     }
 
-    void updateNode(const SUnit *SU) {}
+    void updateNode(const SUnit *SU) override {}
 
-    void releaseState() {
+    void releaseState() override {
       SUnits = 0;
     }
 
@@ -116,18 +116,18 @@ namespace llvm {
     signed regPressureDelta(SUnit *SU, bool RawPressure = false);
     signed rawRegPressureDelta (SUnit *SU, unsigned RCId);
 
-    bool empty() const { return Queue.empty(); }
+    bool empty() const override { return Queue.empty(); }
 
-    virtual void push(SUnit *U);
+    void push(SUnit *U) override;
 
-    virtual SUnit *pop();
+    SUnit *pop() override;
 
-    virtual void remove(SUnit *SU);
+    void remove(SUnit *SU) override;
 
-    virtual void dump(ScheduleDAG* DAG) const;
+    void dump(ScheduleDAG* DAG) const override;
 
     /// scheduledNode - Main resource tracking point.
-    void scheduledNode(SUnit *Node);
+    void scheduledNode(SUnit *Node) override;
     bool isResourceAvailable(SUnit *SU);
     void reserveResources(SUnit *SU);
 
index 3d626e1edfe7980e2c1406825496502ff08435a8..b92b6ec424112a428f2f4600f1e06d82d78b6475 100644 (file)
@@ -60,9 +60,9 @@ public:
     return TM.getTargetLowering();
   }
 
-  virtual void getAnalysisUsage(AnalysisUsage &AU) const;
+  void getAnalysisUsage(AnalysisUsage &AU) const override;
 
-  virtual bool runOnMachineFunction(MachineFunction &MF);
+  bool runOnMachineFunction(MachineFunction &MF) override;
 
   virtual void EmitFunctionEntryCode() {}
 
index 89677a91cd381ea664eaef7403047ce938a2afd6..f36011c9ff93bf594cae9b13bda1ffff5cc4f8e7 100644 (file)
@@ -36,7 +36,7 @@ class AsmLexer : public MCAsmLexer {
 
 protected:
   /// LexToken - Read the next token and return its code.
-  virtual AsmToken LexToken();
+  AsmToken LexToken() override;
 
 public:
   AsmLexer(const MCAsmInfo &MAI);
@@ -44,10 +44,10 @@ public:
 
   void setBuffer(const MemoryBuffer *buf, const char *ptr = NULL);
 
-  virtual StringRef LexUntilEndOfStatement();
+  StringRef LexUntilEndOfStatement() override;
   StringRef LexUntilEndOfLine();
 
-  virtual const AsmToken peekTok(bool ShouldSkipSpace = true);
+  const AsmToken peekTok(bool ShouldSkipSpace = true) override;
 
   bool isAtStartOfComment(char Char);
   bool isAtStatementSeparator(const char *Ptr);
index 032dc13b5e7f701f98e5ef58ce24d9441c70f3ea..6c01d65cc1aa629f62a6cd7baed64272585ec763 100644 (file)
@@ -37,15 +37,15 @@ private:
 
 public:
   APByteStreamer(AsmPrinter &Asm) : AP(Asm) {}
-  void EmitInt8(uint8_t Byte, const Twine &Comment) {
+  void EmitInt8(uint8_t Byte, const Twine &Comment) override {
     AP.OutStreamer.AddComment(Comment);
     AP.EmitInt8(Byte);
   }
-  void EmitSLEB128(uint64_t DWord, const Twine &Comment) {
+  void EmitSLEB128(uint64_t DWord, const Twine &Comment) override {
     AP.OutStreamer.AddComment(Comment);
     AP.EmitSLEB128(DWord);
   }
-  void EmitULEB128(uint64_t DWord, const Twine &Comment) {
+  void EmitULEB128(uint64_t DWord, const Twine &Comment) override {
     AP.OutStreamer.AddComment(Comment);
     AP.EmitULEB128(DWord);
   }
@@ -56,13 +56,13 @@ class HashingByteStreamer : public ByteStreamer {
   DIEHash &Hash;
  public:
  HashingByteStreamer(DIEHash &H) : Hash(H) {}
-  void EmitInt8(uint8_t Byte, const Twine &Comment) {
+  void EmitInt8(uint8_t Byte, const Twine &Comment) override {
     Hash.update(Byte);
   }
-  void EmitSLEB128(uint64_t DWord, const Twine &Comment) {
+  void EmitSLEB128(uint64_t DWord, const Twine &Comment) override {
     Hash.addSLEB128(DWord);
   }
-  void EmitULEB128(uint64_t DWord, const Twine &Comment) {
+  void EmitULEB128(uint64_t DWord, const Twine &Comment) override {
     Hash.addULEB128(DWord);
   }
 };
index 43dd6b2d23b8526edef503e3f6f84dba63c2ccbb..e90812558e5cac0d6bc1bcd379f8ca9823b7ef51 100644 (file)
@@ -265,19 +265,19 @@ public:
 
   /// EmitValue - Emit integer of appropriate size.
   ///
-  virtual void EmitValue(AsmPrinter *AP, dwarf::Form Form) const;
+  void EmitValue(AsmPrinter *AP, dwarf::Form Form) const override;
 
   uint64_t getValue() const { return Integer; }
 
   /// SizeOf - Determine size of integer value in bytes.
   ///
-  virtual unsigned SizeOf(AsmPrinter *AP, dwarf::Form Form) const;
+  unsigned SizeOf(AsmPrinter *AP, dwarf::Form Form) const override;
 
   // Implement isa/cast/dyncast.
   static bool classof(const DIEValue *I) { return I->getType() == isInteger; }
 
 #ifndef NDEBUG
-  virtual void print(raw_ostream &O) const;
+  void print(raw_ostream &O) const override;
 #endif
 };
 
@@ -292,7 +292,7 @@ public:
 
   /// EmitValue - Emit expression value.
   ///
-  virtual void EmitValue(AsmPrinter *AP, dwarf::Form Form) const;
+  void EmitValue(AsmPrinter *AP, dwarf::Form Form) const override;
 
   /// getValue - Get MCExpr.
   ///
@@ -300,13 +300,13 @@ public:
 
   /// SizeOf - Determine size of expression value in bytes.
   ///
-  virtual unsigned SizeOf(AsmPrinter *AP, dwarf::Form Form) const;
+  unsigned SizeOf(AsmPrinter *AP, dwarf::Form Form) const override;
 
   // Implement isa/cast/dyncast.
   static bool classof(const DIEValue *E) { return E->getType() == isExpr; }
 
 #ifndef NDEBUG
-  virtual void print(raw_ostream &O) const;
+  void print(raw_ostream &O) const override;
 #endif
 };
 
@@ -321,7 +321,7 @@ public:
 
   /// EmitValue - Emit label value.
   ///
-  virtual void EmitValue(AsmPrinter *AP, dwarf::Form Form) const;
+  void EmitValue(AsmPrinter *AP, dwarf::Form Form) const override;
 
   /// getValue - Get MCSymbol.
   ///
@@ -329,13 +329,13 @@ public:
 
   /// SizeOf - Determine size of label value in bytes.
   ///
-  virtual unsigned SizeOf(AsmPrinter *AP, dwarf::Form Form) const;
+  unsigned SizeOf(AsmPrinter *AP, dwarf::Form Form) const override;
 
   // Implement isa/cast/dyncast.
   static bool classof(const DIEValue *L) { return L->getType() == isLabel; }
 
 #ifndef NDEBUG
-  virtual void print(raw_ostream &O) const;
+  void print(raw_ostream &O) const override;
 #endif
 };
 
@@ -352,17 +352,17 @@ public:
 
   /// EmitValue - Emit delta value.
   ///
-  virtual void EmitValue(AsmPrinter *AP, dwarf::Form Form) const;
+  void EmitValue(AsmPrinter *AP, dwarf::Form Form) const override;
 
   /// SizeOf - Determine size of delta value in bytes.
   ///
-  virtual unsigned SizeOf(AsmPrinter *AP, dwarf::Form Form) const;
+  unsigned SizeOf(AsmPrinter *AP, dwarf::Form Form) const override;
 
   // Implement isa/cast/dyncast.
   static bool classof(const DIEValue *D) { return D->getType() == isDelta; }
 
 #ifndef NDEBUG
-  virtual void print(raw_ostream &O) const;
+  void print(raw_ostream &O) const override;
 #endif
 };
 
@@ -382,17 +382,17 @@ public:
 
   /// EmitValue - Emit delta value.
   ///
-  virtual void EmitValue(AsmPrinter *AP, dwarf::Form Form) const;
+  void EmitValue(AsmPrinter *AP, dwarf::Form Form) const override;
 
   /// SizeOf - Determine size of delta value in bytes.
   ///
-  virtual unsigned SizeOf(AsmPrinter *AP, dwarf::Form Form) const;
+  unsigned SizeOf(AsmPrinter *AP, dwarf::Form Form) const override;
 
   // Implement isa/cast/dyncast.
   static bool classof(const DIEValue *D) { return D->getType() == isString; }
 
 #ifndef NDEBUG
-  virtual void print(raw_ostream &O) const;
+  void print(raw_ostream &O) const override;
 #endif
 };
 
@@ -412,11 +412,11 @@ public:
 
   /// EmitValue - Emit debug information entry offset.
   ///
-  virtual void EmitValue(AsmPrinter *AP, dwarf::Form Form) const;
+  void EmitValue(AsmPrinter *AP, dwarf::Form Form) const override;
 
   /// SizeOf - Determine size of debug information entry in bytes.
   ///
-  virtual unsigned SizeOf(AsmPrinter *AP, dwarf::Form Form) const {
+   unsigned SizeOf(AsmPrinter *AP, dwarf::Form Form) const override {
     return Form == dwarf::DW_FORM_ref_addr ? getRefAddrSize(AP)
                                            : sizeof(int32_t);
   }
@@ -428,7 +428,7 @@ public:
   static bool classof(const DIEValue *E) { return E->getType() == isEntry; }
 
 #ifndef NDEBUG
-  virtual void print(raw_ostream &O) const;
+  void print(raw_ostream &O) const override;
 #endif
 };
 
@@ -442,10 +442,10 @@ public:
       : DIEValue(isTypeSignature), Unit(Unit) {}
 
   /// \brief Emit type unit signature.
-  virtual void EmitValue(AsmPrinter *Asm, dwarf::Form Form) const;
+  void EmitValue(AsmPrinter *Asm, dwarf::Form Form) const override;
 
   /// Returns size of a ref_sig8 entry.
-  virtual unsigned SizeOf(AsmPrinter *AP, dwarf::Form Form) const {
+  unsigned SizeOf(AsmPrinter *AP, dwarf::Form Form) const override {
     assert(Form == dwarf::DW_FORM_ref_sig8);
     return 8;
   }
@@ -455,7 +455,7 @@ public:
     return E->getType() == isTypeSignature;
   }
 #ifndef NDEBUG
-  virtual void print(raw_ostream &O) const;
+  void print(raw_ostream &O) const override;
   void dump() const;
 #endif
 };
@@ -489,17 +489,17 @@ public:
 
   /// EmitValue - Emit location data.
   ///
-  virtual void EmitValue(AsmPrinter *AP, dwarf::Form Form) const;
+  void EmitValue(AsmPrinter *AP, dwarf::Form Form) const override;
 
   /// SizeOf - Determine size of location data in bytes.
   ///
-  virtual unsigned SizeOf(AsmPrinter *AP, dwarf::Form Form) const;
+  unsigned SizeOf(AsmPrinter *AP, dwarf::Form Form) const override;
 
   // Implement isa/cast/dyncast.
   static bool classof(const DIEValue *E) { return E->getType() == isLoc; }
 
 #ifndef NDEBUG
-  virtual void print(raw_ostream &O) const;
+  void print(raw_ostream &O) const override;
 #endif
 };
 
@@ -529,17 +529,17 @@ public:
 
   /// EmitValue - Emit location data.
   ///
-  virtual void EmitValue(AsmPrinter *AP, dwarf::Form Form) const;
+  void EmitValue(AsmPrinter *AP, dwarf::Form Form) const override;
 
   /// SizeOf - Determine size of location data in bytes.
   ///
-  virtual unsigned SizeOf(AsmPrinter *AP, dwarf::Form Form) const;
+  unsigned SizeOf(AsmPrinter *AP, dwarf::Form Form) const override;
 
   // Implement isa/cast/dyncast.
   static bool classof(const DIEValue *E) { return E->getType() == isBlock; }
 
 #ifndef NDEBUG
-  virtual void print(raw_ostream &O) const;
+  void print(raw_ostream &O) const override;
 #endif
 };
 
@@ -559,17 +559,17 @@ public:
 
   /// EmitValue - Emit location data.
   ///
-  virtual void EmitValue(AsmPrinter *AP, dwarf::Form Form) const;
+  void EmitValue(AsmPrinter *AP, dwarf::Form Form) const override;
 
   /// SizeOf - Determine size of location data in bytes.
   ///
-  virtual unsigned SizeOf(AsmPrinter *AP, dwarf::Form Form) const;
+  unsigned SizeOf(AsmPrinter *AP, dwarf::Form Form) const override;
 
   // Implement isa/cast/dyncast.
   static bool classof(const DIEValue *E) { return E->getType() == isLocList; }
 
 #ifndef NDEBUG
-  virtual void print(raw_ostream &O) const;
+  void print(raw_ostream &O) const override;
 #endif
 };
 
index b8cfdd354b1c47a327edc1d96db6dbc92c6ecd8c..d76ba490cb95cc159b695366a7d2f45e3c6ab3e8 100644 (file)
@@ -702,19 +702,19 @@ public:
   void beginModule();
 
   /// \brief Emit all Dwarf sections that should come after the content.
-  void endModule();
+  void endModule() override;
 
   /// \brief Gather pre-function debug information.
-  void beginFunction(const MachineFunction *MF);
+  void beginFunction(const MachineFunction *MF) override;
 
   /// \brief Gather and emit post-function debug information.
-  void endFunction(const MachineFunction *MF);
+  void endFunction(const MachineFunction *MF) override;
 
   /// \brief Process beginning of an instruction.
-  void beginInstruction(const MachineInstr *MI);
+  void beginInstruction(const MachineInstr *MI) override;
 
   /// \brief Process end of an instruction.
-  void endInstruction();
+  void endInstruction() override;
 
   /// \brief Add a DIE to the set of types that we're going to pull into
   /// type units.
@@ -726,7 +726,7 @@ public:
 
   /// \brief For symbols that have a size designated (e.g. common symbols),
   /// this tracks that size.
-  void setSymbolSize(const MCSymbol *Sym, uint64_t Size) {
+  void setSymbolSize(const MCSymbol *Sym, uint64_t Size) override {
     SymSize[Sym] = Size;
   }
 
index 14357c6a367501616e8b226280a05f13ba140b97..f7924827518e19308efffe92067005be929acd37 100644 (file)
@@ -130,19 +130,19 @@ public:
 
   /// endModule - Emit all exception information that should come after the
   /// content.
-  virtual void endModule();
+  void endModule() override;
 
   /// beginFunction - Gather pre-function exception information.  Assumes being
   /// emitted immediately after the function entry point.
-  virtual void beginFunction(const MachineFunction *MF);
+  void beginFunction(const MachineFunction *MF) override;
 
   /// endFunction - Gather and emit post-function exception information.
-  virtual void endFunction(const MachineFunction *);
+  void endFunction(const MachineFunction *) override;
 
   // We don't need these.
-  virtual void setSymbolSize(const MCSymbol *Sym, uint64_t Size) {}
-  virtual void beginInstruction(const MachineInstr *MI) {}
-  virtual void endInstruction() {}
+  void setSymbolSize(const MCSymbol *Sym, uint64_t Size) override {}
+  void beginInstruction(const MachineInstr *MI) override {}
+  void endInstruction() override {}
 };
 
 class DwarfCFIException : public DwarfException {
@@ -169,18 +169,18 @@ public:
 
   /// endModule - Emit all exception information that should come after the
   /// content.
-  virtual void endModule();
+  void endModule() override;
 
   /// beginFunction - Gather pre-function exception information.  Assumes being
   /// emitted immediately after the function entry point.
-  virtual void beginFunction(const MachineFunction *MF);
+  void beginFunction(const MachineFunction *MF) override;
 
   /// endFunction - Gather and emit post-function exception information.
-  virtual void endFunction(const MachineFunction *);
+  void endFunction(const MachineFunction *) override;
 };
 
 class ARMException : public DwarfException {
-  void EmitTypeInfos(unsigned TTypeEncoding);
+  void EmitTypeInfos(unsigned TTypeEncoding) override;
   ARMTargetStreamer &getTargetStreamer();
 
   /// shouldEmitCFI - Per-function flag to indicate if frame CFI info
@@ -196,14 +196,14 @@ public:
 
   /// endModule - Emit all exception information that should come after the
   /// content.
-  virtual void endModule();
+  void endModule() override;
 
   /// beginFunction - Gather pre-function exception information.  Assumes being
   /// emitted immediately after the function entry point.
-  virtual void beginFunction(const MachineFunction *MF);
+  void beginFunction(const MachineFunction *MF) override;
 
   /// endFunction - Gather and emit post-function exception information.
-  virtual void endFunction(const MachineFunction *);
+  void endFunction(const MachineFunction *) override;
 };
 
 class Win64Exception : public DwarfException {
@@ -228,14 +228,14 @@ public:
 
   /// endModule - Emit all exception information that should come after the
   /// content.
-  virtual void endModule();
+  void endModule() override;
 
   /// beginFunction - Gather pre-function exception information.  Assumes being
   /// emitted immediately after the function entry point.
-  virtual void beginFunction(const MachineFunction *MF);
+  void beginFunction(const MachineFunction *MF) override;
 
   /// endFunction - Gather and emit post-function exception information.
-  virtual void endFunction(const MachineFunction *);
+  void endFunction(const MachineFunction *) override;
 };
 
 } // End of namespace llvm
index 0931ecaab0918aa721d656582c96d4def782bf73..bfcbe6b94e7f8b05d9213f6deb2c177e75f2bbd1 100644 (file)
@@ -35,8 +35,8 @@ namespace {
 
   class ErlangGCPrinter : public GCMetadataPrinter {
   public:
-    void beginAssembly(AsmPrinter &AP);
-    void finishAssembly(AsmPrinter &AP);
+    void beginAssembly(AsmPrinter &AP) override;
+    void finishAssembly(AsmPrinter &AP) override;
   };
 
 }
index c3c1888142b84c71d0cb5f4d3e1aadaca8cf4fa3..5a9ecd794a8d7bc74330fbe02a3a0536bccc36ec 100644 (file)
@@ -33,8 +33,8 @@ namespace {
 
   class OcamlGCMetadataPrinter : public GCMetadataPrinter {
   public:
-    void beginAssembly(AsmPrinter &AP);
-    void finishAssembly(AsmPrinter &AP);
+    void beginAssembly(AsmPrinter &AP) override;
+    void finishAssembly(AsmPrinter &AP) override;
   };
 
 }
index b79473b2fdea5c0ea5470cab8f332ed37090ed37..1f34c987cf3b44e1a68f0ed12877ccdf38cb0a6f 100644 (file)
@@ -122,22 +122,22 @@ public:
       free(I->second);
   }
 
-  virtual void setSymbolSize(const llvm::MCSymbol *, uint64_t) {}
+  void setSymbolSize(const llvm::MCSymbol *, uint64_t) override {}
 
   /// \brief Emit the COFF section that holds the line table information.
-  virtual void endModule();
+  void endModule() override;
 
   /// \brief Gather pre-function debug information.
-  virtual void beginFunction(const MachineFunction *MF);
+  void beginFunction(const MachineFunction *MF) override;
 
   /// \brief Gather post-function debug information.
-  virtual void endFunction(const MachineFunction *);
+  void endFunction(const MachineFunction *) override;
 
   /// \brief Process beginning of an instruction.
-  virtual void beginInstruction(const MachineInstr *MI);
+  void beginInstruction(const MachineInstr *MI) override;
 
   /// \brief Process end of an instruction.
-  virtual void endInstruction() {}
+  void endInstruction() override {}
 };
 } // End of namespace llvm
 
index b5e24db06341f74767880866345ba9f2d62f2da9..842d5a3ee7357bcd5d248f494dca52143df97d4f 100644 (file)
@@ -409,7 +409,7 @@ public:
   explicit WorkListRemover(DAGCombiner &dc)
     : SelectionDAG::DAGUpdateListener(dc.getDAG()), DC(dc) {}
 
-  virtual void NodeDeleted(SDNode *N, SDNode *E) {
+  void NodeDeleted(SDNode *N, SDNode *E) override {
     DC.removeFromWorkList(N);
   }
 };
index 174d78de9b54b1535beb4ca0b9f9f75ed952d098..eb5efd4da045021938ffaa315c52099f7490ac9b 100644 (file)
@@ -152,10 +152,10 @@ private:
 
 public:
   // DAGUpdateListener implementation.
-  virtual void NodeDeleted(SDNode *N, SDNode *E) {
+  void NodeDeleted(SDNode *N, SDNode *E) override {
     ForgetNode(N);
   }
-  virtual void NodeUpdated(SDNode *N) {}
+  void NodeUpdated(SDNode *N) override {}
 
   // Node replacement helpers
   void ReplacedNode(SDNode *N) {
index eb132304ef2cd5c66caee52dc9588092f9ef2d76..e141883744860f94fbd5b7b4a783d55ee16058ab 100644 (file)
@@ -634,7 +634,7 @@ namespace {
       : SelectionDAG::DAGUpdateListener(dtl.getDAG()),
         DTL(dtl), NodesToAnalyze(nta) {}
 
-    virtual void NodeDeleted(SDNode *N, SDNode *E) {
+    void NodeDeleted(SDNode *N, SDNode *E) override {
       assert(N->getNodeId() != DAGTypeLegalizer::ReadyToProcess &&
              N->getNodeId() != DAGTypeLegalizer::Processed &&
              "Invalid node ID for RAUW deletion!");
@@ -655,7 +655,7 @@ namespace {
         NodesToAnalyze.insert(E);
     }
 
-    virtual void NodeUpdated(SDNode *N) {
+    void NodeUpdated(SDNode *N) override {
       // Node updates can mean pretty much anything.  It is possible that an
       // operand was set to something already processed (f.e.) in which case
       // this node could become ready.  Recompute its flags.
index 6c5e0ab8b2cf56a0b82941608f471572a4a38013..0687392a344e866c93e9eda328b905209e9fd64d 100644 (file)
@@ -80,7 +80,7 @@ public:
   ScheduleDAGFast(MachineFunction &mf)
     : ScheduleDAGSDNodes(mf) {}
 
-  void Schedule();
+  void Schedule() override;
 
   /// AddPred - adds a predecessor edge to SUnit SU.
   /// This returns true if this is a new predecessor.
@@ -107,7 +107,7 @@ private:
   void ListScheduleBottomUp();
 
   /// forceUnitLatencies - The fast scheduler doesn't care about real latencies.
-  bool forceUnitLatencies() const { return true; }
+  bool forceUnitLatencies() const override { return true; }
 };
 }  // end anonymous namespace
 
@@ -646,9 +646,10 @@ class ScheduleDAGLinearize : public ScheduleDAGSDNodes {
 public:
   ScheduleDAGLinearize(MachineFunction &mf) : ScheduleDAGSDNodes(mf) {}
 
-  void Schedule();
+  void Schedule() override;
 
-  MachineBasicBlock *EmitSchedule(MachineBasicBlock::iterator &InsertPos);
+  MachineBasicBlock *
+    EmitSchedule(MachineBasicBlock::iterator &InsertPos) override;
 
 private:
   std::vector<SDNode*> Sequence;
index c49810935d8c93d3942010063e30cbf16b93f68b..8932f15b3716020f56b2b17c7d7160d4384b296c 100644 (file)
@@ -177,7 +177,7 @@ public:
     delete AvailableQueue;
   }
 
-  void Schedule();
+  void Schedule() override;
 
   ScheduleHazardRecognizer *getHazardRec() { return HazardRec; }
 
@@ -261,7 +261,7 @@ private:
 
   /// forceUnitLatencies - Register-pressure-reducing scheduling doesn't
   /// need actual latency information but the hybrid scheduler does.
-  bool forceUnitLatencies() const {
+  bool forceUnitLatencies() const override {
     return !NeedLatency;
   }
 };
@@ -1675,13 +1675,13 @@ public:
     return scheduleDAG->getHazardRec();
   }
 
-  void initNodes(std::vector<SUnit> &sunits);
+  void initNodes(std::vector<SUnit> &sunits) override;
 
-  void addNode(const SUnit *SU);
+  void addNode(const SUnit *SU) override;
 
-  void updateNode(const SUnit *SU);
+  void updateNode(const SUnit *SU) override;
 
-  void releaseState() {
+  void releaseState() override {
     SUnits = 0;
     SethiUllmanNumbers.clear();
     std::fill(RegPressure.begin(), RegPressure.end(), 0);
@@ -1695,15 +1695,15 @@ public:
     return SU->getNode()->getIROrder();
   }
 
-  bool empty() const { return Queue.empty(); }
+  bool empty() const override { return Queue.empty(); }
 
-  void push(SUnit *U) {
+  void push(SUnit *U) override {
     assert(!U->NodeQueueId && "Node in the queue already");
     U->NodeQueueId = ++CurQueueId;
     Queue.push_back(U);
   }
 
-  void remove(SUnit *SU) {
+  void remove(SUnit *SU) override {
     assert(!Queue.empty() && "Queue is empty!");
     assert(SU->NodeQueueId != 0 && "Not in queue!");
     std::vector<SUnit *>::iterator I = std::find(Queue.begin(), Queue.end(),
@@ -1714,7 +1714,7 @@ public:
     SU->NodeQueueId = 0;
   }
 
-  bool tracksRegPressure() const { return TracksRegPressure; }
+  bool tracksRegPressure() const override { return TracksRegPressure; }
 
   void dumpRegPressure() const;
 
@@ -1724,9 +1724,9 @@ public:
 
   int RegPressureDiff(SUnit *SU, unsigned &LiveUses) const;
 
-  void scheduledNode(SUnit *SU);
+  void scheduledNode(SUnit *SU) override;
 
-  void unscheduledNode(SUnit *SU);
+  void unscheduledNode(SUnit *SU) override;
 
 protected:
   bool canClobber(const SUnit *SU, const SUnit *Op);
@@ -1776,13 +1776,13 @@ public:
                          tii, tri, tli),
       Picker(this) {}
 
-  bool isBottomUp() const { return SF::IsBottomUp; }
+  bool isBottomUp() const override { return SF::IsBottomUp; }
 
-  bool isReady(SUnit *U) const {
+  bool isReady(SUnit *U) const override {
     return Picker.HasReadyFilter && Picker.isReady(U, getCurCycle());
   }
 
-  SUnit *pop() {
+  SUnit *pop() override {
     if (Queue.empty()) return NULL;
 
     SUnit *V = popFromQueue(Queue, Picker, scheduleDAG);
index 2ff37e0a15e195c20110a66479ff7cd150eabaec..5e11dbb5fb89039a3b8afe06f4637093ad63d093 100644 (file)
@@ -117,13 +117,13 @@ namespace llvm {
     virtual MachineBasicBlock*
     EmitSchedule(MachineBasicBlock::iterator &InsertPos);
 
-    virtual void dumpNode(const SUnit *SU) const;
+    void dumpNode(const SUnit *SU) const override;
 
     void dumpSchedule() const;
 
-    virtual std::string getGraphNodeLabel(const SUnit *SU) const;
+    std::string getGraphNodeLabel(const SUnit *SU) const override;
 
-    virtual std::string getDAGName() const;
+    std::string getDAGName() const override;
 
     virtual void getCustomGraphFeatures(GraphWriter<ScheduleDAG*> &GW) const;
 
index 58aa1fe0ebbead65942275fc791f833e25947aac..fb861030de55c2e0c93c2f43f2b8cc463b1629d4 100644 (file)
@@ -80,7 +80,7 @@ public:
     delete AvailableQueue;
   }
 
-  void Schedule();
+  void Schedule() override;
 
 private:
   void releaseSucc(SUnit *SU, const SDep &D);
index eac55124c2446158a46c80312b935cbdc08dfff5..9a9062af9d78c0c5edf1280592f6a3a88e340439 100644 (file)
@@ -5674,7 +5674,7 @@ class RAUWUpdateListener : public SelectionDAG::DAGUpdateListener {
   SDNode::use_iterator &UI;
   SDNode::use_iterator &UE;
 
-  virtual void NodeDeleted(SDNode *N, SDNode *E) {
+  void NodeDeleted(SDNode *N, SDNode *E) override {
     // Increment the iterator as needed.
     while (UI != UE && N == *UI)
       ++UI;
index 298fb3187614a694242f20ab90c093fbac542ed0..cda0b57a159854614b62f24c5aee593be2c817a0 100644 (file)
@@ -803,7 +803,7 @@ public:
   /// NodeDeleted - Handle nodes deleted from the graph. If the node being
   /// deleted is the current ISelPosition node, update ISelPosition.
   ///
-  virtual void NodeDeleted(SDNode *N, SDNode *E) {
+  void NodeDeleted(SDNode *N, SDNode *E) override {
     if (ISelPosition == SelectionDAG::allnodes_iterator(N))
       ++ISelPosition;
   }