[PATCH] D132601: [llvm-profdata] Improve profile supplementation
Rong Xu via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Aug 25 11:19:11 PDT 2022
xur added a comment.
This patches adds the support for mapping to warm function, just following the existing practice (where it maps to hot functions).
The constant of -1 is already in llvm.
Since we are talking about hiding these values within InstrProfRecord, I would also change the way how the information pass to to down streams: instead of using entry counts,
For a function with InstrProfRecord value of -1, we would set the function attribute hot,
For a function with InstrProfRecord value of -2, we would remove function attribute cold if it has, otherwise do nothing.
For warm functions, we could also delete the function profile in the supplementation step. But it's less optimal:
(1) we will have a no-profile-found warning (it is not a big problem, as the default is off)
(2) we will not be able to fix the incorrect user annotation (where the user sets the function to cold).
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D132601/new/
https://reviews.llvm.org/D132601
More information about the llvm-commits
mailing list