[llvm] [MemProf] Print full context hash when reporting hinted bytes (PR #114465)
Teresa Johnson via llvm-commits
llvm-commits at lists.llvm.org
Thu Nov 7 11:33:29 PST 2024
================
@@ -256,11 +291,14 @@ bool CallStackTrie::buildAndAttachMIBMetadata(CallBase *CI) {
if (hasSingleAllocType(Alloc->AllocTypes)) {
addAllocTypeAttribute(Ctx, CI, (AllocationType)Alloc->AllocTypes);
if (MemProfReportHintedSizes) {
- assert(Alloc->TotalSize);
- errs() << "Total size for allocation with location hash " << AllocStackId
- << " and single alloc type "
- << getAllocTypeAttributeString((AllocationType)Alloc->AllocTypes)
- << ": " << Alloc->TotalSize << "\n";
+ std::vector<ContextTotalSize> ContextSizeInfo;
+ collectContextSizeInfo(Alloc, ContextSizeInfo);
+ for (const auto &Info : ContextSizeInfo) {
+ errs() << "Total size for full allocation context hash "
----------------
teresajohnson wrote:
done
https://github.com/llvm/llvm-project/pull/114465
More information about the llvm-commits
mailing list