|
@@ -5192,19 +5192,21 @@ print_insn_riscv(bfd_vma memaddr, struct disassemble_info *info, rv_isa isa)
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- switch (len) {
|
|
|
- case 2:
|
|
|
- (*info->fprintf_func)(info->stream, INST_FMT_2, inst);
|
|
|
- break;
|
|
|
- case 4:
|
|
|
- (*info->fprintf_func)(info->stream, INST_FMT_4, inst);
|
|
|
- break;
|
|
|
- case 6:
|
|
|
- (*info->fprintf_func)(info->stream, INST_FMT_6, inst);
|
|
|
- break;
|
|
|
- default:
|
|
|
- (*info->fprintf_func)(info->stream, INST_FMT_8, inst);
|
|
|
- break;
|
|
|
+ if (info->show_opcodes) {
|
|
|
+ switch (len) {
|
|
|
+ case 2:
|
|
|
+ (*info->fprintf_func)(info->stream, INST_FMT_2, inst);
|
|
|
+ break;
|
|
|
+ case 4:
|
|
|
+ (*info->fprintf_func)(info->stream, INST_FMT_4, inst);
|
|
|
+ break;
|
|
|
+ case 6:
|
|
|
+ (*info->fprintf_func)(info->stream, INST_FMT_6, inst);
|
|
|
+ break;
|
|
|
+ default:
|
|
|
+ (*info->fprintf_func)(info->stream, INST_FMT_8, inst);
|
|
|
+ break;
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
disasm_inst(buf, sizeof(buf), isa, memaddr, inst,
|