diff options
Diffstat (limited to 'qtmips_machine/instruction.cpp')
-rw-r--r-- | qtmips_machine/instruction.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/qtmips_machine/instruction.cpp b/qtmips_machine/instruction.cpp index 030b79f..70247bd 100644 --- a/qtmips_machine/instruction.cpp +++ b/qtmips_machine/instruction.cpp @@ -223,7 +223,7 @@ static const struct InstructionMap special3_instruction_map[] = { IM_UNKNOWN, // 57 IM_UNKNOWN, // 58 {"RDHWR", IT_R, ALU_OP_NOP, NOMEM, nullptr, - .flags = FLAGS_ALU_T_R_TD}, + .flags = IMF_SUPPORTED | IMF_REGWRITE}, IM_UNKNOWN, // 60 IM_UNKNOWN, // 61 IM_UNKNOWN, // 62 @@ -606,6 +606,10 @@ QString Instruction::to_str(std::int32_t inst_addr) const { next_delim = ", "; } } + if ((im.flags & IMF_REGWRITE) && !(im.flags & IMF_REGD)) { + res += next_delim + "$" + QString::number(rd()); + next_delim = ", "; + } break; } case T_UNKNOWN: |