Skip to content

Commit a7795eb

Browse files
author
git apple-llvm automerger
committed
Merge commit 'c84cba124838' from apple/master into swift/master-next
2 parents 8a251fb + c84cba1 commit a7795eb

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

llvm/lib/Transforms/IPO/Inliner.cpp

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -662,10 +662,10 @@ inlineCallsImpl(CallGraphSCC &SCC, CallGraph &CG,
662662
// just become a regular analysis dependency.
663663
OptimizationRemarkEmitter ORE(Caller);
664664

665-
auto OIC = shouldInline(CB, GetInlineCost, ORE);
665+
auto InlDec = shouldInline(CB, GetInlineCost, ORE);
666666
// If the policy determines that we should inline this function,
667667
// delete the call instead.
668-
if (!OIC)
668+
if (!InlDec)
669669
continue;
670670

671671
// If this call site is dead and it is to a readonly function, we should
@@ -692,7 +692,7 @@ inlineCallsImpl(CallGraphSCC &SCC, CallGraph &CG,
692692
InsertLifetime, AARGetter, ImportedFunctionsStats);
693693
if (!IR.isSuccess()) {
694694
setInlineRemark(CB, std::string(IR.getFailureReason()) + "; " +
695-
inlineCostStr(OIC.getCost()));
695+
inlineCostStr(InlDec.getCost()));
696696
ORE.emit([&]() {
697697
return OptimizationRemarkMissed(DEBUG_TYPE, "NotInlined", DLoc,
698698
Block)
@@ -704,7 +704,7 @@ inlineCallsImpl(CallGraphSCC &SCC, CallGraph &CG,
704704
}
705705
++NumInlined;
706706

707-
emitInlinedInto(ORE, DLoc, Block, *Callee, *Caller, OIC.getCost());
707+
emitInlinedInto(ORE, DLoc, Block, *Callee, *Caller, InlDec.getCost());
708708

709709
// If inlining this function gave us any new call sites, throw them
710710
// onto our worklist to process. They are useful inline candidates.
@@ -1069,9 +1069,9 @@ PreservedAnalyses InlinerPass::run(LazyCallGraph::SCC &InitialC,
10691069
continue;
10701070
}
10711071

1072-
auto OIC = shouldInline(*CB, GetInlineCost, ORE);
1072+
auto InlDec = shouldInline(*CB, GetInlineCost, ORE);
10731073
// Check whether we want to inline this callsite.
1074-
if (!OIC)
1074+
if (!InlDec)
10751075
continue;
10761076

10771077
// Setup the data structure used to plumb customization into the
@@ -1090,7 +1090,7 @@ PreservedAnalyses InlinerPass::run(LazyCallGraph::SCC &InitialC,
10901090
InlineResult IR = InlineFunction(*CB, IFI);
10911091
if (!IR.isSuccess()) {
10921092
setInlineRemark(*CB, std::string(IR.getFailureReason()) + "; " +
1093-
inlineCostStr(OIC.getCost()));
1093+
inlineCostStr(InlDec.getCost()));
10941094
ORE.emit([&]() {
10951095
return OptimizationRemarkMissed(DEBUG_TYPE, "NotInlined", DLoc, Block)
10961096
<< NV("Callee", &Callee) << " will not be inlined into "
@@ -1104,7 +1104,7 @@ PreservedAnalyses InlinerPass::run(LazyCallGraph::SCC &InitialC,
11041104

11051105
++NumInlined;
11061106

1107-
emitInlinedInto(ORE, DLoc, Block, Callee, F, OIC.getCost());
1107+
emitInlinedInto(ORE, DLoc, Block, Callee, F, InlDec.getCost());
11081108

11091109
// Add any new callsites to defined functions to the worklist.
11101110
if (!IFI.InlinedCallSites.empty()) {

0 commit comments

Comments
 (0)