diff options
author | Chris Lattner <sabre@nondot.org> | 2009-08-23 04:37:46 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2009-08-23 04:37:46 +0000 |
commit | bdff548e4dd577a72094d57b282de4e765643b96 (patch) | |
tree | 71c6617214b134968352b854c8f82ce8c89e1282 /lib/Linker/LinkModules.cpp | |
parent | 405ce8db96f7a3a5a4c3da0f71d2ca54d30316f0 (diff) | |
download | external_llvm-bdff548e4dd577a72094d57b282de4e765643b96.zip external_llvm-bdff548e4dd577a72094d57b282de4e765643b96.tar.gz external_llvm-bdff548e4dd577a72094d57b282de4e765643b96.tar.bz2 |
eliminate the "Value" printing methods that print to a std::ostream.
This required converting a bunch of stuff off DOUT and other cleanups.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@79819 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Linker/LinkModules.cpp')
-rw-r--r-- | lib/Linker/LinkModules.cpp | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/lib/Linker/LinkModules.cpp b/lib/Linker/LinkModules.cpp index ca0bf73..effba47 100644 --- a/lib/Linker/LinkModules.cpp +++ b/lib/Linker/LinkModules.cpp @@ -25,7 +25,6 @@ #include "llvm/ValueSymbolTable.h" #include "llvm/Instructions.h" #include "llvm/Assembly/Writer.h" -#include "llvm/Support/Streams.h" #include "llvm/Support/ErrorHandling.h" #include "llvm/System/Path.h" #include "llvm/ADT/DenseMap.h" @@ -145,7 +144,7 @@ protected: // for debugging... virtual void dump() const { - cerr << "AbstractTypeSet!\n"; + errs() << "AbstractTypeSet!\n"; } }; } @@ -338,11 +337,11 @@ static bool LinkTypes(Module *Dest, const Module *Src, std::string *Err) { static void PrintMap(const std::map<const Value*, Value*> &M) { for (std::map<const Value*, Value*>::const_iterator I = M.begin(), E =M.end(); I != E; ++I) { - cerr << " Fr: " << (void*)I->first << " "; + errs() << " Fr: " << (void*)I->first << " "; I->first->dump(); - cerr << " To: " << (void*)I->second << " "; + errs() << " To: " << (void*)I->second << " "; I->second->dump(); - cerr << "\n"; + errs() << "\n"; } } #endif @@ -414,10 +413,10 @@ static Value *RemapOperand(const Value *In, } #ifndef NDEBUG - cerr << "LinkModules ValueMap: \n"; + errs() << "LinkModules ValueMap: \n"; PrintMap(ValueMap); - cerr << "Couldn't remap value: " << (void*)In << " " << *In << "\n"; + errs() << "Couldn't remap value: " << (void*)In << " " << *In << "\n"; llvm_unreachable("Couldn't remap value!"); #endif return 0; @@ -1280,10 +1279,10 @@ Linker::LinkModules(Module *Dest, Module *Src, std::string *ErrorMsg) { if (!Src->getDataLayout().empty() && !Dest->getDataLayout().empty() && Src->getDataLayout() != Dest->getDataLayout()) - cerr << "WARNING: Linking two modules of different data layouts!\n"; + errs() << "WARNING: Linking two modules of different data layouts!\n"; if (!Src->getTargetTriple().empty() && Dest->getTargetTriple() != Src->getTargetTriple()) - cerr << "WARNING: Linking two modules of different target triples!\n"; + errs() << "WARNING: Linking two modules of different target triples!\n"; // Append the module inline asm string. if (!Src->getModuleInlineAsm().empty()) { |