This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
[committed] Fix disassembly of addil/ldil on hppa
- From: "John David Anglin" <dave at hiauly1 dot hia dot nrc dot ca>
- To: binutils at sources dot redhat dot com
- Cc: carlos at systemhalted dot org
- Date: Fri, 5 Aug 2005 14:03:10 -0400 (EDT)
- Subject: [committed] Fix disassembly of addil/ldil on hppa
This fixes a small problem noticied by Carlos O'Donell. When disassembly
addil and ldil, we shift the immediate value left 11 bits for display on
output. We need to prefix the value with L% to show that the value has
been shifted, or we shouldn't shift the value. I've choosen to prefix
the value with "L%" as that seems the most useful form. It's also what's
done by adb.
Tested on hppa-unknown-linux-gnu.
Dave
--
J. David Anglin dave.anglin@nrc-cnrc.gc.ca
National Research Council of Canada (613) 990-0752 (FAX: 952-6602)
2005-08-05 John David Anglin <dave.anglin@nrc-crnc.gc.ca>
* hppa-dis.c (print_insn_hppa): Prefix 21-bit values with "L%".
Index: hppa-dis.c
===================================================================
RCS file: /cvs/src/src/opcodes/hppa-dis.c,v
retrieving revision 1.46
diff -u -3 -p -r1.46 hppa-dis.c
--- hppa-dis.c 17 Jul 2005 02:26:26 -0000 1.46
+++ hppa-dis.c 5 Aug 2005 17:27:12 -0000
@@ -912,6 +912,7 @@ print_insn_hppa (bfd_vma memaddr, disass
fput_const (extract_14 (insn), info);
break;
case 'k':
+ fputs_filtered ("L%", info);
fput_const (extract_21 (insn), info);
break;
case '<':
2005-08-05 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
* gas/hppa/reloc/reloc.exp (do_function_reloc_bug): Add "L%" to regexp.
Index: gas/hppa/reloc/reloc.exp
===================================================================
RCS file: /cvs/src/src/gas/testsuite/gas/hppa/reloc/reloc.exp,v
retrieving revision 1.11
diff -u -3 -p -r1.11 reloc.exp
--- gas/hppa/reloc/reloc.exp 5 May 2005 09:13:13 -0000 1.11
+++ gas/hppa/reloc/reloc.exp 5 Aug 2005 17:28:14 -0000
@@ -545,7 +545,7 @@ proc do_function_reloc_bug {} {
# Make sure we didn't put anything in the instruction itself!
while 1 {
expect {
- -re "^0+cc\[^\n\]*ldil 0,r20\[^\n\]*\n"
+ -re "^0+cc\[^\n\]*ldil L%0,r20\[^\n\]*\n"
{ set x [expr $x+1] }
-re "^0+d0\[^\n\]*ldo 0\[\(\]+r20\[\)\]+,r19\[^\n\]*\n"
{ set x [expr $x+1] }