This patch improves llvm-profdata show command:
(1) add -value-cutoff=<N> option: only show function whose max count value is greater or equal to this cutoff value.
(2) add -list-below-cutoff option: output the functions whose max count value are below the cutoff value.
(3) format value-profile count values and print out the percentage.
Details
Details
Diff Detail
Diff Detail
- Repository
- rL LLVM
Event Timeline
Comment Actions
why is list-below-cutoff option useful?
Please also update the documentation for llvm-profdata with the new options.
Comment Actions
it can be used to list all the 0-count functions, like "-list-below-cutoff -value-cutoff=1 "
Please also update the documentation for llvm-profdata with the new options.
docs/CommandGuide/llvm-profdata.rst | ||
---|---|---|
226 ↗ | (On Diff #180538) | 'Only output names of functions whose .... ' |
tools/llvm-profdata/llvm-profdata.cpp | ||
675 ↗ | (On Diff #180538) | ListBelow --> OnlyListBelow |
703 ↗ | (On Diff #180538) | !TextFormat && ListBelow Text dump option is not compatible with ListBelow, and it should take precedence |
812 ↗ | (On Diff #180538) | Number of functions with maximum count (< " << ValueCutoff << "): " << .. |
813 ↗ | (On Diff #180538) | Functions -> functions |
922 ↗ | (On Diff #180538) | ListBelow --> OnlyListBelow |
924 ↗ | (On Diff #180538) | The semantics seems to be 'only list functions with ...' |
Comment Actions
lgtm
test/tools/llvm-profdata/value-prof.proftext | ||
---|---|---|
50 ↗ | (On Diff #180573) | Remove space here. |