mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-01-31 12:41:49 +01:00
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.
llvm-svn: 143715
This commit is contained in:
parent
6269524bb5
commit
afdb17e3d2
@ -33,7 +33,7 @@ struct DOTGraphTraits<const Function*> : public DefaultDOTGraphTraits {
|
|||||||
}
|
}
|
||||||
|
|
||||||
static std::string getSimpleNodeLabel(const BasicBlock *Node,
|
static std::string getSimpleNodeLabel(const BasicBlock *Node,
|
||||||
const Function *Graph) {
|
const Function *) {
|
||||||
if (!Node->getName().empty())
|
if (!Node->getName().empty())
|
||||||
return Node->getNameStr();
|
return Node->getNameStr();
|
||||||
|
|
||||||
@ -45,7 +45,7 @@ struct DOTGraphTraits<const Function*> : public DefaultDOTGraphTraits {
|
|||||||
}
|
}
|
||||||
|
|
||||||
static std::string getCompleteNodeLabel(const BasicBlock *Node,
|
static std::string getCompleteNodeLabel(const BasicBlock *Node,
|
||||||
const Function *Graph) {
|
const Function *) {
|
||||||
std::string Str;
|
std::string Str;
|
||||||
raw_string_ostream OS(Str);
|
raw_string_ostream OS(Str);
|
||||||
|
|
||||||
|
@ -32,30 +32,30 @@ public:
|
|||||||
|
|
||||||
/// emitFunctionAnnot - This may be implemented to emit a string right before
|
/// emitFunctionAnnot - This may be implemented to emit a string right before
|
||||||
/// the start of a function.
|
/// the start of a function.
|
||||||
virtual void emitFunctionAnnot(const Function *F,
|
virtual void emitFunctionAnnot(const Function *,
|
||||||
formatted_raw_ostream &OS) {}
|
formatted_raw_ostream &) {}
|
||||||
|
|
||||||
/// emitBasicBlockStartAnnot - This may be implemented to emit a string right
|
/// emitBasicBlockStartAnnot - This may be implemented to emit a string right
|
||||||
/// after the basic block label, but before the first instruction in the
|
/// after the basic block label, but before the first instruction in the
|
||||||
/// block.
|
/// block.
|
||||||
virtual void emitBasicBlockStartAnnot(const BasicBlock *BB,
|
virtual void emitBasicBlockStartAnnot(const BasicBlock *,
|
||||||
formatted_raw_ostream &OS) {
|
formatted_raw_ostream &) {
|
||||||
}
|
}
|
||||||
|
|
||||||
/// emitBasicBlockEndAnnot - This may be implemented to emit a string right
|
/// emitBasicBlockEndAnnot - This may be implemented to emit a string right
|
||||||
/// after the basic block.
|
/// after the basic block.
|
||||||
virtual void emitBasicBlockEndAnnot(const BasicBlock *BB,
|
virtual void emitBasicBlockEndAnnot(const BasicBlock *,
|
||||||
formatted_raw_ostream &OS) {
|
formatted_raw_ostream &) {
|
||||||
}
|
}
|
||||||
|
|
||||||
/// emitInstructionAnnot - This may be implemented to emit a string right
|
/// emitInstructionAnnot - This may be implemented to emit a string right
|
||||||
/// before an instruction is emitted.
|
/// before an instruction is emitted.
|
||||||
virtual void emitInstructionAnnot(const Instruction *I,
|
virtual void emitInstructionAnnot(const Instruction *,
|
||||||
formatted_raw_ostream &OS) {}
|
formatted_raw_ostream &) {}
|
||||||
|
|
||||||
/// printInfoComment - This may be implemented to emit a comment to the
|
/// printInfoComment - This may be implemented to emit a comment to the
|
||||||
/// right of an instruction or global value.
|
/// 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
|
} // End llvm namespace
|
||||||
|
@ -59,9 +59,9 @@ public:
|
|||||||
/// NotifyFunctionEmitted - Called after a function has been successfully
|
/// NotifyFunctionEmitted - Called after a function has been successfully
|
||||||
/// emitted to memory. The function still has its MachineFunction attached,
|
/// emitted to memory. The function still has its MachineFunction attached,
|
||||||
/// if you should happen to need that.
|
/// if you should happen to need that.
|
||||||
virtual void NotifyFunctionEmitted(const Function &F,
|
virtual void NotifyFunctionEmitted(const Function &,
|
||||||
void *Code, size_t Size,
|
void *, size_t,
|
||||||
const EmittedFunctionDetails &Details) {}
|
const EmittedFunctionDetails &) {}
|
||||||
|
|
||||||
/// NotifyFreeingMachineCode - Called from freeMachineCodeForFunction(), after
|
/// NotifyFreeingMachineCode - Called from freeMachineCodeForFunction(), after
|
||||||
/// the global mapping is removed, but before the machine code is returned to
|
/// the global mapping is removed, but before the machine code is returned to
|
||||||
@ -71,7 +71,7 @@ public:
|
|||||||
/// parameter to a previous NotifyFunctionEmitted call. The Function passed
|
/// parameter to a previous NotifyFunctionEmitted call. The Function passed
|
||||||
/// to NotifyFunctionEmitted may have been destroyed by the time of the
|
/// to NotifyFunctionEmitted may have been destroyed by the time of the
|
||||||
/// matching NotifyFreeingMachineCode call.
|
/// matching NotifyFreeingMachineCode call.
|
||||||
virtual void NotifyFreeingMachineCode(void *OldPtr) {}
|
virtual void NotifyFreeingMachineCode(void *) {}
|
||||||
};
|
};
|
||||||
|
|
||||||
// This returns NULL if support isn't available.
|
// This returns NULL if support isn't available.
|
||||||
|
@ -42,13 +42,13 @@ public:
|
|||||||
/// top of the graph.
|
/// top of the graph.
|
||||||
///
|
///
|
||||||
template<typename GraphType>
|
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
|
/// getGraphProperties - Return any custom properties that should be included
|
||||||
/// in the top level graph structure for dot.
|
/// in the top level graph structure for dot.
|
||||||
///
|
///
|
||||||
template<typename GraphType>
|
template<typename GraphType>
|
||||||
static std::string getGraphProperties(const GraphType& Graph) {
|
static std::string getGraphProperties(const GraphType &) {
|
||||||
return "";
|
return "";
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -61,44 +61,44 @@ public:
|
|||||||
|
|
||||||
/// isNodeHidden - If the function returns true, the given node is not
|
/// isNodeHidden - If the function returns true, the given node is not
|
||||||
/// displayed in the graph.
|
/// displayed in the graph.
|
||||||
static bool isNodeHidden(const void *Node) {
|
static bool isNodeHidden(const void *) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// getNodeLabel - Given a node and a pointer to the top level graph, return
|
/// getNodeLabel - Given a node and a pointer to the top level graph, return
|
||||||
/// the label to print in the node.
|
/// the label to print in the node.
|
||||||
template<typename GraphType>
|
template<typename GraphType>
|
||||||
std::string getNodeLabel(const void *Node, const GraphType& Graph) {
|
std::string getNodeLabel(const void *, const GraphType &) {
|
||||||
return "";
|
return "";
|
||||||
}
|
}
|
||||||
|
|
||||||
/// hasNodeAddressLabel - If this method returns true, the address of the node
|
/// hasNodeAddressLabel - If this method returns true, the address of the node
|
||||||
/// is added to the label of the node.
|
/// is added to the label of the node.
|
||||||
template<typename GraphType>
|
template<typename GraphType>
|
||||||
static bool hasNodeAddressLabel(const void *Node, const GraphType& Graph) {
|
static bool hasNodeAddressLabel(const void *, const GraphType &) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// If you want to specify custom node attributes, this is the place to do so
|
/// If you want to specify custom node attributes, this is the place to do so
|
||||||
///
|
///
|
||||||
template<typename GraphType>
|
template<typename GraphType>
|
||||||
static std::string getNodeAttributes(const void *Node,
|
static std::string getNodeAttributes(const void *,
|
||||||
const GraphType& Graph) {
|
const GraphType &) {
|
||||||
return "";
|
return "";
|
||||||
}
|
}
|
||||||
|
|
||||||
/// If you want to override the dot attributes printed for a particular edge,
|
/// If you want to override the dot attributes printed for a particular edge,
|
||||||
/// override this method.
|
/// override this method.
|
||||||
template<typename EdgeIter, typename GraphType>
|
template<typename EdgeIter, typename GraphType>
|
||||||
static std::string getEdgeAttributes(const void *Node, EdgeIter EI,
|
static std::string getEdgeAttributes(const void *, EdgeIter,
|
||||||
const GraphType& Graph) {
|
const GraphType &) {
|
||||||
return "";
|
return "";
|
||||||
}
|
}
|
||||||
|
|
||||||
/// getEdgeSourceLabel - If you want to label the edge source itself,
|
/// getEdgeSourceLabel - If you want to label the edge source itself,
|
||||||
/// implement this method.
|
/// implement this method.
|
||||||
template<typename EdgeIter>
|
template<typename EdgeIter>
|
||||||
static std::string getEdgeSourceLabel(const void *Node, EdgeIter I) {
|
static std::string getEdgeSourceLabel(const void *, EdgeIter) {
|
||||||
return "";
|
return "";
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -106,7 +106,7 @@ public:
|
|||||||
/// should actually target another edge source, not a node. If this method is
|
/// should actually target another edge source, not a node. If this method is
|
||||||
/// implemented, getEdgeTarget should be implemented.
|
/// implemented, getEdgeTarget should be implemented.
|
||||||
template<typename EdgeIter>
|
template<typename EdgeIter>
|
||||||
static bool edgeTargetsEdgeSource(const void *Node, EdgeIter I) {
|
static bool edgeTargetsEdgeSource(const void *, EdgeIter) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -114,7 +114,7 @@ public:
|
|||||||
/// called to determine which outgoing edge of Node is the target of this
|
/// called to determine which outgoing edge of Node is the target of this
|
||||||
/// edge.
|
/// edge.
|
||||||
template<typename EdgeIter>
|
template<typename EdgeIter>
|
||||||
static EdgeIter getEdgeTarget(const void *Node, EdgeIter I) {
|
static EdgeIter getEdgeTarget(const void *, EdgeIter I) {
|
||||||
return I;
|
return I;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -126,13 +126,13 @@ public:
|
|||||||
|
|
||||||
/// numEdgeDestLabels - If hasEdgeDestLabels, this function returns the
|
/// numEdgeDestLabels - If hasEdgeDestLabels, this function returns the
|
||||||
/// number of incoming edge labels the given node has.
|
/// number of incoming edge labels the given node has.
|
||||||
static unsigned numEdgeDestLabels(const void *Node) {
|
static unsigned numEdgeDestLabels(const void *) {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// getEdgeDestLabel - If hasEdgeDestLabels, this function returns the
|
/// getEdgeDestLabel - If hasEdgeDestLabels, this function returns the
|
||||||
/// incoming edge label with the given index in the given node.
|
/// 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 "";
|
return "";
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -143,7 +143,7 @@ public:
|
|||||||
/// it to add things to the output graph.
|
/// it to add things to the output graph.
|
||||||
///
|
///
|
||||||
template<typename GraphType, typename GraphWriter>
|
template<typename GraphType, typename GraphWriter>
|
||||||
static void addCustomGraphFeatures(const GraphType& Graph, GraphWriter &GW) {}
|
static void addCustomGraphFeatures(const GraphType &, GraphWriter &) {}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user