diff options
author | Alan Hayward <alan.hayward@arm.com> | 2017-04-12 09:19:55 +0100 |
---|---|---|
committer | Alan Hayward <alan.hayward@arm.com> | 2017-04-12 09:19:55 +0100 |
commit | ab0538b875c054468aa205d8d36550d1223a3bfd (patch) | |
tree | 4ef56ad715d7030f80d136aebca441799ed9cd24 | |
parent | 5430098f1807e084fe4ff5057040d68435f3d8a2 (diff) | |
download | gdb-ab0538b875c054468aa205d8d36550d1223a3bfd.zip gdb-ab0538b875c054468aa205d8d36550d1223a3bfd.tar.gz gdb-ab0538b875c054468aa205d8d36550d1223a3bfd.tar.bz2 |
Add M32R_ARG_REGISTER_SIZE
gdb/
* m32r-tdep.c M32R_ARG_REGISTER_SIZE: Added.
(m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
-rw-r--r-- | gdb/ChangeLog | 5 | ||||
-rw-r--r-- | gdb/m32r-tdep.c | 5 |
2 files changed, 9 insertions, 1 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 087c0735..29afd13 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,8 @@ +2017-04-12 Alan Hayward <alan.hayward@arm.com> + + * m32r-tdep.c M32R_ARG_REGISTER_SIZE: Added. + (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE. + 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com> * windows-nat.c (windows_create_inferior): Declare 'toexec' as diff --git a/gdb/m32r-tdep.c b/gdb/m32r-tdep.c index 1d0d7ed..4701f7a 100644 --- a/gdb/m32r-tdep.c +++ b/gdb/m32r-tdep.c @@ -39,6 +39,9 @@ #include "m32r-tdep.h" #include <algorithm> +/* The size of the argument registers (r0 - r3) in bytes. */ +#define M32R_ARG_REGISTER_SIZE 4 + /* Local functions */ extern void _initialize_m32r_tdep (void); @@ -677,7 +680,7 @@ m32r_push_dummy_call (struct gdbarch *gdbarch, struct value *function, enum type_code typecode; CORE_ADDR regval; gdb_byte *val; - gdb_byte valbuf[MAX_REGISTER_SIZE]; + gdb_byte valbuf[M32R_ARG_REGISTER_SIZE]; int len; /* First force sp to a 4-byte alignment. */ |