This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: rs6000 stack boundary


Alan Modra <amodra@bigpond.net.au> writes:

> Fixes some problems with STACK_BOUNDARY.  Altivec needs 16 byte
> alignment whether or no -mabi=altivec is given, and PowerPC64 Linux
> always has a 16 byte aligned stack.  On PowerPC64 Linux, the sysv4.h
> definition unfortunately overrode the rs6000.h one.
> 
> 	* config/rs6000/rs6000.h (STACK_BOUNDARY): Use 128 bit for either
> 	TARGET_ALTIVEC or TARGET_ALTIVEC_ABI.
> 	* config/rs6000/sysv4.h (ABI_STACK_BOUNDARY): Likewise.
> 	(STACK_BOUNDARY): Delete.

This isn't right; it's not true that all ELF targets have a 128-bit
stack boundary.  In particular, EABI targets don't.  Remember,
TARGET_ALTIVEC does not change ABI.  The change would be OK if it
didn't have the TARGET_ALTIVEC part.  (Note that the sysv4.h
definition of STACK_BOUNDARY was correct.)

-- 
- Geoffrey Keating <geoffk@geoffk.org>


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]