[llvm] r175334 - [ms-inline asm] Do not omit the frame pointer if we have ms-inline assembly.

Chad Rosier mcrosier at apple.com
Fri Feb 15 18:28:13 PST 2013


On Feb 15, 2013, at 5:48 PM, Eric Christopher <echristo at gmail.com> wrote:

> 
> 
> 
> On Fri, Feb 15, 2013 at 5:25 PM, Chad Rosier <mcrosier at apple.com> wrote:
> Author: mcrosier
> Date: Fri Feb 15 19:25:28 2013
> New Revision: 175334
> 
> URL: http://llvm.org/viewvc/llvm-project?rev=175334&view=rev
> Log:
> [ms-inline asm] Do not omit the frame pointer if we have ms-inline assembly.
> 
> If the frame pointer is omitted, and any stack changes occur in the inline
> assembly, e.g.: "pusha", then any C local variable or C argument references
> will be incorrect.
> 
> I pass no judgement on anyone who would do such a thing. ;)
> rdar://13218191
> 
> Should be no different than anything in any other asm block?
> 
> I.e. why conditionalize it?

As in why do it for MS-style only?  AFAIK, the MSVC compiler has the same behavior (i.e., it always omits a frame pointer).  As for GNU-style assembly, no one has complained, so why change something that doesn't appear to be broken.

> Or why do it at all?

Because I've had external developers complain and because of the MSVC compatibility issue (which could be a correctness issue depending on how crazy the developer wants to get; again, no judgement ;).

 Chad

> -eric 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20130215/a9c8a534/attachment.html>


More information about the llvm-commits mailing list