forked from OSchip/llvm-project
[LV] Rename Region to TargetRegion, similar to SinkRegion (NFC).
Adjust the name to make it clearer this is the region containing the
target recipe, similar to SinkRegion below.
Suggested post-commit for ccebf7a109
.
This commit is contained in:
parent
01c78a0b07
commit
01c26d4e04
|
@ -9118,12 +9118,13 @@ VPlanPtr LoopVectorizationPlanner::buildVPlanWithVPRecipes(
|
|||
|
||||
// If the target is in a replication region, make sure to move Sink to the
|
||||
// block after it, not into the replication region itself.
|
||||
if (auto *Region =
|
||||
if (auto *TargetRegion =
|
||||
dyn_cast_or_null<VPRegionBlock>(Target->getParent()->getParent())) {
|
||||
if (Region->isReplicator()) {
|
||||
assert(Region->getNumSuccessors() == 1 && "Expected SESE region!");
|
||||
if (TargetRegion->isReplicator()) {
|
||||
assert(TargetRegion->getNumSuccessors() == 1 &&
|
||||
"Expected SESE region!");
|
||||
VPBasicBlock *NextBlock =
|
||||
cast<VPBasicBlock>(Region->getSuccessors().front());
|
||||
cast<VPBasicBlock>(TargetRegion->getSuccessors().front());
|
||||
Sink->moveBefore(*NextBlock, NextBlock->getFirstNonPhi());
|
||||
continue;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue