This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB 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: [rfa/6.0] Better handle unspecified CFI values


On Fri, Sep 05, 2003 at 08:57:57PM -0400, Andrew Cagney wrote:
> +	  /* Can things get worse?  Yep!  One of the registers GCC
> +	     forgot to provide unwind information for was the stack
> +	     pointer.  Outch!  GCC appears to assumes that the CFA
> +	     address can be used - after all it points to the inner
> +	     most address of the previous frame before the function
> +	     call and that's always the same as the stack pointer on
> +	     return, right?

Yes, gcc does assume the CFA can be used, except when there is
a CFI entry for the stack pointer.  See s390 for this case.

> 	     Wrong.  See GCC's i386 STDCALL option for
> +	     an ABI that has a different entry and return stack

Indeed, this is a problem.  Please file a gcc pr for this.  We
should be generating an entry for the stack pointer in this case.

We probably don't see the bug in gcc's unwinding for exception
handling because we also apply the fixup for DW_CFA_GNU_args_size,
since we're not unwinding to the call site exactly, but rather to
the handler within the function.


r~


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