• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: GCC's -mstackrealign option
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: GCC's -mstackrealign option


  • Subject: Re: GCC's -mstackrealign option
  • From: Alastair Houghton <email@hidden>
  • Date: Thu, 15 Jun 2006 16:14:16 +0100

On 14 Jun 2006, at 20:46, Ladd Van Tol wrote:

So I'm porting some legacy x86 assembly to work on MacTel. The assembly code uses 4-byte stack alignment, whereas GCC on Mac OS X uses 16-byte alignment. This becomes problematic in places where the assembly calls back into the C code.

Poking around the man pages, I noticed this useful-looking option:

-mstackrealign

[snip]

I've filed a bug (#4585228) but in the meanwhile is there any way to coax GDB into behaving with -mstackrealign turned on? I'm using the Xcode 2.3 release.

Have you tried using wrappers that just re-align the stack and jump to your real C functions? If you did that, you could compile your C code without this option enabled, which might work better.


Kind regards,

Alastair.

--
http://www.alastairs-place.net


_______________________________________________ Do not post admin requests to the list. They will be ignored. Xcode-users mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
References: 
 >GCC's -mstackrealign option (From: Ladd Van Tol <email@hidden>)

  • Prev by Date: Re: Reporting distributed build bugs
  • Next by Date: Re: Debugging problem with XCode 2.3
  • Previous by thread: GCC's -mstackrealign option
  • Next by thread: zero link on of off?
  • Index(es):
    • Date
    • Thread