<html>
    <head>
      <base href="http://llvm.org/bugs/" />
    </head>
    <body><span class="vcard"><a class="email" href="mailto:rnk@google.com" title="Reid Kleckner <rnk@google.com>"> <span class="fn">Reid Kleckner</span></a>
</span> changed
              <a class="bz_bug_link 
          bz_status_RESOLVED  bz_closed"
   title="RESOLVED DUPLICATE - Bad code generation on i686 w/ inline assembly and -mstackrealign"
   href="http://llvm.org/bugs/show_bug.cgi?id=22068">bug 22068</a>
        <br>
             <table border="1" cellspacing="0" cellpadding="8">
          <tr>
            <th>What</th>
            <th>Removed</th>
            <th>Added</th>
          </tr>

         <tr>
           <td style="text-align:right;">Status</td>
           <td>NEW
           </td>
           <td>RESOLVED
           </td>
         </tr>

         <tr>
           <td style="text-align:right;">CC</td>
           <td>
                
           </td>
           <td>rnk@google.com
           </td>
         </tr>

         <tr>
           <td style="text-align:right;">Resolution</td>
           <td>---
           </td>
           <td>DUPLICATE
           </td>
         </tr></table>
      <p>
        <div>
            <b><a class="bz_bug_link 
          bz_status_RESOLVED  bz_closed"
   title="RESOLVED DUPLICATE - Bad code generation on i686 w/ inline assembly and -mstackrealign"
   href="http://llvm.org/bugs/show_bug.cgi?id=22068#c1">Comment # 1</a>
              on <a class="bz_bug_link 
          bz_status_RESOLVED  bz_closed"
   title="RESOLVED DUPLICATE - Bad code generation on i686 w/ inline assembly and -mstackrealign"
   href="http://llvm.org/bugs/show_bug.cgi?id=22068">bug 22068</a>
              from <span class="vcard"><a class="email" href="mailto:rnk@google.com" title="Reid Kleckner <rnk@google.com>"> <span class="fn">Reid Kleckner</span></a>
</span></b>
        <pre>This is a known issue with our stack realignment that happens with rbx on x64.

I ran into and tried to make us fatal error in these situations:
<a href="http://reviews.llvm.org/D1317">http://reviews.llvm.org/D1317</a>

I'm going to dupe this against PR16830, since it's older and basically the same
problem. The core issue is that aligned stack space with a moving SP requires
three pointers to the stack:
- ebp to reference args in memory
- esp to handle calls and dynamic allocas
- "base pointer" (currently esi/rbx) to reference the aligned space

Keeping ebp where it is also keeps a reference to the return address, which is
good for frame pointer based unwinders.

*** This bug has been marked as a duplicate of <a class="bz_bug_link 
          bz_status_NEW "
   title="NEW --- - MS inline asm conflicts with base pointer register"
   href="show_bug.cgi?id=16830">bug 16830</a> ***</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>