<html>
    <head>
      <base href="https://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 --- - ARM backend crash when compiling half-precision FP op without hardware FP"
   href="https://llvm.org/bugs/show_bug.cgi?id=24549">24549</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>ARM backend crash when compiling half-precision FP op without hardware FP
          </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>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>Backend: ARM
          </td>
        </tr>

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

        <tr>
          <th>Reporter</th>
          <td>oliver.stannard@arm.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvm-bugs@lists.llvm.org
          </td>
        </tr>

        <tr>
          <th>Classification</th>
          <td>Unclassified
          </td>
        </tr></table>
      <p>
        <div>
        <pre>This IR causes the ARM backend to crash when it is compiled for a target that
does not have any floating-point hardware:

  target datalayout = "e-m:e-p:32:32-i64:64-v128:64:128-a:0:32-n32-S64"
  target triple = "armv7--none-eabi"

  define void @foo(half* %a, half* %b, half* %c) {
  entry:
    %d = load half, half* %a
    %e = load half, half* %b
    %f = fadd half %d, %e
    store half %f, half* %c
    ret void
  }

This is the error I get (with a recent trunk build):
$ llc test.ll -mattr=-vfp2
LLVM ERROR: Unsupported library call operation!

LLVM is attempting to lower the half-precision fadd to a library call, but
there are no library calls for half-precision. it should probably promote the
value to float (as it does when f32 is legal but f16 is not), and then emit f32
library calls.</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>