<html>
    <head>
      <base href="http://llvm.org/bugs/" />
    </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 --- - Radeon: code generation for GCN GPUs seems to be broken. Clpeak benchmark outputs many errors ("Can't spill VGPR!") and then GPU hangs."
   href="http://llvm.org/bugs/show_bug.cgi?id=20738">20738</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>Radeon: code generation for GCN GPUs seems to be broken. Clpeak benchmark outputs many errors ("Can't spill VGPR!") and then GPU hangs.
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>clang
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>trunk
          </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>release blocker
          </td>
        </tr>

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

        <tr>
          <th>Component</th>
          <td>-New Bugs
          </td>
        </tr>

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

        <tr>
          <th>Reporter</th>
          <td>t3st@sogetthis.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvmbugs@cs.uiuc.edu
          </td>
        </tr>

        <tr>
          <th>Classification</th>
          <td>Unclassified
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Created <span class=""><a href="attachment.cgi?id=12931" name="attach_12931" title="LLVM error log.">attachment 12931</a> <a href="attachment.cgi?id=12931&action=edit" title="LLVM error log.">[details]</a></span>
LLVM error log.

Configuration: 
 AMD R9 270 GPU. 
 Linux kernel 3.16
 LLVM 3.15-rc3

Problem:
 Code generation for AMD GPUs seems to be broken in LLVM. At very least for GCN
based GPUs.
 When trying to run certain opencl kernels, LLVMS seems to face numerous
troubles and then probably generates bugged code which locks up GPU.

To reproduce:
1) Get "clpeak" tool at <a href="https://github.com/krrishnarraj/clpeak.git">https://github.com/krrishnarraj/clpeak.git</a>
2) Build it. 
3) Try to use it with AMD GCN-based GPU. I used R9 270 for this test.
4) Take a look what happens.

Test result: 
1) LLVM outputs about 40Kb of error messages (log attached).
2) After some time of running OpenCL kernels GPU locks up.

Notes: 
1) I was never able to complete single run of clpeak benchmark on opencl GPUs
due to GPU lockups. Bug seems to be dead simple to reproduce.
2) Could also be some kernel or lib issue, let's AMD staff to classify it
correctly.</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>