[llvm] [llvm-profgen] Filter out ambiguous cold profiles during profile generation (PR #81803)

Lei Wang via llvm-commits llvm-commits at lists.llvm.org
Wed Feb 14 17:31:49 PST 2024


================
@@ -975,6 +975,8 @@ class FunctionSamples {
     return CallsiteSamples;
   }
 
+  CallsiteSampleMap &getCallsiteSamples() { return CallsiteSamples; }
----------------
wlei-llvm wrote:

OK, I just checked the profile matching, so we only check against `FSFlattened` (not FS) https://github.com/llvm/llvm-project/blob/main/llvm/lib/Transforms/IPO/SampleProfile.cpp#L2433
The reason is that there could be function that all the call are inlined, so there is no top-level version, but it's still can be checksum mismatched, we should make it possible to run stale matching for those functions.

Given this, we probably needs the filtering for inlined samples.

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


More information about the llvm-commits mailing list