2004-08-02 Andrew Cagney <cagney@gnu.org>

* regcache.h: Delete DEPRECATED_REGISTER_VIRTUAL_SIZE and
	DEPRECATED_REGISTER_RAW_SIZE from comments.
	* regcache.c (init_regcache_descr, regcache_dump): Do not check or
	use DEPRECATED_REGISTER_VIRTUAL_SIZE and
	DEPRECATED_REGISTER_RAW_SIZE.
	* findvar.c (value_of_register): Simplify by assuming that the
	registers raw and virtual sizes are identical.
	* regcache.h: Delete DEPRECATED_REGISTER_VIRTUAL_TYPE in
	comment.
	* arch-utils.c (generic_register_size): Simplify by assuming
	register_type.
This commit is contained in:
Andrew Cagney
2004-08-02 21:58:44 +00:00
parent 73f458fb31
commit 01e1877c5f
5 changed files with 21 additions and 88 deletions

View File

@@ -282,18 +282,8 @@ value_of_register (int regnum, struct frame_info *frame)
reg_val = allocate_value (register_type (current_gdbarch, regnum));
/* Convert raw data to virtual format if necessary. */
if (DEPRECATED_REGISTER_RAW_SIZE (regnum) == DEPRECATED_REGISTER_VIRTUAL_SIZE (regnum))
memcpy (VALUE_CONTENTS_RAW (reg_val), raw_buffer,
DEPRECATED_REGISTER_RAW_SIZE (regnum));
else
internal_error (__FILE__, __LINE__,
"Register \"%s\" (%d) has conflicting raw (%d) and virtual (%d) size",
REGISTER_NAME (regnum),
regnum,
DEPRECATED_REGISTER_RAW_SIZE (regnum),
DEPRECATED_REGISTER_VIRTUAL_SIZE (regnum));
memcpy (VALUE_CONTENTS_RAW (reg_val), raw_buffer,
register_size (current_gdbarch, regnum));
VALUE_LVAL (reg_val) = lval;
VALUE_ADDRESS (reg_val) = addr;
VALUE_REGNO (reg_val) = regnum;