From 35eeb78fa9535df6a273c053d8f102e046261b89 Mon Sep 17 00:00:00 2001 From: Jim Wilson Date: Fri, 5 Jan 2018 17:51:23 -0800 Subject: RISC-V: Print symbol address for jalr w/ zero offset. ld/ * testsuite/ld-riscv-elf/disas-jalr.d: New. * testsuite/ld-riscv-elf/disas-jalr.s: New. * testsuite/ld-riscv-elf/ld-riscv-elf.exp: Run new testcase. opcodes/ * riscv-dis.c (print_insn_args) <'s'>: Call maybe_print_address for a jalr. --- opcodes/riscv-dis.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'opcodes/riscv-dis.c') diff --git a/opcodes/riscv-dis.c b/opcodes/riscv-dis.c index 972cbcf..cc427b4 100644 --- a/opcodes/riscv-dis.c +++ b/opcodes/riscv-dis.c @@ -226,6 +226,8 @@ print_insn_args (const char *d, insn_t l, bfd_vma pc, disassemble_info *info) case 'b': case 's': + if ((l & MASK_JALR) == MATCH_JALR) + maybe_print_address (pd, rs1, 0); print (info->stream, "%s", riscv_gpr_names[rs1]); break; -- cgit v1.1