From c34d1123622ca99efffc8ae4fdb194ae4f1a66bc Mon Sep 17 00:00:00 2001 From: Owen Anderson Date: Mon, 15 Dec 2008 03:52:17 +0000 Subject: [PATCH] Ifdef out some code that I didn't mean to enable by default yet. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61024 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Transforms/Scalar/GVN.cpp | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/lib/Transforms/Scalar/GVN.cpp b/lib/Transforms/Scalar/GVN.cpp index d3e15d457a4..36624249238 100644 --- a/lib/Transforms/Scalar/GVN.cpp +++ b/lib/Transforms/Scalar/GVN.cpp @@ -1611,11 +1611,18 @@ bool GVN::iterateOnFunction(Function &F) { // Top-down walk of the dominator tree bool changed = false; +#if 0 + // Needed for value numbering with phi construction to work. ReversePostOrderTraversal RPOT(&F); for (ReversePostOrderTraversal::rpo_iterator RI = RPOT.begin(), RE = RPOT.end(); RI != RE; ++RI) changed |= processBlock(*RI); - +#else + for (df_iterator DI = df_begin(DT->getRootNode()), + DE = df_end(DT->getRootNode()); DI != DE; ++DI) + changed |= processBlock(DI->getBlock()); +#endif + return changed; } -- 2.34.1