Use StringRef instead of a string in FunctionSamplesMap's key type, because all usages of it are backed by the data of a sample profile, or sourced from a function name in the IR. It is necessary to change all usages of string into StringRef inside a SampleProfileMap to implement the 2nd phase of MD5 function name refactoring (by comparing MD5 values directly, instead of changing it to a string first)
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
This revision is now accepted and ready to land.Jun 7 2023, 9:53 AM
huangjd added a child revision: D150334: [llvm-profdata] Use string ref for FunctionSamplesMap.Jun 8 2023, 4:16 PM
huangjd removed a child revision: D150334: [llvm-profdata] Use string ref for FunctionSamplesMap.Jun 8 2023, 4:29 PM
huangjd added a child revision: D152490: [llvm-profdata] Use StringRef for CallTargetMap.Jun 13 2023, 6:24 PM