mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-10-10 16:24:04 +00:00
Fix some incorrect logic in DominanceFrontier::splitBlock. Part of
PR4238. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72223 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
c4c268b04f
commit
0f4012ca9d
@ -160,10 +160,7 @@ void DominanceFrontier::splitBlock(BasicBlock *NewBB) {
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!BlockDominatesAny)
|
|
||||||
continue;
|
|
||||||
|
|
||||||
// If NewBBSucc should not stay in our dominator frontier, remove it.
|
// If NewBBSucc should not stay in our dominator frontier, remove it.
|
||||||
// We remove it unless there is a predecessor of NewBBSucc that we
|
// We remove it unless there is a predecessor of NewBBSucc that we
|
||||||
// dominate, but we don't strictly dominate NewBBSucc.
|
// dominate, but we don't strictly dominate NewBBSucc.
|
||||||
@ -181,7 +178,8 @@ void DominanceFrontier::splitBlock(BasicBlock *NewBB) {
|
|||||||
|
|
||||||
if (ShouldRemove)
|
if (ShouldRemove)
|
||||||
removeFromFrontier(DFI, NewBBSucc);
|
removeFromFrontier(DFI, NewBBSucc);
|
||||||
addToFrontier(DFI, NewBB);
|
if (BlockDominatesAny && (&*FI == NewBB || !DT.dominates(FI, NewBB)))
|
||||||
|
addToFrontier(DFI, NewBB);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
; RUN: llvm-as < %s | opt -scalarrepl -loopsimplify -licm -disable-output
|
; RUN: llvm-as < %s | opt -scalarrepl -loopsimplify -licm -disable-output -verify-dom-info
|
||||||
|
|
||||||
define void @inflate() {
|
define void @inflate() {
|
||||||
entry:
|
entry:
|
||||||
|
Loading…
Reference in New Issue
Block a user