<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">2016-09-02 15:11 GMT-07:00 Teresa Johnson <span dir="ltr"><<a href="mailto:tejohnson@google.com" target="_blank">tejohnson@google.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote"><span class="">On Fri, Sep 2, 2016 at 2:58 PM, Piotr Padlewski <span dir="ltr"><<a href="mailto:piotr.padlewski@gmail.com" target="_blank">piotr.padlewski@gmail.com</a>></span> wrote:<br></span><span class=""><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi,<div>I am working right now on importing based on PGO/FDO data. There is one issue that I found - when we calculate the list of imports, we can't get the ProfileSummaryInfo, which is the best and I </div><div>think only valid way of checking if callsite/callee is hot (isHotCount()). There are 2 solutions that I come up with Teresa and Easwaran:</div><div><br></div><div>1. Add PGO data to summary </div></div></blockquote><div><br></div></span><div>How much PGO data would need to be copied to summary? </div></div></div></div></blockquote><div><br></div><div>AFAI got information form Easwaran - not much, about 3*15 integers. </div><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"><div class="gmail_quote"><span class=""><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>2. Replace CalleeInfo::ProfileCount with enum {None, Cold, Hot} computed during computing summary.</div></div></blockquote><div><br></div></span><div>It depends on how binary the inlining decisions that (will) use this are - do we want to give different thresholds to medium hot/cold vs very hot/cold?</div></div></div></div></blockquote><div><br></div><div>We could also just later add MediumHot, MediumCold to the enum. But I am not sure if we want to have that specific information. We can always mark medium hot </div><div>as hot, and then maybe import more stuff, which should not be that harrmful.</div><div><br></div><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"><div class="gmail_quote"><span class=""><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><br></div><div>I like the 2. much more. It will reduce the summary size slightly and I don't think we will need ProfileCount anywhere else.</div><div><br></div><div>The other thing I would like to mention is that I think we should start using the summary versioning and drop support of old version. </div><div>ThinLTO doesn't have enough users right now and parsing many versions of summary will just add additional cost, that will start to grow.</div></div></blockquote><div><br></div></span><div>It was released in 3.9 and in Xcode so it has external users and I believe will need to support old versions going forward.</div></div></div></div></blockquote><div><br></div><div>Is this really needed? I think it is important to be able to distinguish between versions, so combining old summary with new one won't lead to some</div><div>weird behaviour and user will get an error. The user will maybe have to recompile whole project, but on the other hand we won't spend</div><div>time on trying to figure out support for all the versions.</div><div><br></div><div> </div><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"><div class="gmail_quote"><div><br></div><div>Teresa</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><span><font color="#888888"><div><br></div><div>Piotr</div></font></span></div><span class="HOEnZb"><font color="#888888">
</font></span></blockquote></div><span class="HOEnZb"><font color="#888888"><br><br clear="all"><div><br></div>-- <br><div data-smartmail="gmail_signature"><span style="font-family:Times;font-size:medium"><table cellspacing="0" cellpadding="0"><tbody><tr style="color:rgb(85,85,85);font-family:sans-serif;font-size:small"><td nowrap style="border-top-style:solid;border-top-color:rgb(213,15,37);border-top-width:2px">Teresa Johnson |</td><td nowrap style="border-top-style:solid;border-top-color:rgb(51,105,232);border-top-width:2px"> Software Engineer |</td><td nowrap style="border-top-style:solid;border-top-color:rgb(0,153,57);border-top-width:2px"> <a href="mailto:tejohnson@google.com" target="_blank">tejohnson@google.com</a> |</td><td nowrap style="border-top-style:solid;border-top-color:rgb(238,178,17);border-top-width:2px"> <a href="tel:408-460-2413" value="+14084602413" target="_blank">408-460-2413</a></td></tr></tbody></table></span></div>
</font></span></div></div>
</blockquote></div><br></div></div>