This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: [rfa:ppc] Cleanup SVR4 push dummy call
- From: Kevin Buettner <kevinb at redhat dot com>
- To: Andrew Cagney <ac131313 at redhat dot com>
- Cc: gdb-patches at sources dot redhat dot com
- Date: Fri, 12 Sep 2003 10:56:24 -0700
- Subject: Re: [rfa:ppc] Cleanup SVR4 push dummy call
- References: <3F61DC59.5040706@redhat.com> <3F61DFB3.7000706@redhat.com>
On Sep 12, 11:01am, Andrew Cagney wrote:
> * ppc-sysv-tdep.c (align_up, align_down): Replace "round2" macro.
> (ppc_sysv_abi_push_dummy_call): Rewrite, use a two pass loop.
Okay, except...
> ! else if (len == 8
> ! && (TYPE_CODE (type) == TYPE_CODE_INT /* long long */
> ! || (!ppc_floating_point_unit_p (current_gdbarch)
> ! && TYPE_CODE (type) == TYPE_CODE_FLT))) /* double */
> ! {
> ! /* "long long" or "double" passed in an odd/even
> ! register pair with the low addressed word in the odd
> ! register and the high addressed word in the even
> ! register, or when the registers run out an 8 byte
> ! aligned stack location. */
> ! if (greg > 9)
> ! {
> ! /* Just in case GREG was 10. */
> ! greg = 11;
> ! argoffset = align_up (argoffset, 8);
> ! write_memory (sp + argoffset, val, len);
...I believe you forgot the ``if (write_pass)'' check on the above
call to write_memory().
Kevin