This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: assign_stack_local (and friends) alignment issue
- To: John Wehle <john at feith dot com>
- Subject: Re: assign_stack_local (and friends) alignment issue
- From: Jeffrey A Law <law at hurl dot cygnus dot com>
- Date: Wed, 23 Dec 1998 00:36:05 -0700
- cc: egcs at cygnus dot com
- Reply-To: law at cygnus dot com
In message <199812200518.AAA05057@jwlab.FEITH.COM>you write:
> Ideally assign_stack_temp / assign_stack_local should have more
> information so that something like the DATA_ALIGNMENT macro could
> be used which understands that on the i386 an array of doubles
> should have at least 64 bits (actually in this specific case 256
> bits) of alignment. This could be accomplished by changing
> assign_stack_local / assign_outer_stack_local / assign_stack_temp
> to take the decl tree as a parameter (this involves changing a lot
> of callers), or by creating new functions which takes the decl tree,
> changing the old assign_stack functions to use the new ones, and changing
> expand_decl to call the new assign_stack_temp function.
I'd suggest creating new functions which take the decl as an argument, then
have the existing assign_stack_blah functions call into the new function,
creating a scratch decl as needed.
We'd then tweak all the code we could to use the new functions.
That helps with the integration issues for languages not under the egcs
umbrella. They can continue to use the old interfaces, except that they'll
not get the desired alignment in some cases.
jeff