+2012-11-12 Joel Brobecker <brobecker@adacore.com>
+
+ * frame.h (deprecated_frame_register_read): Renames
+ frame_register_read.
+ * frame.c (deprecated_frame_register_read): Renames
+ frame_register_read. Update all callers.
+ * i386-tdep.c: Update all callers of frame_register_read.
+ * infcmd.c: Likewise.
+ * jit.c: Likewise.
+ * mips-tdep.c: Likewise.
+ * mt-tdep.c: Likewise.
+ * sh64-tdep.c: Likewise.
+
2012-11-12 Joel Brobecker <brobecker@adacore.com>
* frame.h (frame_register_read): Remove FIXME comment.
static enum register_status
do_frame_register_read (void *src, int regnum, gdb_byte *buf)
{
- if (!frame_register_read (src, regnum, buf))
+ if (!deprecated_frame_register_read (src, regnum, buf))
return REG_UNAVAILABLE;
else
return REG_VALID;
Returns 0 if the register value could not be found. */
int
-frame_register_read (struct frame_info *frame, int regnum,
+deprecated_frame_register_read (struct frame_info *frame, int regnum,
gdb_byte *myaddr)
{
int optimized;
{
gdb_byte buf[MAX_REGISTER_SIZE];
- frame_register_read (frame, regnum, buf);
+ deprecated_frame_register_read (frame, regnum, buf);
memcpy (buf + offset, myaddr, curr_len);
put_frame_register (frame, regnum, buf);
}
extern int deprecated_pc_in_call_dummy (struct gdbarch *gdbarch, CORE_ADDR pc);
-extern int frame_register_read (struct frame_info *frame, int regnum,
+extern int deprecated_frame_register_read (struct frame_info *frame, int regnum,
gdb_byte *buf);
/* From stack.c. */
/* Saved stack pointer has been saved (but the SAVED_SP_REG
register may be unavailable). */
if (cache->saved_sp == 0
- && frame_register_read (this_frame, cache->saved_sp_reg, buf))
+ && deprecated_frame_register_read (this_frame,
+ cache->saved_sp_reg, buf))
cache->saved_sp = extract_unsigned_integer (buf, 4, byte_order);
}
/* Now that we have the base address for the stack frame we can
val = allocate_value (regtype);
/* Get the data in raw format. */
- if (! frame_register_read (frame, i, value_contents_raw (val)))
+ if (! deprecated_frame_register_read (frame, i, value_contents_raw (val)))
mark_value_bytes_unavailable (val, 0, TYPE_LENGTH (value_type (val)));
default_print_one_register_info (file,
gdb_reg = gdbarch_dwarf2_reg_to_regnum (frame_arch, regnum);
size = register_size (frame_arch, gdb_reg);
value = xmalloc (sizeof (struct gdb_reg_value) + size - 1);
- value->defined = frame_register_read (priv->this_frame, gdb_reg,
- value->value);
+ value->defined = deprecated_frame_register_read (priv->this_frame, gdb_reg,
+ value->value);
value->size = size;
value->free = reg_value_free_impl;
return value;
int raw_size = register_size (gdbarch, regno);
gdb_byte *raw_buffer = alloca (raw_size);
- if (!frame_register_read (frame, regno, raw_buffer))
+ if (!deprecated_frame_register_read (frame, regno, raw_buffer))
error (_("can't read register %d (%s)"),
regno, gdbarch_register_name (gdbarch, regno));
if (raw_size == 8)
{
/* We have a 64-bit value for this register, and we should use
all 64 bits. */
- if (!frame_register_read (frame, regno, rare_buffer))
+ if (!deprecated_frame_register_read (frame, regno, rare_buffer))
error (_("can't read register %d (%s)"),
regno, gdbarch_register_name (gdbarch, regno));
}
break; /* End row: large register. */
/* OK: get the data in raw format. */
- if (!frame_register_read (frame, regnum, raw_buffer))
+ if (!deprecated_frame_register_read (frame, regnum, raw_buffer))
error (_("can't read register %d (%s)"),
regnum, gdbarch_register_name (gdbarch, regnum));
/* pad small registers */
buff = alloca (regsize);
bytes = alloca (regsize * sizeof (*bytes));
- frame_register_read (frame, regnum, buff);
+ deprecated_frame_register_read (frame, regnum, buff);
fputs_filtered (gdbarch_register_name
(gdbarch, regnum), file);
struct value_print_options opts;
buf = alloca (register_size (gdbarch, MT_COPRO_REGNUM));
- frame_register_read (frame, MT_COPRO_REGNUM, buf);
+ deprecated_frame_register_read (frame, MT_COPRO_REGNUM, buf);
/* And print. */
regnum = MT_COPRO_PSEUDOREG_REGNUM;
fputs_filtered (gdbarch_register_name (gdbarch, regnum),
gdb_byte buf[3 * sizeof (LONGEST)];
/* Get the two "real" mac registers. */
- frame_register_read (frame, MT_MAC_REGNUM, buf);
+ deprecated_frame_register_read (frame, MT_MAC_REGNUM, buf);
oldmac = extract_unsigned_integer
(buf, register_size (gdbarch, MT_MAC_REGNUM), byte_order);
if (gdbarch_bfd_arch_info (gdbarch)->mach == bfd_mach_mrisc2
|| gdbarch_bfd_arch_info (gdbarch)->mach == bfd_mach_ms2)
{
- frame_register_read (frame, MT_EXMAC_REGNUM, buf);
+ deprecated_frame_register_read (frame, MT_EXMAC_REGNUM, buf);
ext_mac = extract_unsigned_integer
(buf, register_size (gdbarch, MT_EXMAC_REGNUM), byte_order);
}
alloca (register_size (gdbarch, gdbarch_fp0_regnum (gdbarch)));
/* Get the data in raw format. */
- if (!frame_register_read (frame, regnum, raw_buffer))
+ if (!deprecated_frame_register_read (frame, regnum, raw_buffer))
error (_("can't read register %d (%s)"),
regnum, gdbarch_register_name (gdbarch, regnum));
(gdbarch, regnum)), file);
/* Get the data in raw format. */
- if (!frame_register_read (frame, regnum, raw_buffer))
+ if (!deprecated_frame_register_read (frame, regnum, raw_buffer))
fprintf_filtered (file, "*value not available*\n");
get_formatted_print_options (&opts, 'x');