<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 - Strict fp->int needs to trigger an invalid exception if the input value is out of range for the destination value when hardware can't detect it"
   href="https://bugs.llvm.org/show_bug.cgi?id=44019">44019</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>Strict fp->int needs to trigger an invalid exception if the input value is out of range for the destination value when hardware can't detect it
          </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>Windows NT
          </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>Common Code Generator Code
          </td>
        </tr>

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

        <tr>
          <th>Reporter</th>
          <td>craig.topper@gmail.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvm-bugs@lists.llvm.org
          </td>
        </tr></table>
      <p>
        <div>
        <pre>If the direct conversion to the result type isn't support by hardware we
currently promote the operation to a supported hardware conversion followed by
a truncate. But this will only trigger an exception if the input is out of
range for the promoted result type.

This is being done in multiple places. Either in type legalization if the
result type isn't legal. During op legalization if the target sets an
operationAction of Promote. Or in the case of X86(maybe other targets), in a
Custom handler.

We should insert a range check and a jump to code that will trigger an invalid
exception, like 0.0 divided by 0.0.</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>