mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
SILCloner: rename 'remapValue' to 'getMappedValue' to avoid confusion.
A follow up commit adds an API for SILCloner clients to set mapped values. Calling the map lookup "remap" would be unacceptably misleading.
This commit is contained in:
@@ -1579,7 +1579,7 @@ protected:
|
||||
}
|
||||
}
|
||||
|
||||
SILValue remapValue(SILValue V) {
|
||||
SILValue getMappedValue(SILValue V) {
|
||||
if (auto *BB = V->getParentBlock()) {
|
||||
if (!DomTree.dominates(StartBB, BB)) {
|
||||
// Must be a value that dominates the start basic block.
|
||||
@@ -1588,7 +1588,7 @@ protected:
|
||||
return V;
|
||||
}
|
||||
}
|
||||
return SILCloner<RegionCloner>::remapValue(V);
|
||||
return SILCloner<RegionCloner>::getMappedValue(V);
|
||||
}
|
||||
|
||||
void postProcess(SILInstruction *Orig, SILInstruction *Cloned) {
|
||||
@@ -1610,7 +1610,7 @@ protected:
|
||||
// Update SSA form.
|
||||
SSAUp.Initialize(V->getType());
|
||||
SSAUp.AddAvailableValue(OrigBB, V);
|
||||
SILValue NewVal = remapValue(V);
|
||||
SILValue NewVal = getMappedValue(V);
|
||||
SSAUp.AddAvailableValue(getOpBasicBlock(OrigBB), NewVal);
|
||||
for (auto U : UseList) {
|
||||
Operand *Use = U;
|
||||
|
||||
Reference in New Issue
Block a user