<html>
  <head>
    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <p><br>
    </p>
    <div class="moz-cite-prefix">On 12/21/2016 03:36 PM, Sanjay Patel
      via llvm-dev wrote:<br>
    </div>
    <blockquote
cite="mid:CA+wODiuPt4KSNXZ-6Go8y8QLNti+irhFYf7ySdVbKLH1DO+OeA@mail.gmail.com"
      type="cite">
      <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
      <div>I would have replied to this thread sooner, but I was busy
        adding more instcombines. :)</div>
      <div><br>
      </div>
      <div>The motivation for r289855 is in the commit msg (I'm out of
        the office and can't look things up conveniently). Feel free to
        revert that and the follow ups, however, if that patch caused a
        noticeable slowdown, then it suggests we have a bigger
        problem?...that's a simple matcher (no value tracking required).</div>
    </blockquote>
    <br>
    I'd recommend against reverting this until we understand more about
    the problem. This is not a critical compile-time regression, and we
    don't yet know the cause (it might just be enabling more down-stream
    transformations), or whether there have been any corresponding
    benefits to code side, performance, etc. It definitely looks like a
    pattern that we should catch.<br>
    <br>
     -Hal<br>
    <br>
    <blockquote
cite="mid:CA+wODiuPt4KSNXZ-6Go8y8QLNti+irhFYf7ySdVbKLH1DO+OeA@mail.gmail.com"
      type="cite">
      <div><br>
        <div class="gmail_quote">
          <div>On Wed, Dec 21, 2016 at 12:12 PM Sean Silva <<a
              moz-do-not-send="true" href="mailto:chisophugis@gmail.com">chisophugis@gmail.com</a>>
            wrote:<br>
          </div>
          <blockquote class="gmail_quote" style="margin:0 0 0
            .8ex;border-left:1px #ccc solid;padding-left:1ex">
            <div class="gmail_msg">
              <div class="gmail_extra gmail_msg">
                <div class="gmail_quote gmail_msg">On Wed, Dec 21, 2016
                  at 8:07 AM, Davide Italiano via llvm-dev <span
                    class="gmail_msg"><<a moz-do-not-send="true"
                      href="mailto:llvm-dev@lists.llvm.org"
                      class="gmail_msg" target="_blank">llvm-dev@lists.llvm.org</a>></span>
                  wrote:<br class="gmail_msg">
                  <blockquote class="gmail_quote gmail_msg"
                    style="margin:0px 0px 0px 0.8ex;border-left:1px
                    solid rgb(204,204,204);padding-left:1ex"><span
                      class="m_3457995834792049705gmail- gmail_msg">On
                      Mon, Dec 19, 2016 at 4:24 PM, Mikhail Zolotukhin<br
                        class="gmail_msg">
                      <br>
                      <br>
                      <<a moz-do-not-send="true"
                        href="mailto:mzolotukhin@apple.com"
                        class="gmail_msg" target="_blank">mzolotukhin@apple.com</a>>
                      wrote:<br class="gmail_msg">
                      <br>
                      <br>
                      > Hi Davide,<br class="gmail_msg">
                      <br>
                      <br>
                      ><br class="gmail_msg">
                      <br>
                      <br>
                      > Thanks for the analysis, it's really
                      interesting! And I'm really glad that we now put
                      more and more attention at the compile time!<br
                        class="gmail_msg">
                      <br>
                      <br>
                      ><br class="gmail_msg">
                      <br>
                      <br>
                      > Just recently I've been looking into
                      historical compile time data as well, and have had
                      similar conclusions. The regressions you've found
                      are probably caused by:<br class="gmail_msg">
                      <br>
                      <br>
                      > 1) r289813 and r289855 - new matchers in
                      InstCombine<br class="gmail_msg">
                      <br>
                      <br>
                      > 2) r286814 and r288024 - changes in Inlining
                      cost model<br class="gmail_msg">
                      <br>
                      <br>
                      ><br class="gmail_msg">
                      <br>
                      <br>
                      <br class="gmail_msg">
                      <br>
                      <br>
                    </span>Haven't looked at 2) yet, but I can confirm
                    for 1). Sanjay/Ehsan, can<br class="gmail_msg">
                    <br>
                    <br>
                    you please explain what's the motivation behind the
                    new<br class="gmail_msg">
                    <br>
                    <br>
                    transformations you introduced? I'm tempted to ask a
                    revert, but I'd<br class="gmail_msg">
                    <br>
                    <br>
                    like to understand the motivations first.<br
                      class="gmail_msg">
                  </blockquote>
                  <div class="gmail_msg"><br class="gmail_msg">
                  </div>
                  <div class="gmail_msg"><br class="gmail_msg">
                  </div>
                </div>
              </div>
            </div>
            <div class="gmail_msg">
              <div class="gmail_extra gmail_msg">
                <div class="gmail_quote gmail_msg">
                  <div class="gmail_msg">Both r289813 and r289855 add a
                    very small amount of matching (it seems?) compared
                    to the rest of the size of instcombine. How is it
                    that these checks are causing such a
                    disproportionate slowdown compared to the rest of
                    instcombine? (by "I can confirm for 1)" I assume you
                    mean these two patches have a pretty significant
                    impact on compile time; not "0.1%" each)</div>
                </div>
              </div>
            </div>
            <div class="gmail_msg">
              <div class="gmail_extra gmail_msg">
                <div class="gmail_quote gmail_msg">
                  <div class="gmail_msg"><br class="gmail_msg">
                  </div>
                  <div class="gmail_msg">-- Sean Silva</div>
                  <div class="gmail_msg"> </div>
                </div>
              </div>
            </div>
            <div class="gmail_msg">
              <div class="gmail_extra gmail_msg">
                <div class="gmail_quote gmail_msg">
                  <blockquote class="gmail_quote gmail_msg"
                    style="margin:0px 0px 0px 0.8ex;border-left:1px
                    solid rgb(204,204,204);padding-left:1ex">
                    <div class="m_3457995834792049705gmail-HOEnZb
                      gmail_msg">
                      <div class="m_3457995834792049705gmail-h5
                        gmail_msg"><br class="gmail_msg">
                        <br>
                        <br>
                        --<br class="gmail_msg">
                        <br>
                        <br>
                        Davide<br class="gmail_msg">
                        <br>
                        <br>
                        <br class="gmail_msg">
                        <br>
                        <br>
                        "There are no solved problems; there are only
                        problems that are more<br class="gmail_msg">
                        <br>
                        <br>
                        or less solved" -- Henri Poincare<br
                          class="gmail_msg">
                      </div>
                    </div>
                  </blockquote>
                </div>
              </div>
            </div>
            <div class="gmail_msg">
              <div class="gmail_extra gmail_msg">
                <div class="gmail_quote gmail_msg">
                  <blockquote class="gmail_quote gmail_msg"
                    style="margin:0px 0px 0px 0.8ex;border-left:1px
                    solid rgb(204,204,204);padding-left:1ex">
                    <div class="m_3457995834792049705gmail-HOEnZb
                      gmail_msg">
                      <div class="m_3457995834792049705gmail-h5
                        gmail_msg"><br>
                        <br>
                        _______________________________________________<br
                          class="gmail_msg">
                        <br>
                        <br>
                        LLVM Developers mailing list<br
                          class="gmail_msg">
                        <br>
                        <br>
                        <a moz-do-not-send="true"
                          href="mailto:llvm-dev@lists.llvm.org"
                          class="gmail_msg" target="_blank">llvm-dev@lists.llvm.org</a><br
                          class="gmail_msg">
                        <br>
                        <br>
                        <a moz-do-not-send="true"
                          href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev"
                          rel="noreferrer" class="gmail_msg"
                          target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev</a><br
                          class="gmail_msg">
                        <br>
                        <br>
                      </div>
                    </div>
                  </blockquote>
                </div>
              </div>
            </div>
          </blockquote>
        </div>
      </div>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
      <pre wrap="">_______________________________________________
LLVM Developers mailing list
<a class="moz-txt-link-abbreviated" href="mailto:llvm-dev@lists.llvm.org">llvm-dev@lists.llvm.org</a>
<a class="moz-txt-link-freetext" href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev">http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev</a>
</pre>
    </blockquote>
    <br>
    <pre class="moz-signature" cols="72">-- 
Hal Finkel
Lead, Compiler Technology and Programming Languages
Leadership Computing Facility
Argonne National Laboratory</pre>
  </body>
</html>