<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 - lld should synthesize .ARM.exidx entries for code without them"
   href="https://bugs.llvm.org/show_bug.cgi?id=40277">40277</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>lld should synthesize .ARM.exidx entries for code without them
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>lld
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>unspecified
          </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>enhancement
          </td>
        </tr>

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

        <tr>
          <th>Component</th>
          <td>ELF
          </td>
        </tr>

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

        <tr>
          <th>Reporter</th>
          <td>george.burgess.iv@gmail.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvm-bugs@lists.llvm.org, peter.smith@linaro.org
          </td>
        </tr></table>
      <p>
        <div>
        <pre>(Apologies if I use vague/handwavy terminology here; I'm not super familiar
with ARM EH or linker terminology)

When a function is defined in assembly, it appears that -- reasonably so --
there will be no unwinding information in .ARM.exidx/.ARM.extab to go along
with it, unless the user goes out of their way to somehow specify that.

This becomes problematic when this assembly code is linked with C/C++ that's
built with unwinding info. AFAICT, the .ARM.exidx entry selected to try to
unwind this asm is the .ARM.exidx entry of the nearest function(s) laid out
before the asm. This... can work, but doesn't always. :)

Gold appears to handle this by synthesizing `cantunwind` .ARM.exidx entries for
functions/sections that have no associated .ARM.exidx entry. I think it would
be reasonable for lld to do the same.</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>