<html>
    <head>
      <base href="https://bugs.llvm.org/">
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - Performance regression: SROA apepars to add unnecessary code to critical path function"
   href="https://bugs.llvm.org/show_bug.cgi?id=33438">33438</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>Performance regression: SROA apepars to add unnecessary code to critical path function
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>new-bugs
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>4.0
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>Other
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>Linux
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>normal
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>P
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>new bugs
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>unassignedbugs@nondot.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>eric.schweitz@pgroup.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvm-bugs@lists.llvm.org
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Created <span class=""><a href="attachment.cgi?id=18630" name="attach_18630" title="SROA adding many phi-nodes">attachment 18630</a> <a href="attachment.cgi?id=18630&action=edit" title="SROA adding many phi-nodes">[details]</a></span>
SROA adding many phi-nodes

A performance regression in a large code has been tracked down to a difference
between the way LLVM 3.9 and LLVM 4.0 produce code for a particular function.
The reproducer is attached.

In LLVM 4.0, one can see that the function performs saves on all registers

# BB#0:                                 # %L.entry
        std 20, -96(1)                  # 8-byte Folded Spill
        std 21, -88(1)                  # 8-byte Folded Spill
        std 22, -80(1)                  # 8-byte Folded Spill
        std 23, -72(1)                  # 8-byte Folded Spill
        std 24, -64(1)                  # 8-byte Folded Spill
        std 25, -56(1)                  # 8-byte Folded Spill
        std 26, -48(1)                  # 8-byte Folded Spill
        std 27, -40(1)                  # 8-byte Folded Spill

lots of register-to-register moves

        mr 27, 0
        mr 30, 0
        mr 29, 0
        mr 28, 0
        mr 26, 0
        mr 8, 0
        mr 7, 0

etc.

The code produced by LLVM 3.9 does not contain these instructions.

It appears that SROA may play some role in this regression.</pre>
        </div>
      </p>


      <hr>
      <span>You are receiving this mail because:</span>

      <ul>
          <li>You are on the CC list for the bug.</li>
      </ul>
    </body>
</html>