Skip to content

Commit 273e463

Browse files
[memprof] Improve a comment (NFC) (#142002)
We can go one step further than "compare" and mention "prefix" to succinctly describe the function.
1 parent 8e19573 commit 273e463

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

llvm/lib/Transforms/Instrumentation/MemProfiler.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -762,9 +762,9 @@ static AllocationType addCallStack(CallStackTrie &AllocTrie,
762762
return AllocType;
763763
}
764764

765-
// Helper to compare the InlinedCallStack computed from an instruction's debug
766-
// info to a list of Frames from profile data (either the allocation data or a
767-
// callsite).
765+
// Return true if InlinedCallStack, computed from a call instruction's debug
766+
// info, is a prefix of ProfileCallStack, a list of Frames from profile data
767+
// (either the allocation data or a callsite).
768768
static bool
769769
stackFrameIncludesInlinedCallStack(ArrayRef<Frame> ProfileCallStack,
770770
ArrayRef<uint64_t> InlinedCallStack) {

0 commit comments

Comments
 (0)