Skip to content

Commit 8046906

Browse files
authored
Merge pull request #18008 from gottesmm/pr-222ed1a4f13c22ece8a00e8ca5724ceaab5adb46
2 parents 1609523 + fe97efc commit 8046906

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

include/swift/SILOptimizer/PassManager/PassManager.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ class SILPassManager {
203203
}
204204

205205
/// \brief Iterate over all analysis and notify them of a deleted function.
206-
void notifyDeleteFunction(SILFunction *F) {
206+
void notifyWillDeleteFunction(SILFunction *F) {
207207
// Invalidate the analysis (unless they are locked)
208208
for (auto AP : Analyses)
209209
if (!AP->isLocked())

include/swift/SILOptimizer/PassManager/Transforms.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -164,9 +164,9 @@ namespace swift {
164164
PM->invalidateFunctionTables();
165165
}
166166

167-
/// Inform the pass manager of a deleted function.
168-
void notifyDeleteFunction(SILFunction *F) {
169-
PM->notifyDeleteFunction(F);
167+
/// Inform the pass manager that we are going to delete a function.
168+
void notifyWillDeleteFunction(SILFunction *F) {
169+
PM->notifyWillDeleteFunction(F);
170170
}
171171

172172
/// Inform the pass manager of an added function.

lib/SILOptimizer/IPO/DeadFunctionElimination.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -702,7 +702,7 @@ class DeadFunctionElimination : FunctionLivenessComputation {
702702

703703
DEBUG(llvm::dbgs() << " erase dead function " << F->getName() << "\n");
704704
NumDeadFunc++;
705-
DFEPass->notifyDeleteFunction(F);
705+
DFEPass->notifyWillDeleteFunction(F);
706706
Module->eraseFunction(F);
707707
}
708708
if (changedTables)

lib/SILOptimizer/Mandatory/MandatoryInlining.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -673,7 +673,7 @@ class MandatoryInlining : public SILModuleTransform {
673673
if (F.getRepresentation() == SILFunctionTypeRepresentation::ObjCMethod)
674674
continue;
675675

676-
notifyDeleteFunction(&F);
676+
notifyWillDeleteFunction(&F);
677677

678678
// Okay, just erase the function from the module.
679679
M->eraseFunction(&F);

0 commit comments

Comments
 (0)