diff options
author | Chandler Carruth <chandlerc@gmail.com> | 2014-01-12 11:30:46 +0000 |
---|---|---|
committer | Chandler Carruth <chandlerc@gmail.com> | 2014-01-12 11:30:46 +0000 |
commit | 9d805139bdf016787c4d66619b17a2fff2c5392c (patch) | |
tree | 22e3dadb68961cff98013382789a4c3549d797a8 /llvm/lib/IR/LegacyPassManager.cpp | |
parent | 3dd261d0c94d949b75e82cd581a0b5cd50aee9b6 (diff) | |
download | llvm-9d805139bdf016787c4d66619b17a2fff2c5392c.zip llvm-9d805139bdf016787c4d66619b17a2fff2c5392c.tar.gz llvm-9d805139bdf016787c4d66619b17a2fff2c5392c.tar.bz2 |
[PM] Simplify the interface exposed for IR printing passes.
Nothing was using the ability of the pass to delete the raw_ostream it
printed to, and nothing was trying to pass it a pointer to the
raw_ostream. Also, the function variant had a different order of
arguments from all of the others which was just really confusing. Now
the interface accepts a reference, doesn't offer to delete it, and uses
a consistent order. The implementation of the printing passes haven't
been updated with this simplification, this is just the API switch.
llvm-svn: 199044
Diffstat (limited to 'llvm/lib/IR/LegacyPassManager.cpp')
-rw-r--r-- | llvm/lib/IR/LegacyPassManager.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/llvm/lib/IR/LegacyPassManager.cpp b/llvm/lib/IR/LegacyPassManager.cpp index ae94f05..f9fca32 100644 --- a/llvm/lib/IR/LegacyPassManager.cpp +++ b/llvm/lib/IR/LegacyPassManager.cpp @@ -235,7 +235,7 @@ public: /// createPrinterPass - Get a function printer pass. Pass *createPrinterPass(raw_ostream &O, const std::string &Banner) const { - return createPrintFunctionPass(Banner, &O); + return createPrintFunctionPass(O, Banner); } // Prepare for running an on the fly pass, freeing memory if needed @@ -304,7 +304,7 @@ public: /// createPrinterPass - Get a module printer pass. Pass *createPrinterPass(raw_ostream &O, const std::string &Banner) const { - return createPrintModulePass(&O, false, Banner); + return createPrintModulePass(O, Banner); } /// run - Execute all of the passes scheduled for execution. Keep track of @@ -404,7 +404,7 @@ public: /// createPrinterPass - Get a module printer pass. Pass *createPrinterPass(raw_ostream &O, const std::string &Banner) const { - return createPrintModulePass(&O, false, Banner); + return createPrintModulePass(O, Banner); } /// run - Execute all of the passes scheduled for execution. Keep track of |