aboutsummaryrefslogtreecommitdiff
path: root/gdb/hppa-tdep.c
diff options
context:
space:
mode:
authorPeter Schauer <Peter.Schauer@mytum.de>1993-11-02 21:51:10 +0000
committerPeter Schauer <Peter.Schauer@mytum.de>1993-11-02 21:51:10 +0000
commitad09cb2bd3ea991f862103ee802a7a93e7895909 (patch)
tree9cf8cf03811fb421fa7f561f13fa4254c9a5018c /gdb/hppa-tdep.c
parentffd334ce820ff277e635f4a674b60776f0d633fd (diff)
downloadfsf-binutils-gdb-ad09cb2bd3ea991f862103ee802a7a93e7895909.zip
fsf-binutils-gdb-ad09cb2bd3ea991f862103ee802a7a93e7895909.tar.gz
fsf-binutils-gdb-ad09cb2bd3ea991f862103ee802a7a93e7895909.tar.bz2
* findvar.c (value_of_register, value_from_register),
hppa-tdep.c (pa_print_fp_reg), infcmd.c (do_registers_info), valops.c (value_assign): Use REGISTER_CONVERT_TO_* only if REGISTER_CONVERTIBLE is defined, otherwise just copy the content. Pass desired type to REGISTER_CONVERT_TO_*. * config/m68k/tm-m68k.h, config/i960/tm-i960.h (REGISTER_CONVERT_*): Pass length of desired type to store/extract_floating. * config/i386/tm-arm.h, config/i386/tm-i386aix.h, config/i386/tm-sun386.h, config/i386/tm-symmetry.h, config/m88k/tm-m88k.h config/rs6000/tm-rs6000.h (REGISTER_CONVERT_*): Use extract_floating and store_floating with length of desired type. * config/m68k/tm-news.h (STORE,EXTRACT_RETURN_VALUE): Add type parameter to REGISTER_CONVERT_*. * config/a29k/tm-a29k.h, config/convex/tm-convex.h, config/gould/tm-np1.h, config/gould/tm-pn.h, config/h8300/tm-h8300.h, config/h8500/tm-h8500.h, config/i386/tm-i386v.h, config/mips/tm-mips.h, config/ns32k/tm-merlin.h, config/ns32k/tm-umax.h, config/pa/tm-hppa.h, config/pyr/tm-pyr.h, config/sh/tm-sh.h, config/sparc/tm-sparc.h, config/tahoe/tm-tahoe.h, config/vax/tm-vax.h, config/z8k/tm-z8k.h (REGISTER_CONVERTIBLE, REGISTER_CONVERT_TO_RAW, REGISTER_CONVERT_TO_VIRTUAL): Remove versions for which REGISTER_CONVERTIBLE is always false. * z8k-tdep.c (register_convert_to_virtual, register_convert_to_raw): Remove, no longer used. * alpha-tdep.c (alpha_register_convert_to_raw, alpha_register_convert_to_virtual): New routines to handle the different raw formats in alpha floating point registers. * config/alpha/tm-alpha.h (REGISTER_CONVERTIBLE, REGISTER_CONVERT_TO_VIRTUAL, REGISTER_CONVERT_TO_RAW): Use them.
Diffstat (limited to 'gdb/hppa-tdep.c')
-rw-r--r--gdb/hppa-tdep.c15
1 files changed, 13 insertions, 2 deletions
diff --git a/gdb/hppa-tdep.c b/gdb/hppa-tdep.c
index 186a080..cc16dd0 100644
--- a/gdb/hppa-tdep.c
+++ b/gdb/hppa-tdep.c
@@ -1097,9 +1097,20 @@ pa_print_fp_reg (i)
unsigned char virtual_buffer[MAX_REGISTER_VIRTUAL_SIZE];
REGISTER_TYPE val;
- /* Get the data in raw format, then convert also to virtual format. */
+ /* Get the data in raw format. */
read_relative_register_raw_bytes (i, raw_buffer);
- REGISTER_CONVERT_TO_VIRTUAL (i, raw_buffer, virtual_buffer);
+
+ /* Convert raw data to virtual format if necessary. */
+#ifdef REGISTER_CONVERTIBLE
+ if (REGISTER_CONVERTIBLE (i))
+ {
+ REGISTER_CONVERT_TO_VIRTUAL (i, REGISTER_VIRTUAL_TYPE (i),
+ raw_buffer, virtual_buffer);
+ }
+ else
+#endif
+ memcpy (virtual_buffer, raw_buffer,
+ REGISTER_VIRTUAL_SIZE (i));
fputs_filtered (reg_names[i], gdb_stdout);
print_spaces_filtered (15 - strlen (reg_names[i]), gdb_stdout);