<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <div class="moz-cite-prefix">The example looks like there's a bug in
      the handling of truncstores:
      DAGCombiner::MergeStoresOfConstantsOrVecElts does "StoreInt |=
      C->getAPIntValue().zextOrTrunc(SizeInBits);", which doesn't
      correctly mask away the extra bits of a truncstore.  Not sure how
      to write a testcase, though.<br>
      <br>
      -Eli<br>
      <br>
      On 11/29/2017 11:01 AM, Nirav Davé wrote:<br>
    </div>
    <blockquote type="cite"
cite="mid:CAEQ+OH9pcYu7U6=tgBii_xEASt1uDyL_WkhkjZrrRO__9TCSrQ@mail.gmail.com">
      <div dir="ltr">Disabled in ARM in r319331.</div>
      <div class="gmail_extra"><br>
        <div class="gmail_quote">On Wed, Nov 29, 2017 at 12:31 PM, Nirav
          Davé <span dir="ltr"><<a href="mailto:niravd@google.com"
              target="_blank" moz-do-not-send="true">niravd@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">Sure If no one objects I'll disable this for
              just the ARM target. <span class="HOEnZb"><font
                  color="#888888">
                  <div><br>
                  </div>
                  <div>-Nirav</div>
                </font></span></div>
            <div class="HOEnZb">
              <div class="h5">
                <div class="gmail_extra"><br>
                  <div class="gmail_quote">On Wed, Nov 29, 2017 at 12:23
                    PM, Evgeny Astigeevich via Phabricator <span
                      dir="ltr"><<a
                        href="mailto:reviews@reviews.llvm.org"
                        target="_blank" moz-do-not-send="true">reviews@reviews.llvm.org</a>></span>
                    wrote:<br>
                    <blockquote class="gmail_quote" style="margin:0 0 0
                      .8ex;border-left:1px #ccc solid;padding-left:1ex">eastig
                      added a comment.<br>
                      <br>
                      Hi Nirav,<br>
                      <br>
                      Could you please revert the changes? They affected
                      Arm targets (Thumb2 code).<br>
                      The following sequence of stores:<br>
                      <br>
                        MOVS     r0,#0xe5<br>
                        STRB     r0,[r6,#0x1e5]<br>
                        MOVS     r0,#0xe4<br>
                        STRB     r0,[r6,#0x1e4]<br>
                        MOVS     r0,#0xe6<br>
                        STRB     r0,[r6,#0x1e6]<br>
                        MOVS     r0,#0xe7<br>
                        STRB     r0,[r6,#0x1e7]<br>
                      <br>
                      is optimised into<br>
                      <br>
                        MVN      r0,#0x1b<br>
                        STR      r0,[r6,#0x1e4]<br>
                      <br>
                      causing incorrect data to be written.<br>
                      <br>
                      We are working on a reproducer.<br>
                      <br>
                      Thanks,<br>
                      Evgeny Astigeevich<br>
                      The Arm Compiler Optimisation team<br>
                      <div class="m_3935825366907052374HOEnZb">
                        <div class="m_3935825366907052374h5"><br>
                          <br>
                          Repository:<br>
                            rL LLVM<br>
                          <br>
                          <a href="https://reviews.llvm.org/D33675"
                            rel="noreferrer" target="_blank"
                            moz-do-not-send="true">https://reviews.llvm.org/D3367<wbr>5</a><br>
                          <br>
                          <br>
                          <br>
                        </div>
                      </div>
                    </blockquote>
                  </div>
                  <br>
                </div>
              </div>
            </div>
          </blockquote>
        </div>
        <br>
      </div>
    </blockquote>
    <p><br>
    </p>
    <pre class="moz-signature" cols="72">-- 
Employee of Qualcomm Innovation Center, Inc.
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a Linux Foundation Collaborative Project</pre>
  </body>
</html>