summaryrefslogtreecommitdiff
path: root/lib/Analysis/PostDominators.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2009-08-23 05:17:37 +0000
committerChris Lattner <sabre@nondot.org>2009-08-23 05:17:37 +0000
commit791102fb1192ac9483274e54cbc42480c9b1af10 (patch)
tree4729b1da9b9c946fb83bc177dd3d00bffcf85390 /lib/Analysis/PostDominators.cpp
parent79c5d3f9717756dc3ff56cfcaa3ae1a5930c457a (diff)
downloadllvm-791102fb1192ac9483274e54cbc42480c9b1af10.tar.gz
llvm-791102fb1192ac9483274e54cbc42480c9b1af10.tar.bz2
llvm-791102fb1192ac9483274e54cbc42480c9b1af10.tar.xz
eliminate the std::ostream form of WriteAsOperand and update clients.
This also updates dominator related stuff. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@79825 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Analysis/PostDominators.cpp')
-rw-r--r--lib/Analysis/PostDominators.cpp11
1 files changed, 8 insertions, 3 deletions
diff --git a/lib/Analysis/PostDominators.cpp b/lib/Analysis/PostDominators.cpp
index 4853c2ac87..69522e8a39 100644
--- a/lib/Analysis/PostDominators.cpp
+++ b/lib/Analysis/PostDominators.cpp
@@ -33,15 +33,20 @@ F("postdomtree", "Post-Dominator Tree Construction", true, true);
bool PostDominatorTree::runOnFunction(Function &F) {
DT->recalculate(F);
- DEBUG(DT->dump());
+ DEBUG(DT->print(errs()));
return false;
}
-PostDominatorTree::~PostDominatorTree()
-{
+PostDominatorTree::~PostDominatorTree() {
delete DT;
}
+void PostDominatorTree::print(std::ostream &OS, const Module *) const {
+ raw_os_ostream OSS(OS);
+ DT->print(OSS);
+}
+
+
FunctionPass* llvm::createPostDomTree() {
return new PostDominatorTree();
}