0
mirror of https://github.com/sampletext32/ParkanPlayground.git synced 2025-06-19 16:08:02 +03:00

Fixed operand order in MOV instructions and updated tests to match disassembler output

This commit is contained in:
bird_egop
2025-04-13 03:56:09 +03:00
parent b2929c38e9
commit 611dce32e5
5 changed files with 16 additions and 57 deletions

View File

@ -58,11 +58,11 @@ public class MovMemRegHandler : InstructionHandler
if (mod == 3)
{
string rmRegName = ModRMDecoder.GetRegisterName(rm, operandSize);
instruction.Operands = $"{regName}, {rmRegName}";
instruction.Operands = $"{rmRegName}, {regName}";
}
else // Memory operand
{
instruction.Operands = $"{regName}, {memOperand}";
instruction.Operands = $"{memOperand}, {regName}";
}
return true;