[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
================
@@ -4404,6 +4410,24 @@ void ModuleBitcodeWriterBase::writePerModuleGlobalValueSummary() {
Stream.EmitRecord(bitc::FS_STACK_IDS, Index->stackIds(), StackIdAbbvId);
}
+ SmallVector<uint64_t, 64> NameVals;
+ if (!Index->contextSizeInfos().empty()) {
+ auto ContextSizeInfoAbbv = std::make_shared<BitCodeAbbrev>();
+ ContextSizeInfoAbbv->Add(BitCodeAbbrevOp(bitc::FS_CONTEXT_SIZE_INFOS));
+ // numids x (fullStackid, totalsize)
+ ContextSizeInfoAbbv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::Array));
+ ContextSizeInfoAbbv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::VBR, 8));
+ unsigned ContextSizeInfoAbbvId =
+ Stream.EmitAbbrev(std::move(ContextSizeInfoAbbv));
+ for (const auto &Info : Index->contextSizeInfos()) {
----------------
teresajohnson wrote:
done
https://github.com/llvm/llvm-project/pull/114465
More information about the llvm-commits
mailing list