<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 - __divdf3 returns zero with some extreme values"
   href="https://bugs.llvm.org/show_bug.cgi?id=51396">51396</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>__divdf3 returns zero with some extreme values
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>compiler-rt
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>11.0
          </td>
        </tr>

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

        <tr>
          <th>OS</th>
          <td>other
          </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>compiler-rt
          </td>
        </tr>

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

        <tr>
          <th>Reporter</th>
          <td>aykevanlaethem@gmail.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvm-bugs@lists.llvm.org
          </td>
        </tr></table>
      <p>
        <div>
        <pre>I've found that __divdf3 returns an incorrect result for a specific input.
Specifically:

    a = 1.7112092293746032e-193 (raw bits: 0x17E8FBBB7CBDC600)
    b = 8.858903059828881e+116  (raw bits: 0x58367bbed68d8223)
    result = __divdf3(a, b)

I've found that the output is 0, while all hardware implementations I've tested
this code with return a non-zero value: 1.9316265431712e-310 (raw bits:
0x0000238ee05c879e). Therefore, I think this is a bug in __divdf3.

In practice, this issue causes the math package in Go to fail the tests when
compiled with TinyGo and when using the compiler-rt library on a baremetal
system.</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>