From: Justin Bogner Date: Wed, 2 Sep 2015 22:28:47 +0000 (+0000) Subject: IR: Remove a redundant function. NFC X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=d034925a3423deda6aa3c99aeeca7b9d749ba885;p=llvm IR: Remove a redundant function. NFC Function::print isn't interestingly different from Value::print. Just let the only caller (in PrintCallGraphPass) call the Value version. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@246720 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/llvm/IR/Function.h b/include/llvm/IR/Function.h index 69c622cc9a8..0c507e4b972 100644 --- a/include/llvm/IR/Function.h +++ b/include/llvm/IR/Function.h @@ -524,10 +524,6 @@ public: Constant *getPrologueData() const; void setPrologueData(Constant *PrologueData); - /// Print the function to an output stream with an optional - /// AssemblyAnnotationWriter. - void print(raw_ostream &OS, AssemblyAnnotationWriter *AAW = nullptr) const; - /// viewCFG - This function is meant for use from the debugger. You can just /// say 'call F->viewCFG()' and a ghostview window should pop up from the /// program, displaying the CFG of the current function with the code for each diff --git a/lib/IR/AsmWriter.cpp b/lib/IR/AsmWriter.cpp index 1219aac8c6a..bc9b00e7de1 100644 --- a/lib/IR/AsmWriter.cpp +++ b/lib/IR/AsmWriter.cpp @@ -3199,13 +3199,6 @@ void AssemblyWriter::printUseLists(const Function *F) { // External Interface declarations //===----------------------------------------------------------------------===// -void Function::print(raw_ostream &ROS, AssemblyAnnotationWriter *AAW) const { - SlotTracker SlotTable(this->getParent()); - formatted_raw_ostream OS(ROS); - AssemblyWriter W(OS, SlotTable, this->getParent(), AAW); - W.printFunction(this); -} - void Module::print(raw_ostream &ROS, AssemblyAnnotationWriter *AAW, bool ShouldPreserveUseListOrder) const { SlotTracker SlotTable(this);