[llvm] [SampleFDO] Stale profile call-graph matching (PR #95135)

Lei Wang via llvm-commits llvm-commits at lists.llvm.org
Mon Jun 17 16:28:25 PDT 2024


================
@@ -189,7 +238,9 @@ LocToLocMap SampleProfileMatcher::longestCommonSequence(
         X = V[Index(K - 1)] + 1;
       Y = X - K;
       while (X < Size1 && Y < Size2 &&
-             AnchorList1[X].second == AnchorList2[Y].second)
+             functionMatchesProfile(AnchorList1[X].second,
+                                    AnchorList2[Y].second,
+                                    !MatchUnusedFunction))
----------------
wlei-llvm wrote:

Comment added

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


More information about the llvm-commits mailing list