<html>
  <head>
    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <br>
    <div class="moz-cite-prefix">On 01/12/2015 07:39 PM, Xinliang David
      Li wrote:<br>
    </div>
    <blockquote
cite="mid:CALRgJCMnq4TzL3j1ggAG4d1ideozP2nHtboE4xjOoShS22eb2g@mail.gmail.com"
      type="cite">
      <div dir="ltr"><br>
        <div class="gmail_extra"><br>
          <div class="gmail_quote">On Wed, Jan 7, 2015 at 5:33 PM,
            Chandler Carruth <span dir="ltr"><<a
                moz-do-not-send="true"
                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"><br>
                  <div class="gmail_quote"><br>
                    <div>How does this compare with classical approaches
                      of loop peeling, partitioning, fission, or
                      whatever you might call it? Is there any
                      literature behind this approach or some literature
                      it should be compared with? (I genuinely don't
                      know this area that well, so I'm of little help
                      here...)</div>
                  </div>
                </div>
              </div>
            </blockquote>
            <div><br>
            </div>
            <div><br>
            </div>
            <div>It is not any of those loop transformations. It does
              not even change the control flow. It is more a code layout
              optimization -- move the cold trace in the loop out of the
              body.</div>
          </div>
        </div>
      </div>
    </blockquote>
    It's also a somewhat major change in the canonical form of the loop
    as seen by the optimizer.  That's probably the more important part
    in practice.  <br>
    <blockquote
cite="mid:CALRgJCMnq4TzL3j1ggAG4d1ideozP2nHtboE4xjOoShS22eb2g@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div class="gmail_extra">
          <div class="gmail_quote">
            <div> <br>
            </div>
            <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">
                  <div class="gmail_quote"><span class="">
                      <blockquote class="gmail_quote" style="margin:0 0
                        0 .8ex;border-left:1px #ccc
                        solid;padding-left:1ex">
                        <div bgcolor="#FFFFFF" text="#000000">
                          <div>
                            <div>
                              <ul>
                                <li>If so, is the notion of 'rareness'
                                  of a loop block something that's worth
                                  extracting out on it's own and
                                  reusing? Are there other similar uses
                                  anyone can think of?</li>
                                <li>Currently, I'm only supporting a
                                  fairly small set of controlling
                                  conditions. Are there important cases
                                  I'm not considering?</li>
                              </ul>
                            </div>
                          </div>
                        </div>
                      </blockquote>
                    </span>
                    <div>To both of these, I think the general
                      combination to use is to identify the set of
                      blocks dominated by a block which is in the loop
                      body of a hot loop, and is cold relative to the
                      other successors of its predecessor(s). These form
                      cold "regions" as I think of them without
                      requiring the complexity of the region analysis.</div>
                    <span class="">
                      <div> </div>
                    </span></div>
                </div>
              </div>
            </blockquote>
            <div><br>
            </div>
            <div>Static prediction should handle it  --  call heuristics
              or some combination with other heuristics (error handler
              recognition etc).</div>
            <div><br>
            </div>
          </div>
        </div>
      </div>
    </blockquote>
    Sorry, I'm really not sure what you're trying to say here.  Could
    you clarify/expand?  <br>
  </body>
</html>