<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 --- - LLVM generates unreachable call stack adjustments after noreturn functions when the frame is not reserved"
   href="https://llvm.org/bugs/show_bug.cgi?id=27117">27117</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>LLVM generates unreachable call stack adjustments after noreturn functions when the frame is not reserved
          </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>normal
          </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>rnk@google.com
          </td>
        </tr>

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

        <tr>
          <th>Blocks</th>
          <td>26299
          </td>
        </tr>

        <tr>
          <th>Classification</th>
          <td>Unclassified
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Consider:

__declspec(noreturn) void crash(void *);
void g(void*);
void f(int c) {
  void *p = _alloca(c);
  if (c)
    crash(p);
  g(p);
}

Here is the call to 'crash':
.LBB0_1:                                # %if.then
        callq   "?crash@@YAXPEAX@Z"
        addq    $32, %rsp
        ud2

The ADD RSP instruction is dead. On Windows, it is very common to not have a
reserved call frame because of inalloca.

Maybe the right fix here is to teach MI more about noreturn functions so we can
do more general DCE after them. It would also help us get rid of
TrapOnUnreachable in favor of inserting int3 after all noreturn 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>