[llvm] [MemProf] Ensure all callsite clones are assigned a function clone (PR #150735)

Teresa Johnson via llvm-commits llvm-commits at lists.llvm.org
Sun Jul 27 10:19:44 PDT 2025


================
@@ -3995,7 +4024,19 @@ void IndexCallsiteContextGraph::updateCall(CallInfo &CallerCall,
   assert(CI &&
          "Caller cannot be an allocation which should not have profiled calls");
   assert(CI->Clones.size() > CallerCall.cloneNo());
-  CI->Clones[CallerCall.cloneNo()] = CalleeFunc.cloneNo();
+  auto NewCalleeCloneNo = CalleeFunc.cloneNo();
+  auto CurCalleeCloneNo = CI->Clones[CallerCall.cloneNo()];
----------------
teresajohnson wrote:

Although I can take a reference to the vector entry and assign into that. Will do that...

https://github.com/llvm/llvm-project/pull/150735


More information about the llvm-commits mailing list