[llvm-commits] [llvm] r143715 - in /llvm/trunk/include/llvm: Analysis/CFGPrinter.h Assembly/AssemblyAnnotationWriter.h ExecutionEngine/JITEventListener.h Support/DOTGraphTraits.h

Eli Friedman eli.friedman at gmail.com
Fri Nov 4 11:11:56 PDT 2011


Author: efriedma
Date: Fri Nov  4 13:11:56 2011
New Revision: 143715

URL: http://llvm.org/viewvc/llvm-project?rev=143715&view=rev
Log:
Delete names for unused parameters in inline function definitions in headers, so LLVM users can compile with -Wunused-parameter.  PR11257; based on patch by Kevin Harris.


Modified:
    llvm/trunk/include/llvm/Analysis/CFGPrinter.h
    llvm/trunk/include/llvm/Assembly/AssemblyAnnotationWriter.h
    llvm/trunk/include/llvm/ExecutionEngine/JITEventListener.h
    llvm/trunk/include/llvm/Support/DOTGraphTraits.h

Modified: llvm/trunk/include/llvm/Analysis/CFGPrinter.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Analysis/CFGPrinter.h?rev=143715&r1=143714&r2=143715&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Analysis/CFGPrinter.h (original)
+++ llvm/trunk/include/llvm/Analysis/CFGPrinter.h Fri Nov  4 13:11:56 2011
@@ -33,7 +33,7 @@
   }
 
   static std::string getSimpleNodeLabel(const BasicBlock *Node,
-                                  const Function *Graph) {
+                                        const Function *) {
     if (!Node->getName().empty())
       return Node->getNameStr(); 
 
@@ -45,7 +45,7 @@
   }
 
   static std::string getCompleteNodeLabel(const BasicBlock *Node, 
-                                          const Function *Graph) {
+                                          const Function *) {
     std::string Str;
     raw_string_ostream OS(Str);
 

Modified: llvm/trunk/include/llvm/Assembly/AssemblyAnnotationWriter.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Assembly/AssemblyAnnotationWriter.h?rev=143715&r1=143714&r2=143715&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Assembly/AssemblyAnnotationWriter.h (original)
+++ llvm/trunk/include/llvm/Assembly/AssemblyAnnotationWriter.h Fri Nov  4 13:11:56 2011
@@ -32,30 +32,30 @@
 
   /// emitFunctionAnnot - This may be implemented to emit a string right before
   /// the start of a function.
-  virtual void emitFunctionAnnot(const Function *F,
-                                 formatted_raw_ostream &OS) {}
+  virtual void emitFunctionAnnot(const Function *,
+                                 formatted_raw_ostream &) {}
 
   /// emitBasicBlockStartAnnot - This may be implemented to emit a string right
   /// after the basic block label, but before the first instruction in the
   /// block.
-  virtual void emitBasicBlockStartAnnot(const BasicBlock *BB,
-                                        formatted_raw_ostream &OS) {
+  virtual void emitBasicBlockStartAnnot(const BasicBlock *,
+                                        formatted_raw_ostream &) {
   }
 
   /// emitBasicBlockEndAnnot - This may be implemented to emit a string right
   /// after the basic block.
-  virtual void emitBasicBlockEndAnnot(const BasicBlock *BB,
-                                      formatted_raw_ostream &OS) {
+  virtual void emitBasicBlockEndAnnot(const BasicBlock *,
+                                      formatted_raw_ostream &) {
   }
 
   /// emitInstructionAnnot - This may be implemented to emit a string right
   /// before an instruction is emitted.
-  virtual void emitInstructionAnnot(const Instruction *I, 
-                                    formatted_raw_ostream &OS) {}
+  virtual void emitInstructionAnnot(const Instruction *, 
+                                    formatted_raw_ostream &) {}
 
   /// printInfoComment - This may be implemented to emit a comment to the
   /// right of an instruction or global value.
-  virtual void printInfoComment(const Value &V, formatted_raw_ostream &OS) {}
+  virtual void printInfoComment(const Value &, formatted_raw_ostream &) {}
 };
 
 } // End llvm namespace

Modified: llvm/trunk/include/llvm/ExecutionEngine/JITEventListener.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/ExecutionEngine/JITEventListener.h?rev=143715&r1=143714&r2=143715&view=diff
==============================================================================
--- llvm/trunk/include/llvm/ExecutionEngine/JITEventListener.h (original)
+++ llvm/trunk/include/llvm/ExecutionEngine/JITEventListener.h Fri Nov  4 13:11:56 2011
@@ -59,9 +59,9 @@
   /// NotifyFunctionEmitted - Called after a function has been successfully
   /// emitted to memory.  The function still has its MachineFunction attached,
   /// if you should happen to need that.
-  virtual void NotifyFunctionEmitted(const Function &F,
-                                     void *Code, size_t Size,
-                                     const EmittedFunctionDetails &Details) {}
+  virtual void NotifyFunctionEmitted(const Function &,
+                                     void *, size_t,
+                                     const EmittedFunctionDetails &) {}
 
   /// NotifyFreeingMachineCode - Called from freeMachineCodeForFunction(), after
   /// the global mapping is removed, but before the machine code is returned to
@@ -71,7 +71,7 @@
   /// parameter to a previous NotifyFunctionEmitted call.  The Function passed
   /// to NotifyFunctionEmitted may have been destroyed by the time of the
   /// matching NotifyFreeingMachineCode call.
-  virtual void NotifyFreeingMachineCode(void *OldPtr) {}
+  virtual void NotifyFreeingMachineCode(void *) {}
 };
 
 // This returns NULL if support isn't available.

Modified: llvm/trunk/include/llvm/Support/DOTGraphTraits.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Support/DOTGraphTraits.h?rev=143715&r1=143714&r2=143715&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Support/DOTGraphTraits.h (original)
+++ llvm/trunk/include/llvm/Support/DOTGraphTraits.h Fri Nov  4 13:11:56 2011
@@ -42,13 +42,13 @@
   /// top of the graph.
   ///
   template<typename GraphType>
-  static std::string getGraphName(const GraphType& Graph) { return ""; }
+  static std::string getGraphName(const GraphType &) { return ""; }
 
   /// getGraphProperties - Return any custom properties that should be included
   /// in the top level graph structure for dot.
   ///
   template<typename GraphType>
-  static std::string getGraphProperties(const GraphType& Graph) {
+  static std::string getGraphProperties(const GraphType &) {
     return "";
   }
 
@@ -61,44 +61,44 @@
 
   /// isNodeHidden - If the function returns true, the given node is not
   /// displayed in the graph.
-  static bool isNodeHidden(const void *Node) {
+  static bool isNodeHidden(const void *) {
     return false;
   }
 
   /// getNodeLabel - Given a node and a pointer to the top level graph, return
   /// the label to print in the node.
   template<typename GraphType>
-  std::string getNodeLabel(const void *Node, const GraphType& Graph) {
+  std::string getNodeLabel(const void *, const GraphType &) {
     return "";
   }
 
   /// hasNodeAddressLabel - If this method returns true, the address of the node
   /// is added to the label of the node.
   template<typename GraphType>
-  static bool hasNodeAddressLabel(const void *Node, const GraphType& Graph) {
+  static bool hasNodeAddressLabel(const void *, const GraphType &) {
     return false;
   }
 
   /// If you want to specify custom node attributes, this is the place to do so
   ///
   template<typename GraphType>
-  static std::string getNodeAttributes(const void *Node,
-                                       const GraphType& Graph) {
+  static std::string getNodeAttributes(const void *,
+                                       const GraphType &) {
     return "";
   }
 
   /// If you want to override the dot attributes printed for a particular edge,
   /// override this method.
   template<typename EdgeIter, typename GraphType>
-  static std::string getEdgeAttributes(const void *Node, EdgeIter EI,
-                                       const GraphType& Graph) {
+  static std::string getEdgeAttributes(const void *, EdgeIter,
+                                       const GraphType &) {
     return "";
   }
 
   /// getEdgeSourceLabel - If you want to label the edge source itself,
   /// implement this method.
   template<typename EdgeIter>
-  static std::string getEdgeSourceLabel(const void *Node, EdgeIter I) {
+  static std::string getEdgeSourceLabel(const void *, EdgeIter) {
     return "";
   }
 
@@ -106,7 +106,7 @@
   /// should actually target another edge source, not a node.  If this method is
   /// implemented, getEdgeTarget should be implemented.
   template<typename EdgeIter>
-  static bool edgeTargetsEdgeSource(const void *Node, EdgeIter I) {
+  static bool edgeTargetsEdgeSource(const void *, EdgeIter) {
     return false;
   }
 
@@ -114,7 +114,7 @@
   /// called to determine which outgoing edge of Node is the target of this
   /// edge.
   template<typename EdgeIter>
-  static EdgeIter getEdgeTarget(const void *Node, EdgeIter I) {
+  static EdgeIter getEdgeTarget(const void *, EdgeIter I) {
     return I;
   }
 
@@ -126,13 +126,13 @@
 
   /// numEdgeDestLabels - If hasEdgeDestLabels, this function returns the
   /// number of incoming edge labels the given node has.
-  static unsigned numEdgeDestLabels(const void *Node) {
+  static unsigned numEdgeDestLabels(const void *) {
     return 0;
   }
 
   /// getEdgeDestLabel - If hasEdgeDestLabels, this function returns the
   /// incoming edge label with the given index in the given node.
-  static std::string getEdgeDestLabel(const void *Node, unsigned i) {
+  static std::string getEdgeDestLabel(const void *, unsigned) {
     return "";
   }
 
@@ -143,7 +143,7 @@
   /// it to add things to the output graph.
   ///
   template<typename GraphType, typename GraphWriter>
-  static void addCustomGraphFeatures(const GraphType& Graph, GraphWriter &GW) {}
+  static void addCustomGraphFeatures(const GraphType &, GraphWriter &) {}
 };
 
 





More information about the llvm-commits mailing list