<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Feb 25, 2015 at 2:03 PM, Philip Reames <span dir="ltr"><<a href="mailto:listmail@philipreames.com" target="_blank">listmail@philipreames.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class=""><br>
On 02/25/2015 12:11 PM, Teresa Johnson wrote:<br>
</span><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">
On Wed, Feb 25, 2015 at 10:52 AM, Philip Reames<br>
<<a href="mailto:listmail@philipreames.com" target="_blank">listmail@philipreames.com</a>> wrote:<br>
</span><span class=""><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Other than the inliner, can you list the passes you think are profitable to<br>
teach about profiling data?  My list so far is: PRE (particularly of<br>
loads!), the vectorizer (i.e. duplicate work down both a hot and cold path<br>
when it can be vectorized on the hot path), LoopUnswitch, IRCE, & LoopUnroll<br>
(avoiding code size explosion in cold code).  I'm much more interested in<br>
sources of improved performance than I am simply code size reduction.<br>
(Reducing code size can improve performance of course.)<br>
</blockquote>
Also, code layout (bb layout, function layout, function splitting).<br>
</span></blockquote>
Correct me if I'm wrong, but we already have "function layout" (i.e. basic block placement).  It may need improved, but I've found it to be reasonable effective.<br>
<br>
What do you mean by "bb layout"?<br></blockquote><div><br></div><div>By bb layout I was referring to basic block placement - I am not overly familiar with LLVM's implementation, but I know that this typically benefits from profile information.</div><div><br></div><div>By function layout, I meant layout of functions within the module and then the executable. This could simply be marking/separating hot vs cold functions, or could be fancier via a linker plugin to use profile data to colocate functions with affinity.</div><div><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
I'm assuming you're referring to a form of outlining as "function splitting".  This seems like a clearly good idea.</blockquote><div><br></div><div>Right.</div><div><br></div><div>Thanks,</div><div>Teresa</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class=""><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Need to represent global profile summary data. For example, for global<br>
hotness determination, it is useful to compute additional global summary<br>
info, such as a histogram of counts that can be used to determine hotness<br>
and working set size estimates for a large percentage of the profiled<br>
execution.<br>
<br>
Er, not clear what you're trying to say here?<br>
</blockquote>
The idea is to get a sense of a good global profile count threshold to<br>
use given an application's profile, i.e. when determining whether a<br>
profile count is hot in the given profile. For example, what is the<br>
minimum profile count contributing to the hottest 99% of the<br>
application's profile.<br>
</blockquote></span>
Ah, got it.  That makes sense for a C/C++ use case.<br>
<br>
In my use case, we're only compiling the hottest methods.  As such, I care mostly about relative hotness within a method or a small set of methods.<br>
<br>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="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"> 408-460-2413</td></tr></tbody></table></span></div>
</div></div>