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] PR target/18916; Function arg passing mem align fixes.


On Tue, Jan 18, 2005 at 12:23:53PM -0200, Alexandre Oliva wrote:
> I just feared the proposed change would break that.

It shouldn't do. :)   One thing that concerned me a little is that we
may generate worse code in some cases.  If a target has an ABI that
passes function parms on the stack without aligning to normal alignment
for the type, but the alignment is sufficient for all generated code,
then the new code in assign_parm_adjust_stack_rtl will unnecessarily
generate a new aligned stack temp for the parm.  This results in an
unnecessary copy.  Some tweaking of

  if (stack_parm
      && ((STRICT_ALIGNMENT
	   && GET_MODE_ALIGNMENT (data->nominal_mode) > MEM_ALIGN (stack_parm))
	  || (data->nominal_type
	      && TYPE_ALIGN (data->nominal_type) > MEM_ALIGN (stack_parm)
	      && MEM_ALIGN (stack_parm) < PREFERRED_STACK_BOUNDARY)))

may be necessary.

-- 
Alan Modra
IBM OzLabs - Linux Technology Centre


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