diff options
author | Pierre Muller <muller@sourceware.org> | 2001-12-03 08:41:10 +0000 |
---|---|---|
committer | Pierre Muller <muller@sourceware.org> | 2001-12-03 08:41:10 +0000 |
commit | 14e534aa3559f269c92d72f1d9a5dda56c0aab2d (patch) | |
tree | f2deb8ac40a58c7424dc2607f926744ee7d32825 | |
parent | 441532d7b8ddcdcf36a2228746687d1681a369da (diff) | |
download | gdb-14e534aa3559f269c92d72f1d9a5dda56c0aab2d.zip gdb-14e534aa3559f269c92d72f1d9a5dda56c0aab2d.tar.gz gdb-14e534aa3559f269c92d72f1d9a5dda56c0aab2d.tar.bz2 |
2001-11-30 Pierre Muller <muller@ics.u-strasbg.fr>
* findvar.c (locate_var_value): Specify in which register a register
variable is stored.
-rw-r--r-- | gdb/ChangeLog | 5 | ||||
-rw-r--r-- | gdb/findvar.c | 17 |
2 files changed, 20 insertions, 2 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 3cdd070..732be25 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,10 @@ 2001-11-30 Pierre Muller <muller@ics.u-strasbg.fr> + * findvar.c (locate_var_value): Specify in which register a register + variable is stored. + +2001-11-30 Pierre Muller <muller@ics.u-strasbg.fr> + * win32-nat.c (mappings): Correct position of XMM registers, based on FXSAVE instruction structure. diff --git a/gdb/findvar.c b/gdb/findvar.c index b9b9be4..5f5766c 100644 --- a/gdb/findvar.c +++ b/gdb/findvar.c @@ -29,6 +29,7 @@ #include "inferior.h" #include "target.h" #include "gdb_string.h" +#include "gdb_assert.h" #include "floatformat.h" #include "symfile.h" /* for overlay functions */ #include "regcache.h" @@ -869,9 +870,21 @@ locate_var_value (register struct symbol *var, struct frame_info *frame) switch (VALUE_LVAL (lazy_value)) { case lval_register: + gdb_assert (REGISTER_NAME (VALUE_REGNO (lazy_value)) != NULL + && *REGISTER_NAME (VALUE_REGNO (lazy_value)) != '\0'); + error("Address requested for identifier " + "\"%s\" which is in register $%s", + SYMBOL_SOURCE_NAME (var), + REGISTER_NAME (VALUE_REGNO (lazy_value))); + break; + case lval_reg_frame_relative: - error ("Address requested for identifier \"%s\" which is in a register.", - SYMBOL_SOURCE_NAME (var)); + gdb_assert (REGISTER_NAME (VALUE_FRAME_REGNUM (lazy_value)) != NULL + && *REGISTER_NAME (VALUE_FRAME_REGNUM (lazy_value)) != '\0'); + error("Address requested for identifier " + "\"%s\" which is in frame register $%s", + SYMBOL_SOURCE_NAME (var), + REGISTER_NAME (VALUE_FRAME_REGNUM (lazy_value))); break; default: |