<div dir="ltr">Example. Assuming the cap is 'C'<div><br></div><div>void bar()</div><div>{</div><div>    // ENTRY count is 4*C, after capping it becomes 'C'</div><div>    ...</div><div>}</div><div><br></div><div>void test()</div><div>{</div><div>  // BB1:   count(BB1) = C</div><div>  bar();</div><div><br></div><div><div>  // BB2:   count(BB2) = C</div><div>  bar();</div></div><div><br></div><div>}</div><div><br></div><div><div>void test2()</div><div>{</div><div>  // BB3:   count(BB3) = C</div><div>  bar();</div><div><br></div><div><div>  // BB4:   count(BB4) = C</div><div>  bar();</div></div><div>}</div></div><div><br></div><div>What would inliner see here ? When it sees callsite1 -- it might mistaken that is the only dominating callsite to 'bar'.</div><div><br></div><div>David</div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Mar 24, 2015 at 12:57 PM, Chandler Carruth <span dir="ltr"><<a href="mailto:chandlerc@google.com" target="_blank">chandlerc@google.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><span class=""><br><div class="gmail_quote">On Tue, Mar 24, 2015 at 12:53 PM, Xinliang David Li <span dir="ltr"><<a href="mailto:xinliangli@gmail.com" target="_blank">xinliangli@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Capping also leads to other kinds of problems -- e.g., sum of incoming edge count (callgraph) does not match the callee entry count etc.</blockquote></div><br></span>Can you explain these problems in more detail? I think that's essential for understanding why you think the design should be work in this way.</div></div>
</blockquote></div><br></div>