forked from OSchip/llvm-project
0b6985a3c6
When the original binary is executed and sampled, the resulting profile contains information on the original inline stack. We currently follow the original inline plan if we notice that the inlined callsite has more than 0 samples to it. A better way is to determine whether the callsite is actually worth inlining. If the callsite accumulates a small fraction of the samples spent in the parent function, then we don't want to bother inlining it (as it means that the callsite is actually cold). This patch introduces a threshold expressed in percentage of samples in relation to the parent function. If the callsite uses less than N% of the total samples used by its parent, the original inline decision is not re-applied. I've set the threshold to the very arbitrary value of 5%. I'm yet to do any actual experiments to see what's a good value. I wanted to separate the basic mechanism from the tuning. llvm-svn: 254034 |
||
---|---|---|
.. | ||
Inputs | ||
branch.ll | ||
calls.ll | ||
cov-zero-samples.ll | ||
coverage-warning.ll | ||
discriminator.ll | ||
entry_counts.ll | ||
fnptr.ll | ||
gcc-simple.ll | ||
inline-coverage.ll | ||
inline.ll | ||
nolocinfo.ll | ||
offset.ll | ||
propagate.ll | ||
remarks.ll | ||
syntax.ll |