summaryrefslogtreecommitdiff
path: root/lib/Transforms/Utils
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2004-07-15 02:06:12 +0000
committerChris Lattner <sabre@nondot.org>2004-07-15 02:06:12 +0000
commit30b434476796cd4a85c02914687d22f2e5ec95ca (patch)
treeb2ddee2e918c75250f97590e6e58ca31786fb8b3 /lib/Transforms/Utils
parent2fc1230dd68e3f67d36b295adc5168733c412009 (diff)
downloadllvm-30b434476796cd4a85c02914687d22f2e5ec95ca.tar.gz
llvm-30b434476796cd4a85c02914687d22f2e5ec95ca.tar.bz2
llvm-30b434476796cd4a85c02914687d22f2e5ec95ca.tar.xz
Progress on PR341
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14840 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms/Utils')
-rw-r--r--lib/Transforms/Utils/CodeExtractor.cpp8
-rw-r--r--lib/Transforms/Utils/SimplifyCFG.cpp6
-rw-r--r--lib/Transforms/Utils/ValueMapper.cpp4
3 files changed, 9 insertions, 9 deletions
diff --git a/lib/Transforms/Utils/CodeExtractor.cpp b/lib/Transforms/Utils/CodeExtractor.cpp
index 8699e88578..67ec6415cd 100644
--- a/lib/Transforms/Utils/CodeExtractor.cpp
+++ b/lib/Transforms/Utils/CodeExtractor.cpp
@@ -262,23 +262,23 @@ Function *CodeExtractor::constructFunction(const Values &inputs,
for (Values::const_iterator i = inputs.begin(),
e = inputs.end(); i != e; ++i) {
const Value *value = *i;
- DEBUG(std::cerr << "value used in func: " << value << "\n");
+ DEBUG(std::cerr << "value used in func: " << *value << "\n");
paramTy.push_back(value->getType());
}
// Add the types of the output values to the function's argument list.
for (Values::const_iterator I = outputs.begin(), E = outputs.end();
I != E; ++I) {
- DEBUG(std::cerr << "instr used in func: " << *I << "\n");
+ DEBUG(std::cerr << "instr used in func: " << **I << "\n");
if (AggregateArgs)
paramTy.push_back((*I)->getType());
else
paramTy.push_back(PointerType::get((*I)->getType()));
}
- DEBUG(std::cerr << "Function type: " << RetTy << " f(");
+ DEBUG(std::cerr << "Function type: " << *RetTy << " f(");
DEBUG(for (std::vector<const Type*>::iterator i = paramTy.begin(),
- e = paramTy.end(); i != e; ++i) std::cerr << *i << ", ");
+ e = paramTy.end(); i != e; ++i) std::cerr << **i << ", ");
DEBUG(std::cerr << ")\n");
if (AggregateArgs && (inputs.size() + outputs.size() > 0)) {
diff --git a/lib/Transforms/Utils/SimplifyCFG.cpp b/lib/Transforms/Utils/SimplifyCFG.cpp
index 579812efa8..c3ed43d1f0 100644
--- a/lib/Transforms/Utils/SimplifyCFG.cpp
+++ b/lib/Transforms/Utils/SimplifyCFG.cpp
@@ -567,7 +567,7 @@ bool llvm::SimplifyCFG(BasicBlock *BB) {
// Remove basic blocks that have no predecessors... which are unreachable.
if (pred_begin(BB) == pred_end(BB) ||
*pred_begin(BB) == BB && ++pred_begin(BB) == pred_end(BB)) {
- DEBUG(std::cerr << "Removing BB: \n" << BB);
+ DEBUG(std::cerr << "Removing BB: \n" << *BB);
// Loop through all of our successors and make sure they know that one
// of their predecessors is going away.
@@ -615,7 +615,7 @@ bool llvm::SimplifyCFG(BasicBlock *BB) {
// we cannot do this transformation!
//
if (!PropagatePredecessorsForPHIs(BB, Succ)) {
- DEBUG(std::cerr << "Killing Trivial BB: \n" << BB);
+ DEBUG(std::cerr << "Killing Trivial BB: \n" << *BB);
std::string OldName = BB->getName();
std::vector<BasicBlock*>
@@ -921,7 +921,7 @@ bool llvm::SimplifyCFG(BasicBlock *BB) {
}
if (OnlySucc) {
- DEBUG(std::cerr << "Merging: " << BB << "into: " << OnlyPred);
+ DEBUG(std::cerr << "Merging: " << *BB << "into: " << *OnlyPred);
TerminatorInst *Term = OnlyPred->getTerminator();
// Resolve any PHI nodes at the start of the block. They are all
diff --git a/lib/Transforms/Utils/ValueMapper.cpp b/lib/Transforms/Utils/ValueMapper.cpp
index 16547e1337..7a5fcff111 100644
--- a/lib/Transforms/Utils/ValueMapper.cpp
+++ b/lib/Transforms/Utils/ValueMapper.cpp
@@ -112,8 +112,8 @@ void llvm::RemapInstruction(Instruction *I,
Value *V = MapValue(Op, ValueMap);
#ifndef NDEBUG
if (!V) {
- std::cerr << "Val = \n" << Op << "Addr = " << (void*)Op;
- std::cerr << "\nInst = " << I;
+ std::cerr << "Val = \n" << *Op << "Addr = " << (void*)Op;
+ std::cerr << "\nInst = " << *I;
}
#endif
assert(V && "Referenced value not in value map!");