Skip to content

Commit 5639cfa

Browse files
committed
Add comment
1 parent 49aaca2 commit 5639cfa

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

llvm/lib/Transforms/IPO/MemProfContextDisambiguation.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5579,6 +5579,12 @@ void MemProfContextDisambiguation::performICP(
55795579
.getCallee());
55805580
}
55815581
DirectCall.setCalledFunction(TargetToUse);
5582+
// During matching we generate synthetic VP metadata for indirect calls
5583+
// not already having any, from the memprof profile's callee GUIDs. If
5584+
// we subsequently promote and inline those callees, we currently lose
5585+
// the ability to generate this synthetic VP metadata. Optionally apply
5586+
// a noinline attribute to promoted direct calls, where the threshold is
5587+
// set to capture synthetic VP metadata targets which get a count of 1.
55825588
if (MemProfICPNoInlineThreshold &&
55835589
Candidate.Count < MemProfICPNoInlineThreshold)
55845590
DirectCall.setIsNoInline();

0 commit comments

Comments
 (0)