OSDN Git Service

[PM] Rename the IR printing pass header to a more generic and correct
authorChandler Carruth <chandlerc@gmail.com>
Sun, 12 Jan 2014 11:10:32 +0000 (11:10 +0000)
committerChandler Carruth <chandlerc@gmail.com>
Sun, 12 Jan 2014 11:10:32 +0000 (11:10 +0000)
name to match the source file which I got earlier. Update the include
sites. Also modernize the comments in the header to use the more
recommended doxygen style.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@199041 91177308-0d34-0410-b5e6-96231b3b80d8

16 files changed:
include/llvm/IR/IRPrintingPasses.h [moved from include/llvm/IR/PrintModulePass.h with 60% similarity]
include/llvm/LinkAllPasses.h
lib/Analysis/LoopPass.cpp
lib/CodeGen/LLVMTargetMachine.cpp
lib/CodeGen/Passes.cpp
lib/IR/AsmWriter.cpp
lib/IR/IRPrintingPasses.cpp
lib/IR/LegacyPassManager.cpp
lib/IR/Pass.cpp
lib/Target/CppBackend/CPPBackend.cpp
lib/Target/NVPTX/NVPTXTargetMachine.cpp
tools/llc/llc.cpp
tools/llvm-extract/llvm-extract.cpp
tools/llvm-stress/llvm-stress.cpp
tools/opt/opt.cpp
unittests/IR/LegacyPassManagerTest.cpp

similarity index 60%
rename from include/llvm/IR/PrintModulePass.h
rename to include/llvm/IR/IRPrintingPasses.h
index 3c18bd5..45d3c7a 100644 (file)
@@ -1,4 +1,4 @@
-//===- PrintModulePass.h - IR Printing Passes -------------------*- C++ -*-===//
+//===- IRPrintingPasses.h - Passes to print out IR constructs ---*- C++ -*-===//
 //
 //                     The LLVM Compiler Infrastructure
 //
@@ -6,13 +6,14 @@
 // License. See LICENSE.TXT for details.
 //
 //===----------------------------------------------------------------------===//
-//
-// This file defines two passes to print out a module.  The PrintModulePass pass
-// simply prints out the entire module when it is executed.  The
-// PrintFunctionPass class is designed to be pipelined with other
-// FunctionPass's, and prints out the functions of the module as they are
-// processed.
-//
+/// \file
+///
+/// This file defines passes to print out IR in various granularities. The
+/// PrintModulePass pass simply prints out the entire module when it is
+/// executed. The PrintFunctionPass class is designed to be pipelined with
+/// other FunctionPass's, and prints out the functions of the module as they
+/// are processed.
+///
 //===----------------------------------------------------------------------===//
 
 #ifndef LLVM_IR_PRINTMODULEPASS_H
@@ -26,19 +27,19 @@ class ModulePass;
 class BasicBlockPass;
 class raw_ostream;
 
-/// createPrintModulePass - Create and return a pass that writes the
-/// module to the specified raw_ostream.
+/// \brief Create and return a pass that writes the module to the specified
+/// \c raw_ostream.
 ModulePass *createPrintModulePass(raw_ostream *OS, bool DeleteStream = false,
                                   const std::string &Banner = "");
 
-/// createPrintFunctionPass - Create and return a pass that prints
-/// functions to the specified raw_ostream as they are processed.
+/// \brief Create and return a pass that prints functions to the specified
+/// \c raw_ostream as they are processed.
 FunctionPass *createPrintFunctionPass(const std::string &Banner,
                                       raw_ostream *OS,
                                       bool DeleteStream = false);
 
-/// createPrintBasicBlockPass - Create and return a pass that writes the
-/// BB to the specified raw_ostream.
+/// \brief Create and return a pass that writes the BB to the specified
+/// \c raw_ostream.
 BasicBlockPass *createPrintBasicBlockPass(raw_ostream *OS,
                                           bool DeleteStream = false,
                                           const std::string &Banner = "");
index 106267a..6c8c5f7 100644 (file)
@@ -28,7 +28,7 @@
 #include "llvm/Analysis/ScalarEvolution.h"
 #include "llvm/CodeGen/Passes.h"
 #include "llvm/IR/Function.h"
-#include "llvm/IR/PrintModulePass.h"
+#include "llvm/IR/IRPrintingPasses.h"
 #include "llvm/Transforms/IPO.h"
 #include "llvm/Transforms/Instrumentation.h"
 #include "llvm/Transforms/ObjCARC.h"
index 3b08536..4775359 100644 (file)
@@ -14,7 +14,7 @@
 //===----------------------------------------------------------------------===//
 
 #include "llvm/Analysis/LoopPass.h"
-#include "llvm/IR/PrintModulePass.h"
+#include "llvm/IR/IRPrintingPasses.h"
 #include "llvm/Support/Debug.h"
 #include "llvm/Support/Timer.h"
 using namespace llvm;
index 10c896b..be90d5d 100644 (file)
@@ -17,7 +17,7 @@
 #include "llvm/CodeGen/MachineFunctionAnalysis.h"
 #include "llvm/CodeGen/MachineModuleInfo.h"
 #include "llvm/CodeGen/Passes.h"
-#include "llvm/IR/PrintModulePass.h"
+#include "llvm/IR/IRPrintingPasses.h"
 #include "llvm/MC/MCAsmInfo.h"
 #include "llvm/MC/MCContext.h"
 #include "llvm/MC/MCInstrInfo.h"
index 22e72f4..dd9cb55 100644 (file)
@@ -18,7 +18,7 @@
 #include "llvm/CodeGen/GCStrategy.h"
 #include "llvm/CodeGen/MachineFunctionPass.h"
 #include "llvm/CodeGen/RegAllocRegistry.h"
-#include "llvm/IR/PrintModulePass.h"
+#include "llvm/IR/IRPrintingPasses.h"
 #include "llvm/MC/MCAsmInfo.h"
 #include "llvm/PassManager.h"
 #include "llvm/Support/CommandLine.h"
index cfe07ff..91684c9 100644 (file)
 #include "llvm/IR/CallingConv.h"
 #include "llvm/IR/Constants.h"
 #include "llvm/IR/DerivedTypes.h"
+#include "llvm/IR/IRPrintingPasses.h"
 #include "llvm/IR/InlineAsm.h"
 #include "llvm/IR/IntrinsicInst.h"
 #include "llvm/IR/LLVMContext.h"
 #include "llvm/IR/Module.h"
 #include "llvm/IR/Operator.h"
-#include "llvm/IR/PrintModulePass.h"
 #include "llvm/IR/TypeFinder.h"
 #include "llvm/IR/ValueSymbolTable.h"
 #include "llvm/Support/CFG.h"
index cf82923..7240fd0 100644 (file)
@@ -11,7 +11,7 @@
 //
 //===----------------------------------------------------------------------===//
 
-#include "llvm/IR/PrintModulePass.h"
+#include "llvm/IR/IRPrintingPasses.h"
 #include "llvm/IR/Function.h"
 #include "llvm/IR/Module.h"
 #include "llvm/Pass.h"
index 85e50f7..ae94f05 100644 (file)
@@ -12,7 +12,7 @@
 //===----------------------------------------------------------------------===//
 
 
-#include "llvm/IR/PrintModulePass.h"
+#include "llvm/IR/IRPrintingPasses.h"
 #include "llvm/IR/LegacyPassManager.h"
 #include "llvm/IR/LegacyPassManagers.h"
 #include "llvm/IR/Module.h"
index e9f43ac..dc8eee5 100644 (file)
@@ -14,7 +14,7 @@
 //===----------------------------------------------------------------------===//
 
 #include "llvm/Pass.h"
-#include "llvm/IR/PrintModulePass.h"
+#include "llvm/IR/IRPrintingPasses.h"
 #include "llvm/PassRegistry.h"
 #include "llvm/Support/Debug.h"
 #include "llvm/Support/PassNameParser.h"
index 492b194..6e2dd0a 100644 (file)
@@ -1924,11 +1924,11 @@ void CppWriter::printProgram(const std::string& fname,
   Out << "#include <llvm/IR/DerivedTypes.h>\n";
   Out << "#include <llvm/IR/Function.h>\n";
   Out << "#include <llvm/IR/GlobalVariable.h>\n";
+  Out << "#include <llvm/IR/IRPrintingPasses.h>\n";
   Out << "#include <llvm/IR/InlineAsm.h>\n";
   Out << "#include <llvm/IR/Instructions.h>\n";
   Out << "#include <llvm/IR/LLVMContext.h>\n";
   Out << "#include <llvm/IR/Module.h>\n";
-  Out << "#include <llvm/IR/PrintModulePass.h>\n";
   Out << "#include <llvm/Support/FormattedStream.h>\n";
   Out << "#include <llvm/Support/MathExtras.h>\n";
   Out << "#include <algorithm>\n";
index 30de9cd..3c6c032 100644 (file)
@@ -25,7 +25,7 @@
 #include "llvm/CodeGen/MachineModuleInfo.h"
 #include "llvm/CodeGen/Passes.h"
 #include "llvm/IR/DataLayout.h"
-#include "llvm/IR/PrintModulePass.h"
+#include "llvm/IR/IRPrintingPasses.h"
 #include "llvm/MC/MCAsmInfo.h"
 #include "llvm/MC/MCInstrInfo.h"
 #include "llvm/MC/MCStreamer.h"
index 7073343..d1dd6d6 100644 (file)
@@ -14,9 +14,9 @@
 //===----------------------------------------------------------------------===//
 
 
-#include "llvm/IR/LLVMContext.h"
 #include "llvm/ADT/Triple.h"
-#include "llvm/IR/PrintModulePass.h"
+#include "llvm/IR/IRPrintingPasses.h"
+#include "llvm/IR/LLVMContext.h"
 #include "llvm/CodeGen/CommandFlags.h"
 #include "llvm/CodeGen/LinkAllAsmWriterComponents.h"
 #include "llvm/CodeGen/LinkAllCodegenComponents.h"
index a3a99bf..ecea005 100644 (file)
 //
 //===----------------------------------------------------------------------===//
 
-#include "llvm/IR/LLVMContext.h"
 #include "llvm/ADT/SetVector.h"
 #include "llvm/ADT/SmallPtrSet.h"
-#include "llvm/IR/PrintModulePass.h"
 #include "llvm/Bitcode/ReaderWriter.h"
 #include "llvm/IR/DataLayout.h"
+#include "llvm/IR/IRPrintingPasses.h"
+#include "llvm/IR/LLVMContext.h"
 #include "llvm/IR/Module.h"
 #include "llvm/IRReader/IRReader.h"
 #include "llvm/PassManager.h"
index 4f98df7..455b111 100644 (file)
 // different components in LLVM.
 //
 //===----------------------------------------------------------------------===//
-#include "llvm/IR/LLVMContext.h"
 #include "llvm/ADT/OwningPtr.h"
 #include "llvm/Analysis/CallGraphSCCPass.h"
 #include "llvm/Analysis/Verifier.h"
-#include "llvm/IR/PrintModulePass.h"
 #include "llvm/IR/Constants.h"
+#include "llvm/IR/IRPrintingPasses.h"
 #include "llvm/IR/Instruction.h"
+#include "llvm/IR/LLVMContext.h"
 #include "llvm/IR/Module.h"
 #include "llvm/PassManager.h"
 #include "llvm/Support/Debug.h"
index 5138ef6..44b3f13 100644 (file)
@@ -24,9 +24,9 @@
 #include "llvm/CodeGen/CommandFlags.h"
 #include "llvm/DebugInfo.h"
 #include "llvm/IR/DataLayout.h"
+#include "llvm/IR/IRPrintingPasses.h"
 #include "llvm/IR/LLVMContext.h"
 #include "llvm/IR/Module.h"
-#include "llvm/IR/PrintModulePass.h"
 #include "llvm/IRReader/IRReader.h"
 #include "llvm/LinkAllIR.h"
 #include "llvm/LinkAllPasses.h"
index 1b03305..b005c42 100644 (file)
 #include "llvm/IR/DerivedTypes.h"
 #include "llvm/IR/Function.h"
 #include "llvm/IR/GlobalVariable.h"
+#include "llvm/IR/IRPrintingPasses.h"
 #include "llvm/IR/InlineAsm.h"
 #include "llvm/IR/Instructions.h"
 #include "llvm/IR/LLVMContext.h"
 #include "llvm/IR/Module.h"
-#include "llvm/IR/PrintModulePass.h"
 #include "llvm/Pass.h"
 #include "llvm/Support/MathExtras.h"
 #include "llvm/Support/raw_ostream.h"