diff options
author | Andrew Cagney <cagney@redhat.com> | 2002-04-12 18:18:59 +0000 |
---|---|---|
committer | Andrew Cagney <cagney@redhat.com> | 2002-04-12 18:18:59 +0000 |
commit | cda5a58a3e11c1676519d476534636cc3e8bf02c (patch) | |
tree | 25cacefd5b1553dcf83d0fc164e5d05a35292670 /gdb | |
parent | 2ea5f656d72f0457f59fd540874bd2cad0687b1f (diff) | |
download | gdb-cda5a58a3e11c1676519d476534636cc3e8bf02c.zip gdb-cda5a58a3e11c1676519d476534636cc3e8bf02c.tar.gz gdb-cda5a58a3e11c1676519d476534636cc3e8bf02c.tar.bz2 |
* defs.h (read_relative_register_raw_bytes): Delete declaration.
* frame.c (frame_register_read): New function. Return non-zero on
success.
(read_relative_register_raw_bytes_for_frame): Delete.
(read_relative_register_raw_bytes): Delete.
* frame.h (frame_register_read): Declare.
* d30v-tdep.c: Update Copyright. Use frame_register_read.
* sh-tdep.c: Ditto.
* infcmd.c (do_registers_info): Ditto.
* hppa-tdep.c: Ditto.
* rs6000-tdep.c: Ditto.
* h8500-tdep.c: Ditto.
* mips-tdep.c: Ditto.
* h8300-tdep.c: Ditto.
* z8k-tdep.c: Ditto.
Diffstat (limited to 'gdb')
-rw-r--r-- | gdb/ChangeLog | 18 | ||||
-rw-r--r-- | gdb/d30v-tdep.c | 7 | ||||
-rw-r--r-- | gdb/defs.h | 4 | ||||
-rw-r--r-- | gdb/frame.c | 36 | ||||
-rw-r--r-- | gdb/frame.h | 5 | ||||
-rw-r--r-- | gdb/h8300-tdep.c | 7 | ||||
-rw-r--r-- | gdb/h8500-tdep.c | 7 | ||||
-rw-r--r-- | gdb/hppa-tdep.c | 17 | ||||
-rw-r--r-- | gdb/infcmd.c | 2 | ||||
-rw-r--r-- | gdb/mi/ChangeLog | 6 | ||||
-rw-r--r-- | gdb/mi/mi-main.c | 6 | ||||
-rw-r--r-- | gdb/mips-tdep.c | 12 | ||||
-rw-r--r-- | gdb/mn10300-tdep.c | 7 | ||||
-rw-r--r-- | gdb/rs6000-tdep.c | 4 | ||||
-rw-r--r-- | gdb/sh-tdep.c | 4 | ||||
-rw-r--r-- | gdb/sparc-tdep.c | 18 | ||||
-rw-r--r-- | gdb/z8k-tdep.c | 19 |
17 files changed, 97 insertions, 82 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 86df853..a58790e 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,21 @@ +2002-04-12 Andrew Cagney <cagney@redhat.com> + + * defs.h (read_relative_register_raw_bytes): Delete declaration. + * frame.c (frame_register_read): New function. Return non-zero on + success. + (read_relative_register_raw_bytes_for_frame): Delete. + (read_relative_register_raw_bytes): Delete. + * frame.h (frame_register_read): Declare. + * d30v-tdep.c: Update Copyright. Use frame_register_read. + * sh-tdep.c: Ditto. + * infcmd.c (do_registers_info): Ditto. + * hppa-tdep.c: Ditto. + * rs6000-tdep.c: Ditto. + * h8500-tdep.c: Ditto. + * mips-tdep.c: Ditto. + * h8300-tdep.c: Ditto. + * z8k-tdep.c: Ditto. + 2002-04-12 Kevin Buettner <kevinb@redhat.com> From Jimi X <jimix@watson.ibm.com>: diff --git a/gdb/d30v-tdep.c b/gdb/d30v-tdep.c index ede8dd8..b5d3a3b 100644 --- a/gdb/d30v-tdep.c +++ b/gdb/d30v-tdep.c @@ -1,6 +1,7 @@ /* Target-dependent code for Mitsubishi D30V, for GDB. - Copyright 1996, 1997, 1998, 1999, 2000, 2001 - Free Software Foundation, Inc. + + Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002 Free Software + Foundation, Inc. This file is part of GDB. @@ -725,7 +726,7 @@ d30v_print_register (int regnum, int tabular) { char regbuf[MAX_REGISTER_RAW_SIZE]; - read_relative_register_raw_bytes (regnum, regbuf); + frame_register_read (selected_frame, regnum, regbuf); val_print (REGISTER_VIRTUAL_TYPE (regnum), regbuf, 0, 0, gdb_stdout, 'x', 1, 0, Val_pretty_default); @@ -580,10 +580,6 @@ extern void exec_set_find_memory_regions (int (*) (int (*) (CORE_ADDR, void *), void *)); -/* From findvar.c */ - -extern int read_relative_register_raw_bytes (int, char *); - /* Possible lvalue types. Like enum language, this should be in value.h, but needs to be here for the same reason. */ diff --git a/gdb/frame.c b/gdb/frame.c index 8849f2f..5886ab5 100644 --- a/gdb/frame.c +++ b/gdb/frame.c @@ -175,40 +175,26 @@ get_saved_register (char *raw_buffer, GET_SAVED_REGISTER (raw_buffer, optimized, addrp, frame, regnum, lval); } -/* READ_RELATIVE_REGISTER_RAW_BYTES_FOR_FRAME +/* frame_register_read () - Copy the bytes of register REGNUM, relative to the input stack frame, - into our memory at MYADDR, in target byte order. + Find and return the value of REGNUM for the specified stack frame. The number of bytes copied is REGISTER_RAW_SIZE (REGNUM). - Returns 1 if could not be read, 0 if could. */ + Returns 0 if the register value could not be found. */ -static int -read_relative_register_raw_bytes_for_frame (int regnum, - char *myaddr, - struct frame_info *frame) +int +frame_register_read (struct frame_info *frame, int regnum, void *myaddr) { int optim; get_saved_register (myaddr, &optim, (CORE_ADDR *) NULL, frame, regnum, (enum lval_type *) NULL); + /* FIXME: cagney/2002-04-10: This test is just bogus. It is no + indication of the validity of the register. The value could + easily be found (on the stack) even though the corresponding + register isn't available. */ if (register_cached (regnum) < 0) - return 1; /* register value not available */ - - return optim; -} + return 0; /* register value not available */ -/* READ_RELATIVE_REGISTER_RAW_BYTES - - Copy the bytes of register REGNUM, relative to the current stack - frame, into our memory at MYADDR, in target byte order. - The number of bytes copied is REGISTER_RAW_SIZE (REGNUM). - - Returns 1 if could not be read, 0 if could. */ - -int -read_relative_register_raw_bytes (int regnum, char *myaddr) -{ - return read_relative_register_raw_bytes_for_frame (regnum, myaddr, - selected_frame); + return !optim; } diff --git a/gdb/frame.h b/gdb/frame.h index a989890..4f41364 100644 --- a/gdb/frame.h +++ b/gdb/frame.h @@ -282,4 +282,9 @@ extern void get_saved_register (char *raw_buffer, int *optimized, struct frame_info *frame, int regnum, enum lval_type *lval); +/* Return the register as found on the FRAME. Return zero if the + register could not be found. */ +extern int frame_register_read (struct frame_info *frame, int regnum, + void *buf); + #endif /* !defined (FRAME_H) */ diff --git a/gdb/h8300-tdep.c b/gdb/h8300-tdep.c index e335fdb..93b9bbb 100644 --- a/gdb/h8300-tdep.c +++ b/gdb/h8300-tdep.c @@ -1,6 +1,7 @@ /* Target-machine dependent code for Hitachi H8/300, for GDB. - Copyright 1988, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1998, 1999, - 2000, 2001 Free Software Foundation, Inc. + + Copyright 1988, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1998, + 1999, 2000, 2001, 2002 Free Software Foundation, Inc. This file is part of GDB. @@ -834,7 +835,7 @@ h8300_print_register_hook (int regno) int C, Z, N, V; unsigned char b[4]; unsigned char l; - read_relative_register_raw_bytes (regno, b); + frame_register_read (selected_frame, regno, b); l = b[REGISTER_VIRTUAL_SIZE (8) - 1]; printf_unfiltered ("\t"); printf_unfiltered ("I-%d - ", (l & 0x80) != 0); diff --git a/gdb/h8500-tdep.c b/gdb/h8500-tdep.c index 01869bb..04ba706 100644 --- a/gdb/h8500-tdep.c +++ b/gdb/h8500-tdep.c @@ -1,6 +1,7 @@ /* Target-dependent code for Hitachi H8/500, for GDB. - Copyright 1993, 1994, 1995, 1998, 2000, 2001 - Free Software Foundation, Inc. + + Copyright 1993, 1994, 1995, 1998, 2000, 2001, 2002 Free Software + Foundation, Inc. This file is part of GDB. @@ -186,7 +187,7 @@ print_register_hook (int regno) unsigned char b[2]; unsigned char l; - read_relative_register_raw_bytes (regno, b); + frame_register_read (selected_frame, regno, b); l = b[1]; printf_unfiltered ("\t"); printf_unfiltered ("I-%d - ", (l & 0x80) != 0); diff --git a/gdb/hppa-tdep.c b/gdb/hppa-tdep.c index e8a68cf..175b702 100644 --- a/gdb/hppa-tdep.c +++ b/gdb/hppa-tdep.c @@ -1,6 +1,7 @@ /* Target-dependent code for the HP PA architecture, for GDB. - Copyright 1986, 1987, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, - 1998, 1999, 2000, 2001 Free Software Foundation, Inc. + + Copyright 1986, 1987, 1989, 1990, 1991, 1992, 1993, 1994, 1995, + 1996, 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc. Contributed by the Center for Software Science at the University of Utah (pa-gdb-bugs@cs.utah.edu). @@ -2488,7 +2489,7 @@ pa_do_registers_info (int regnum, int fpregs) /* Make a copy of gdb's save area (may cause actual reads from the target). */ for (i = 0; i < NUM_REGS; i++) - read_relative_register_raw_bytes (i, raw_regs + REGISTER_BYTE (i)); + frame_register_read (selected_frame, i, raw_regs + REGISTER_BYTE (i)); if (regnum == -1) pa_print_registers (raw_regs, regnum, fpregs); @@ -2532,7 +2533,7 @@ pa_do_strcat_registers_info (int regnum, int fpregs, struct ui_file *stream, /* Make a copy of gdb's save area (may cause actual reads from the target). */ for (i = 0; i < NUM_REGS; i++) - read_relative_register_raw_bytes (i, raw_regs + REGISTER_BYTE (i)); + frame_register_read (selected_frame, i, raw_regs + REGISTER_BYTE (i)); if (regnum == -1) pa_strcat_registers (raw_regs, regnum, fpregs, stream); @@ -2784,7 +2785,7 @@ pa_print_fp_reg (int i) char virtual_buffer[MAX_REGISTER_VIRTUAL_SIZE]; /* Get 32bits of data. */ - read_relative_register_raw_bytes (i, raw_buffer); + frame_register_read (selected_frame, i, raw_buffer); /* Put it in the buffer. No conversions are ever necessary. */ memcpy (virtual_buffer, raw_buffer, REGISTER_RAW_SIZE (i)); @@ -2802,7 +2803,7 @@ pa_print_fp_reg (int i) if ((i % 2) == 0) { /* Get the data in raw format for the 2nd half. */ - read_relative_register_raw_bytes (i + 1, raw_buffer); + frame_register_read (selected_frame, i + 1, raw_buffer); /* Copy it into the appropriate part of the virtual buffer. */ memcpy (virtual_buffer + REGISTER_RAW_SIZE (i), raw_buffer, @@ -2830,7 +2831,7 @@ pa_strcat_fp_reg (int i, struct ui_file *stream, enum precision_type precision) print_spaces_filtered (8 - strlen (REGISTER_NAME (i)), stream); /* Get 32bits of data. */ - read_relative_register_raw_bytes (i, raw_buffer); + frame_register_read (selected_frame, i, raw_buffer); /* Put it in the buffer. No conversions are ever necessary. */ memcpy (virtual_buffer, raw_buffer, REGISTER_RAW_SIZE (i)); @@ -2841,7 +2842,7 @@ pa_strcat_fp_reg (int i, struct ui_file *stream, enum precision_type precision) char raw_buf[MAX_REGISTER_RAW_SIZE]; /* Get the data in raw format for the 2nd half. */ - read_relative_register_raw_bytes (i + 1, raw_buf); + frame_register_read (selected_frame, i + 1, raw_buf); /* Copy it into the appropriate part of the virtual buffer. */ memcpy (virtual_buffer + REGISTER_RAW_SIZE (i), raw_buf, REGISTER_RAW_SIZE (i)); diff --git a/gdb/infcmd.c b/gdb/infcmd.c index a10a91a..0680caa 100644 --- a/gdb/infcmd.c +++ b/gdb/infcmd.c @@ -1590,7 +1590,7 @@ do_registers_info (int regnum, int fpregs) print_spaces_filtered (15 - strlen (REGISTER_NAME (i)), gdb_stdout); /* Get the data in raw format. */ - if (read_relative_register_raw_bytes (i, raw_buffer)) + if (! frame_register_read (selected_frame, i, raw_buffer)) { printf_filtered ("*value not available*\n"); continue; diff --git a/gdb/mi/ChangeLog b/gdb/mi/ChangeLog index 7de9d64..cfe77bd 100644 --- a/gdb/mi/ChangeLog +++ b/gdb/mi/ChangeLog @@ -1,3 +1,9 @@ +2002-04-09 Andrew Cagney <ac131313@redhat.com> + + * mi-main.c (register_changed_p): Use frame_register_read instead + of read_relative_register_raw_bytes. + (get_register): Delete out-of-date comment. + 2002-04-07 Elena Zannoni <ezannoni@redhat.com> * mi-cmd-disas.c: Run through indent. diff --git a/gdb/mi/mi-main.c b/gdb/mi/mi-main.c index 238d0e7..f42fdcf 100644 --- a/gdb/mi/mi-main.c +++ b/gdb/mi/mi-main.c @@ -368,7 +368,7 @@ register_changed_p (int regnum) { char *raw_buffer = alloca (MAX_REGISTER_RAW_SIZE); - if (read_relative_register_raw_bytes (regnum, raw_buffer)) + if (! frame_register_read (selected_frame, regnum, raw_buffer)) return -1; if (memcmp (&old_regs[REGISTER_BYTE (regnum)], raw_buffer, @@ -481,10 +481,6 @@ get_register (int regnum, int format) if (format == 'N') format = 0; - /* read_relative_register_raw_bytes returns a virtual frame pointer - (FRAME_FP (selected_frame)) if regnum == FP_REGNUM instead - of the real contents of the register. To get around this, - use get_saved_register instead. */ get_saved_register (raw_buffer, &optim, (CORE_ADDR *) NULL, selected_frame, regnum, (enum lval_type *) NULL); if (optim) diff --git a/gdb/mips-tdep.c b/gdb/mips-tdep.c index c3fa252..3de03fa 100644 --- a/gdb/mips-tdep.c +++ b/gdb/mips-tdep.c @@ -1,7 +1,7 @@ /* Target-dependent code for the MIPS architecture, for GDB, the GNU Debugger. - Copyright 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, - 1998, 1999, 2000, 2001 Free Software Foundation, Inc. + Copyright 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, + 1997, 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc. Contributed by Alessandro Forin(af@cs.cmu.edu) at CMU and by Per Bothner(bothner@cs.wisc.edu) at U.Wisconsin. @@ -2747,7 +2747,7 @@ mips_read_fp_register_single (int regno, char *rare_buffer) int raw_size = REGISTER_RAW_SIZE (regno); char *raw_buffer = alloca (raw_size); - if (read_relative_register_raw_bytes (regno, raw_buffer)) + if (!frame_register_read (selected_frame, regno, raw_buffer)) error ("can't read register %d (%s)", regno, REGISTER_NAME (regno)); if (raw_size == 8) { @@ -2781,7 +2781,7 @@ mips_read_fp_register_double (int regno, char *rare_buffer) { /* We have a 64-bit value for this register, and we should use all 64 bits. */ - if (read_relative_register_raw_bytes (regno, rare_buffer)) + if (!frame_register_read (selected_frame, regno, rare_buffer)) error ("can't read register %d (%s)", regno, REGISTER_NAME (regno)); } else @@ -2812,7 +2812,7 @@ mips_print_register (int regnum, int all) char raw_buffer[MAX_REGISTER_RAW_SIZE]; /* Get the data in raw format. */ - if (read_relative_register_raw_bytes (regnum, raw_buffer)) + if (!frame_register_read (selected_frame, regnum, raw_buffer)) { printf_filtered ("%s: [Invalid]", REGISTER_NAME (regnum)); return; @@ -2992,7 +2992,7 @@ do_gp_register_row (int regnum) if (TYPE_CODE (REGISTER_VIRTUAL_TYPE (regnum)) == TYPE_CODE_FLT) break; /* end row: reached FP register */ /* OK: get the data in raw format. */ - if (read_relative_register_raw_bytes (regnum, raw_buffer)) + if (!frame_register_read (selected_frame, regnum, raw_buffer)) error ("can't read register %d (%s)", regnum, REGISTER_NAME (regnum)); /* pad small registers */ for (byte = 0; byte < (MIPS_REGSIZE - REGISTER_VIRTUAL_SIZE (regnum)); byte++) diff --git a/gdb/mn10300-tdep.c b/gdb/mn10300-tdep.c index a618ca7..ceb97ad 100644 --- a/gdb/mn10300-tdep.c +++ b/gdb/mn10300-tdep.c @@ -1,6 +1,7 @@ /* Target-dependent code for the Matsushita MN10300 for GDB, the GNU debugger. - Copyright 1996, 1997, 1998, 1999, 2000, 2001 - Free Software Foundation, Inc. + + Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002 Free Software + Foundation, Inc. This file is part of GDB. @@ -1010,7 +1011,7 @@ mn10300_print_register (const char *name, int regnum, int reg_width) printf_filtered ("%s: ", name); /* Get the data */ - if (read_relative_register_raw_bytes (regnum, raw_buffer)) + if (!frame_register_read (selected_frame, regnum, raw_buffer)) { printf_filtered ("[invalid]"); return; diff --git a/gdb/rs6000-tdep.c b/gdb/rs6000-tdep.c index e0f07bc..86c07f4 100644 --- a/gdb/rs6000-tdep.c +++ b/gdb/rs6000-tdep.c @@ -1729,7 +1729,7 @@ rs6000_do_altivec_registers (int regnum) print_spaces_filtered (15 - strlen (REGISTER_NAME (i)), gdb_stdout); /* Get the data in raw format. */ - if (read_relative_register_raw_bytes (i, raw_buffer)) + if (!frame_register_read (selected_frame, i, raw_buffer)) { printf_filtered ("*value not available*\n"); continue; @@ -1826,7 +1826,7 @@ rs6000_do_registers_info (int regnum, int fpregs) print_spaces_filtered (15 - strlen (REGISTER_NAME (i)), gdb_stdout); /* Get the data in raw format. */ - if (read_relative_register_raw_bytes (i, raw_buffer)) + if (!frame_register_read (selected_frame, i, raw_buffer)) { printf_filtered ("*value not available*\n"); continue; diff --git a/gdb/sh-tdep.c b/gdb/sh-tdep.c index 107385f..996e611 100644 --- a/gdb/sh-tdep.c +++ b/gdb/sh-tdep.c @@ -1732,7 +1732,7 @@ sh_do_fp_register (int regnum) raw_buffer = (char *) alloca (REGISTER_RAW_SIZE (FP0_REGNUM)); /* Get the data in raw format. */ - if (read_relative_register_raw_bytes (regnum, raw_buffer)) + if (!frame_register_read (selected_frame, regnum, raw_buffer)) error ("can't read register %d (%s)", regnum, REGISTER_NAME (regnum)); /* Get the register as a number */ @@ -1769,7 +1769,7 @@ sh_do_register (int regnum) print_spaces_filtered (15 - strlen (REGISTER_NAME (regnum)), gdb_stdout); /* Get the data in raw format. */ - if (read_relative_register_raw_bytes (regnum, raw_buffer)) + if (!frame_register_read (selected_frame, regnum, raw_buffer)) printf_filtered ("*value not available*\n"); val_print (REGISTER_VIRTUAL_TYPE (regnum), raw_buffer, 0, 0, diff --git a/gdb/sparc-tdep.c b/gdb/sparc-tdep.c index ed3726e..d6c5dcc 100644 --- a/gdb/sparc-tdep.c +++ b/gdb/sparc-tdep.c @@ -1,6 +1,8 @@ /* Target-dependent code for the SPARC for GDB, the GNU debugger. - Copyright 1986, 1987, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, - 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc. + + Copyright 1986, 1987, 1989, 1990, 1991, 1992, 1993, 1994, 1995, + 1996, 1997, 1998, 1999, 2000, 2001, 2002 Free Software Foundation, + Inc. This file is part of GDB. @@ -1829,8 +1831,8 @@ sparc_print_register_hook (int regno) { char value[16]; - if (!read_relative_register_raw_bytes (regno, value) - && !read_relative_register_raw_bytes (regno + 1, value + 4)) + if (frame_register_read (selected_frame, regno, value) + && frame_register_read (selected_frame, regno + 1, value + 4)) { printf_unfiltered ("\t"); print_floating (value, builtin_type_double, gdb_stdout); @@ -1838,8 +1840,8 @@ sparc_print_register_hook (int regno) #if 0 /* FIXME: gdb doesn't handle long doubles */ if ((regno & 3) == 0) { - if (!read_relative_register_raw_bytes (regno + 2, value + 8) - && !read_relative_register_raw_bytes (regno + 3, value + 12)) + if (frame_register_read (selected_frame, regno + 2, value + 8) + && frame_register_read (selected_frame, regno + 3, value + 12)) { printf_unfiltered ("\t"); print_floating (value, builtin_type_long_double, gdb_stdout); @@ -1858,8 +1860,8 @@ sparc_print_register_hook (int regno) { char value[16]; - if (!read_relative_register_raw_bytes (regno, value) - && !read_relative_register_raw_bytes (regno + 1, value + 8)) + if (frame_register_read (selected_frame, regno, value) + && frame_register_read (selected_frame, regno + 1, value + 8)) { printf_unfiltered ("\t"); print_floating (value, builtin_type_long_double, gdb_stdout); diff --git a/gdb/z8k-tdep.c b/gdb/z8k-tdep.c index 622cbc0..fa043a2 100644 --- a/gdb/z8k-tdep.c +++ b/gdb/z8k-tdep.c @@ -1,6 +1,7 @@ /* Target-machine dependent code for Zilog Z8000, for GDB. - Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001 - Free Software Foundation, Inc. + + Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, + 2002 Free Software Foundation, Inc. This file is part of GDB. @@ -330,8 +331,8 @@ z8k_print_register_hook (int regno) { unsigned short l[2]; - read_relative_register_raw_bytes (regno, (char *) (l + 0)); - read_relative_register_raw_bytes (regno + 1, (char *) (l + 1)); + frame_register_read (selected_frame, regno, (char *) (l + 0)); + frame_register_read (selected_frame, regno + 1, (char *) (l + 1)); printf_unfiltered ("\t"); printf_unfiltered ("%04x%04x", l[0], l[1]); } @@ -340,10 +341,10 @@ z8k_print_register_hook (int regno) { unsigned short l[4]; - read_relative_register_raw_bytes (regno, (char *) (l + 0)); - read_relative_register_raw_bytes (regno + 1, (char *) (l + 1)); - read_relative_register_raw_bytes (regno + 2, (char *) (l + 2)); - read_relative_register_raw_bytes (regno + 3, (char *) (l + 3)); + frame_register_read (selected_frame, regno, (char *) (l + 0)); + frame_register_read (selected_frame, regno + 1, (char *) (l + 1)); + frame_register_read (selected_frame, regno + 2, (char *) (l + 2)); + frame_register_read (selected_frame, regno + 3, (char *) (l + 3)); printf_unfiltered ("\t"); printf_unfiltered ("%04x%04x%04x%04x", l[0], l[1], l[2], l[3]); @@ -353,7 +354,7 @@ z8k_print_register_hook (int regno) unsigned short rval; int i; - read_relative_register_raw_bytes (regno, (char *) (&rval)); + frame_register_read (selected_frame, regno, (char *) (&rval)); printf_unfiltered ("\n"); for (i = 0; i < 10; i += 2) |