<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 - Suboptimal instruction schedule leads to spilling and poor performance"
   href="https://bugs.llvm.org/show_bug.cgi?id=46934">46934</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>Suboptimal instruction schedule leads to spilling and poor performance
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>libraries
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>trunk
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>PC
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>All
          </td>
        </tr>

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

        <tr>
          <th>Severity</th>
          <td>enhancement
          </td>
        </tr>

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

        <tr>
          <th>Component</th>
          <td>Register Allocator
          </td>
        </tr>

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

        <tr>
          <th>Reporter</th>
          <td>benny.kra@gmail.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>echristo@gmail.com, llvm-bugs@lists.llvm.org, ntv@google.com, quentin.colombet@gmail.com
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Created <span class=""><a href="attachment.cgi?id=23801" name="attach_23801" title="test case">attachment 23801</a> <a href="attachment.cgi?id=23801&action=edit" title="test case">[details]</a></span>
test case

When looking at a matmul benchmark we're seeing steep performance cliffs after
tiny changes to the IR. This seems to be due to excessive spilling.

$ llc -mcpu=skx < matmul.ll | grep -c Spill
13

Picking a different scheduler can make this go away. I think it's just getting
lucky though:
$ llc -mcpu=skx < matmul.ll -pre-RA-sched=list-ilp | grep -c Spill
1

The input contains a loop with lots of loads, followed by arithmetic. It is
possible to move some of the loads down into the arithmetic to reduce register
pressure.</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>