projects
/
oota-llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a34d395
)
Insert cloned loop basic blocks before original loop header.
author
Devang Patel
<dpatel@apple.com>
Tue, 4 Sep 2007 20:46:35 +0000
(20:46 +0000)
committer
Devang Patel
<dpatel@apple.com>
Tue, 4 Sep 2007 20:46:35 +0000
(20:46 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41713
91177308
-0d34-0410-b5e6-
96231b3b80d8
lib/Transforms/Utils/CloneLoop.cpp
patch
|
blob
|
history
diff --git
a/lib/Transforms/Utils/CloneLoop.cpp
b/lib/Transforms/Utils/CloneLoop.cpp
index 6e35916c89a4770590b0a835ae7130655095c249..61d25f2dfae56da00089edc59889e9ecbeaf7dc7 100644
(file)
--- a/
lib/Transforms/Utils/CloneLoop.cpp
+++ b/
lib/Transforms/Utils/CloneLoop.cpp
@@
-145,7
+145,9
@@
Loop *llvm::CloneLoop(Loop *OrigL, LPPassManager *LPM, LoopInfo *LI,
BasicBlock *Latch = OrigL->getLoopLatch();
Function *F = Latch->getParent();
- F->getBasicBlockList().insert(Latch, NewBlocks.begin(), NewBlocks.end());
+ F->getBasicBlockList().insert(OrigL->getHeader(),
+ NewBlocks.begin(), NewBlocks.end());
+
return NewParentLoop;
}