aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStu Grossman <grossman@cygnus>1993-05-05 22:26:57 +0000
committerStu Grossman <grossman@cygnus>1993-05-05 22:26:57 +0000
commit68c8d698d4e7df0ca1197ef8546a37d2738957ee (patch)
treef680870a2f23421497a9e94b8d84c2e6688b0e7d
parenta34d4bc1782b35b034c2ceb61019e82873568cbd (diff)
downloadgdb-68c8d698d4e7df0ca1197ef8546a37d2738957ee.zip
gdb-68c8d698d4e7df0ca1197ef8546a37d2738957ee.tar.gz
gdb-68c8d698d4e7df0ca1197ef8546a37d2738957ee.tar.bz2
* Patches from Jeffrey Law <law@cs.utah.edu>.
* gdb/hppa-pinsn.c (print_insn): Handle 'r' and 'R' for break, rsm, and ssm instructions. * gdb/hppa-tdep.c (extract_5r_store, extract_5R_store): New helper functions for print_insn.
-rw-r--r--gdb/ChangeLog4
-rw-r--r--gdb/hppa-pinsn.c6
-rw-r--r--gdb/hppa-tdep.c18
3 files changed, 28 insertions, 0 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index cc0309d..ae489ef 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,6 +1,10 @@
Wed May 5 15:16:33 1993 Stu Grossman (grossman@cygnus.com)
* Patches from Jeffrey Law <law@cs.utah.edu>.
+ * gdb/hppa-pinsn.c (print_insn): Handle 'r' and 'R' for break, rsm,
+ and ssm instructions.
+ * gdb/hppa-tdep.c (extract_5r_store, extract_5R_store): New
+ helper functions for print_insn.
* gdb/hppa-tdep.c (gcc_p, hpux_cc_p): Delete unused functions.
* gdb/config/pa/tm-hppa.h (ABOUT_TO_RETURN): Handle a return
which nullifies the following instruction.
diff --git a/gdb/hppa-pinsn.c b/gdb/hppa-pinsn.c
index 87d5e7a..8b39e41 100644
--- a/gdb/hppa-pinsn.c
+++ b/gdb/hppa-pinsn.c
@@ -215,6 +215,12 @@ print_insn (memaddr, stream)
case 'V':
fput_const (extract_5_store (insn), stream);
break;
+ case 'r':
+ fput_const (extract_5r_store (insn), stream);
+ break;
+ case 'R':
+ fput_const (extract_5R_store (insn), stream);
+ break;
case 'i':
fput_const (extract_11 (insn), stream);
break;
diff --git a/gdb/hppa-tdep.c b/gdb/hppa-tdep.c
index 5f574d1..49af79e 100644
--- a/gdb/hppa-tdep.c
+++ b/gdb/hppa-tdep.c
@@ -125,6 +125,24 @@ extract_5_store (word)
return low_sign_extend (word & MASK_5, 5);
}
+/* extract the immediate field from a break instruction */
+
+unsigned
+extract_5r_store (word)
+ unsigned word;
+{
+ return (word & MASK_5);
+}
+
+/* extract the immediate field from a {sr}sm instruction */
+
+unsigned
+extract_5R_store (word)
+ unsigned word;
+{
+ return (word >> 16 & MASK_5);
+}
+
/* extract an 11 bit immediate field */
int