diff options
author | Helge Deller <deller@gmx.de> | 2023-11-17 11:26:02 +0100 |
---|---|---|
committer | Helge Deller <deller@gmx.de> | 2023-11-17 18:36:36 +0100 |
commit | 2f926bfd5b79e6219ae65a1e530b38f37d62b384 (patch) | |
tree | d47bf51643f9b941ee3e37fabd6223f6f6f2b6ae /disas | |
parent | a01491a238fab670ba68b5c649c109c64ae23e21 (diff) |
disas/hppa: Show hexcode of instruction along with disassembly
On hppa many instructions can be expressed by different bytecodes.
To be able to debug qemu translation bugs it's therefore necessary to see the
currently executed byte codes without the need to lookup the sequence without
the full executable.
With this patch the instruction byte code is shown beside the disassembly.
Signed-off-by: Helge Deller <deller@gmx.de>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Diffstat (limited to 'disas')
-rw-r--r-- | disas/hppa.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/disas/hppa.c b/disas/hppa.c index dcf9a47f34..cce4f4aa37 100644 --- a/disas/hppa.c +++ b/disas/hppa.c @@ -1968,6 +1968,10 @@ print_insn_hppa (bfd_vma memaddr, disassemble_info *info) insn = bfd_getb32 (buffer); + info->fprintf_func(info->stream, " %02x %02x %02x %02x ", + (insn >> 24) & 0xff, (insn >> 16) & 0xff, + (insn >> 8) & 0xff, insn & 0xff); + for (i = 0; i < NUMOPCODES; ++i) { const struct pa_opcode *opcode = &pa_opcodes[i]; @@ -2826,6 +2830,6 @@ print_insn_hppa (bfd_vma memaddr, disassemble_info *info) return sizeof (insn); } } - (*info->fprintf_func) (info->stream, "#%8x", insn); + info->fprintf_func(info->stream, "<unknown>"); return sizeof (insn); } |