diff options
author | Chris Lattner <sabre@nondot.org> | 2003-06-24 19:48:06 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2003-06-24 19:48:06 +0000 |
commit | f7544873def024bcba8045e008e64e3147dfbdea (patch) | |
tree | d2af03d2b8a14dffbebda7797ef5fc342be67395 | |
parent | 17b4e96e7e5cd4edbab28d0c00126cc8cafb3b99 (diff) | |
download | bcm5719-llvm-f7544873def024bcba8045e008e64e3147dfbdea.tar.gz bcm5719-llvm-f7544873def024bcba8045e008e64e3147dfbdea.zip |
Fix bug: TailDup/2003-06-24-Simpleloop.ll
llvm-svn: 6881
-rw-r--r-- | llvm/lib/Transforms/Scalar/TailDuplication.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/lib/Transforms/Scalar/TailDuplication.cpp b/llvm/lib/Transforms/Scalar/TailDuplication.cpp index e736f970af5..04736f07e14 100644 --- a/llvm/lib/Transforms/Scalar/TailDuplication.cpp +++ b/llvm/lib/Transforms/Scalar/TailDuplication.cpp @@ -203,7 +203,8 @@ void TailDup::InsertPHINodesIfNecessary(Instruction *OrigInst, Value *NewInst, for (Value::use_iterator I = OrigInst->use_begin(), E = OrigInst->use_end(); I != E; ++I) { Instruction *In = cast<Instruction>(*I); - if (In->getParent() != OrigBlock) // Don't modify uses in the orig block! + if (In->getParent() != OrigBlock || // Don't modify uses in the orig block! + isa<PHINode>(In)) Users.push_back(In); } |