diff options
author | Michael Snyder <msnyder@vmware.com> | 2002-09-05 18:31:07 +0000 |
---|---|---|
committer | Michael Snyder <msnyder@vmware.com> | 2002-09-05 18:31:07 +0000 |
commit | 6672060b1877c20582d769ffa31b7d13b030cc97 (patch) | |
tree | f00d104e3e72eaa2c23913d6d5a919dd573bc0c2 | |
parent | 299ffc6418d380c1a2145f755b6a724feabca81b (diff) | |
download | ppe42-binutils-6672060b1877c20582d769ffa31b7d13b030cc97.tar.gz ppe42-binutils-6672060b1877c20582d769ffa31b7d13b030cc97.zip |
2002-09-05 Michael Snyder <msnyder@redhat.com>
* mips-tdep.c (mips_n32n64_push_arguments): Remove alignment
adjustment that doesn't conform to the ABI.
(mips_extract_struct_value_address): Retrieve V0_REGNUM from
saved regcache, not from current regcache.
-rw-r--r-- | gdb/ChangeLog | 7 | ||||
-rw-r--r-- | gdb/mips-tdep.c | 10 |
2 files changed, 11 insertions, 6 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 388861949b..415773c87b 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,10 @@ +2002-09-05 Michael Snyder <msnyder@redhat.com> + + * mips-tdep.c (mips_n32n64_push_arguments): Remove alignment + adjustment that doesn't conform to the ABI. + (mips_extract_struct_value_address): Retrieve V0_REGNUM from + saved regcache, not from current regcache. + 2002-09-05 Andrew Cagney <ac131313@redhat.com> * NEWS: Update for 5.3. Add new section ``Changes since 5.3''. diff --git a/gdb/mips-tdep.c b/gdb/mips-tdep.c index 58e1a8b128..eeffe24f8e 100644 --- a/gdb/mips-tdep.c +++ b/gdb/mips-tdep.c @@ -2955,10 +2955,6 @@ mips_n32n64_push_arguments (int nargs, typecode == TYPE_CODE_PTR || typecode == TYPE_CODE_FLT) && len <= 4) longword_offset = MIPS_STACK_ARGSIZE - len; - else if ((typecode == TYPE_CODE_STRUCT || - typecode == TYPE_CODE_UNION) && - TYPE_LENGTH (arg_type) < MIPS_STACK_ARGSIZE) - longword_offset = MIPS_STACK_ARGSIZE - len; } if (mips_debug) @@ -4906,12 +4902,14 @@ mips_store_struct_return (CORE_ADDR addr, CORE_ADDR sp) } static CORE_ADDR -mips_extract_struct_value_address (struct regcache *ignore) +mips_extract_struct_value_address (struct regcache *regcache) { /* FIXME: This will only work at random. The caller passes the struct_return address in V0, but it is not preserved. It may still be there, or this may be a random value. */ - return read_register (V0_REGNUM); + CORE_ADDR val; + regcache_cooked_read_unsigned (regcache, V0_REGNUM, &val); + return val; } /* Exported procedure: Is PC in the signal trampoline code */ |