[LLVMdev] RFC - Improvements to PGO profile support
Chandler Carruth
chandlerc at google.com
Tue Mar 24 13:13:41 PDT 2015
On Tue, Mar 24, 2015 at 1:08 PM, Xinliang David Li <xinliangli at gmail.com>
wrote:
> Example. Assuming the cap is 'C'
>
> void bar()
> {
> // ENTRY count is 4*C, after capping it becomes 'C'
> ...
> }
>
> void test()
> {
> // BB1: count(BB1) = C
> bar();
>
> // BB2: count(BB2) = C
> bar();
>
> }
>
> void test2()
> {
> // BB3: count(BB3) = C
> bar();
>
> // BB4: count(BB4) = C
> bar();
> }
>
> What would inliner see here ? When it sees callsite1 -- it might mistaken
> that is the only dominating callsite to 'bar'.
>
I don't understand, why would it assume this?
I was suggesting that each function would need to be associated with some
global weight, and the global weight ration between test and bar should
provide the needed information here?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20150324/bdfb253e/attachment.html>
More information about the llvm-dev
mailing list