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: [PATCH] Alignment and split function args


On Fri, Feb 27, 2004 at 01:22:30AM +0000, Paul Brook wrote:
> On arm a and the first 3 words of b are passed in registers. The last word of 
> b, and c are passed on the stack. For some subtargets STACK_BOUNDARY == 32,  
> PREFERRED_STACK_BOUNDARY == 64, and long long types require doubleword 
> (64-bit) alignment.

As Dan notes, this is simply broken.  PREFERRED_STACK_BOUNDARY is 
absolutely *not* guaranteed, merely preferred.

If long long absolutely has to have 64-bit alignment, you'd have
to implement dynamic stack alignment, which gcc isn't set up to
support well at all.  Or change the ABI.

More likely, long long needn't actually have 64-bit alignment,
since ARM doesn't.  Yes, you'd need it to use the iwmmxt insns,
but is that absolutely required?  I think not.

That said, your patch makes sense for non-ABI-stupidity reasons.

> 	* function.c (assign_parms): Don't count pretend args for alignment.

Ok.


r~


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