This is the mail archive of the
mailing list for the GCC project.
Re: [PATCH] ia64 -fstack-protector support
- From: Richard Henderson <rth at redhat dot com>
- To: Jakub Jelinek <jakub at redhat dot com>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Mon, 4 Jul 2005 14:53:37 -0700
- Subject: Re: [PATCH] ia64 -fstack-protector support
- References: <20050704185228.GQ15087@devserv.devel.redhat.com>
On Mon, Jul 04, 2005 at 02:52:28PM -0400, Jakub Jelinek wrote:
> -#define FRAME_GROWS_DOWNWARD 0
> +#define FRAME_GROWS_DOWNWARD (flag_stack_protect != 0)
As much as possible, this should not change based on stack-protect.
We want as much testing as possible with frame layout.
I know what you're trying to do is avoid extra padding here:
> + if (FRAME_GROWS_DOWNWARD)
> + size = IA64_STACK_ALIGN (size);
but that simply means you chose the wrong point at which to base
the soft frame pointer. Seems like the most appropriate place is
the incoming stack pointer + 16, aka the CFA. This does mean that
the initial stack offset is variable (based on spill_size etc), but
> + ia64_compute_frame_size (size = get_frame_size ());
Please avoid embedding assignments in other expressions when possible.