aboutsummaryrefslogtreecommitdiff
path: root/gdb/iq2000-tdep.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/iq2000-tdep.c')
-rw-r--r--gdb/iq2000-tdep.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/gdb/iq2000-tdep.c b/gdb/iq2000-tdep.c
index 1e95077..ed6621d 100644
--- a/gdb/iq2000-tdep.c
+++ b/gdb/iq2000-tdep.c
@@ -86,7 +86,7 @@ insn_addr_from_ptr (CORE_ADDR ptr) /* target_pointer to CORE_ADDR. */
Convert a target pointer to an address in host (CORE_ADDR) format. */
static CORE_ADDR
-iq2000_pointer_to_address (struct type * type, const void * buf)
+iq2000_pointer_to_address (struct type * type, const gdb_byte * buf)
{
enum type_code target = TYPE_CODE (TYPE_TARGET_TYPE (type));
CORE_ADDR addr = extract_unsigned_integer (buf, TYPE_LENGTH (type));
@@ -103,7 +103,7 @@ iq2000_pointer_to_address (struct type * type, const void * buf)
Convert a host-format address (CORE_ADDR) into a target pointer. */
static void
-iq2000_address_to_pointer (struct type *type, void *buf, CORE_ADDR addr)
+iq2000_address_to_pointer (struct type *type, gdb_byte *buf, CORE_ADDR addr)
{
enum type_code target = TYPE_CODE (TYPE_TARGET_TYPE (type));
@@ -393,7 +393,7 @@ static void
iq2000_frame_prev_register (struct frame_info *next_frame, void **this_cache,
int regnum, int *optimizedp,
enum lval_type *lvalp, CORE_ADDR *addrp,
- int *realnump, void *valuep)
+ int *realnump, gdb_byte *valuep)
{
struct iq2000_frame_cache *cache = iq2000_frame_cache (next_frame, this_cache);
if (regnum == E_SP_REGNUM && cache->saved_sp)
@@ -558,7 +558,6 @@ iq2000_extract_return_value (struct type *type, struct regcache *regcache,
returned in a register, and if larger than 8 bytes, it is
returned in a stack location which is pointed to by the same
register. */
- CORE_ADDR return_buffer;
int len = TYPE_LENGTH (type);
if (len <= (2 * 4))
@@ -584,7 +583,9 @@ iq2000_extract_return_value (struct type *type, struct regcache *regcache,
{
/* Return values > 8 bytes are returned in memory,
pointed to by FN_RETURN_REGNUM. */
- regcache_cooked_read (regcache, E_FN_RETURN_REGNUM, & return_buffer);
+ ULONGEST return_buffer;
+ regcache_cooked_read_unsigned (regcache, E_FN_RETURN_REGNUM,
+ &return_buffer);
read_memory (return_buffer, valbuf, TYPE_LENGTH (type));
}
}
@@ -592,7 +593,7 @@ iq2000_extract_return_value (struct type *type, struct regcache *regcache,
static enum return_value_convention
iq2000_return_value (struct gdbarch *gdbarch, struct type *type,
struct regcache *regcache,
- void *readbuf, const void *writebuf)
+ gdb_byte *readbuf, const gdb_byte *writebuf)
{
if (iq2000_use_struct_convention (type))
return RETURN_VALUE_STRUCT_CONVENTION;