aboutsummaryrefslogtreecommitdiff
path: root/opcodes
diff options
context:
space:
mode:
authorMaciej W. Rozycki <macro@imgtec.com>2016-12-09 22:27:00 +0000
committerMaciej W. Rozycki <macro@imgtec.com>2016-12-09 23:18:06 +0000
commit55af478400524cba7994e353fd9a98ef1543df2f (patch)
treeec2194cbeaf5733b21fc26a20d2d6d82b37d6339 /opcodes
parent1736a7bd96e8927c3f889a35f9153df4fd19d833 (diff)
downloadgdb-55af478400524cba7994e353fd9a98ef1543df2f.zip
gdb-55af478400524cba7994e353fd9a98ef1543df2f.tar.gz
gdb-55af478400524cba7994e353fd9a98ef1543df2f.tar.bz2
MIPS16/opcodes: Reformat raw EXTEND and undecoded output
Use a tab rather than a space to separate `extend' and its uninterpreted argument output, like with regular instructions. Separate hexadecimal halves of undecoded extended instructions output with a space instead of presenting them concatenated. opcodes/ * mips-dis.c (print_insn_mips16): Use a tab rather than a space to separate `extend' and its uninterpreted argument output. Separate hexadecimal halves of undecoded extended instructions output. binutils/ * testsuite/binutils-all/mips/mips16-extend-noinsn.d: New test. * testsuite/binutils-all/mips/mips16-extend-noinsn.s: New test source. * testsuite/binutils-all/mips/mips.exp: Run the new test.
Diffstat (limited to 'opcodes')
-rw-r--r--opcodes/ChangeLog7
-rw-r--r--opcodes/mips-dis.c8
2 files changed, 11 insertions, 4 deletions
diff --git a/opcodes/ChangeLog b/opcodes/ChangeLog
index 1e5ca72..0d0e186 100644
--- a/opcodes/ChangeLog
+++ b/opcodes/ChangeLog
@@ -1,3 +1,10 @@
+2016-12-09 Maciej W. Rozycki <macro@imgtec.com>
+
+ * mips-dis.c (print_insn_mips16): Use a tab rather than a space
+ to separate `extend' and its uninterpreted argument output.
+ Separate hexadecimal halves of undecoded extended instructions
+ output.
+
2016-12-08 Maciej W. Rozycki <macro@imgtec.com>
* mips-dis.c (print_mips16_insn_arg): Remove extraneous
diff --git a/opcodes/mips-dis.c b/opcodes/mips-dis.c
index c23e369..b3daacd 100644
--- a/opcodes/mips-dis.c
+++ b/opcodes/mips-dis.c
@@ -2042,7 +2042,7 @@ print_insn_mips16 (bfd_vma memaddr, struct disassemble_info *info)
status = (*info->read_memory_func) (memaddr, buffer, 2, info);
if (status != 0)
{
- infprintf (is, "extend 0x%x", (unsigned int) extend);
+ infprintf (is, "extend\t0x%x", (unsigned int) extend);
(*info->memory_error_func) (status, memaddr, info);
return -1;
}
@@ -2055,7 +2055,7 @@ print_insn_mips16 (bfd_vma memaddr, struct disassemble_info *info)
/* Check for an extend opcode followed by an extend opcode. */
if ((insn & 0xf800) == 0xf000)
{
- infprintf (is, "extend 0x%x", (unsigned int) extend);
+ infprintf (is, "extend\t0x%x", (unsigned int) extend);
info->insn_type = dis_noninsn;
return length;
}
@@ -2078,7 +2078,7 @@ print_insn_mips16 (bfd_vma memaddr, struct disassemble_info *info)
{
if (use_extend)
{
- infprintf (is, "extend 0x%x", (unsigned int) extend);
+ infprintf (is, "extend\t0x%x", (unsigned int) extend);
info->insn_type = dis_noninsn;
return length - 2;
}
@@ -2147,7 +2147,7 @@ print_insn_mips16 (bfd_vma memaddr, struct disassemble_info *info)
#undef GET_OP
if (use_extend)
- infprintf (is, "0x%x", extend | 0xf000);
+ infprintf (is, "0x%x ", extend | 0xf000);
infprintf (is, "0x%x", insn);
info->insn_type = dis_noninsn;