Document replacement for frame_register_read (deprecated).

gdb/ChangeLog:

        * frame.h (frame_register_read): Remove FIXME comment.
        * frame.c (frame_register_read): Add suggestion explaining
        which function to use in place of this one.
This commit is contained in:
Joel Brobecker 2012-11-12 21:28:51 +00:00
parent 31594462ca
commit b2c7d45a4c
3 changed files with 8 additions and 13 deletions

View file

@ -1,3 +1,9 @@
2012-11-12 Joel Brobecker <brobecker@adacore.com>
* frame.h (frame_register_read): Remove FIXME comment.
* frame.c (frame_register_read): Add suggestion explaining
which function to use in place of this one.
2012-11-12 Tom Tromey <tromey@redhat.com> 2012-11-12 Tom Tromey <tromey@redhat.com>
* python/python.c (start_type_printers): Initialize 'result_obj'. * python/python.c (start_type_printers): Initialize 'result_obj'.

View file

@ -1088,7 +1088,8 @@ put_frame_register (struct frame_info *frame, int regnum,
} }
} }
/* frame_register_read () /* This function is deprecated. Use get_frame_register_value instead,
which provides more accurate information.
Find and return the value of REGNUM for the specified stack frame. Find and return the value of REGNUM for the specified stack frame.
The number of bytes copied is REGISTER_SIZE (REGNUM). The number of bytes copied is REGISTER_SIZE (REGNUM).

View file

@ -673,18 +673,6 @@ extern struct frame_info *block_innermost_frame (const struct block *);
extern int deprecated_pc_in_call_dummy (struct gdbarch *gdbarch, CORE_ADDR pc); extern int deprecated_pc_in_call_dummy (struct gdbarch *gdbarch, CORE_ADDR pc);
/* FIXME: cagney/2003-02-02: Should be deprecated or replaced with a
function called get_frame_register_p(). This slightly weird (and
older) variant of get_frame_register() returns zero (indicating the
register value is unavailable/invalid) if either: the register
isn't cached; or the register has been optimized out; or the
register contents are unavailable (because they haven't been
collected in a traceframe). Problem is, neither check is exactly
correct. A register can't be optimized out (it may not have been
saved as part of a function call); The fact that a register isn't
in the register cache doesn't mean that the register isn't
available (it could have been fetched from memory). */
extern int frame_register_read (struct frame_info *frame, int regnum, extern int frame_register_read (struct frame_info *frame, int regnum,
gdb_byte *buf); gdb_byte *buf);