public static void PerformFromRInMAssignmentOperation(LM1 machine) { machine.SetVariableInMemory(machine.GetAddressOperand(machine.currentAddress, 2), machine.GetCpuMemoryCell(machine.GetAddressOperand(machine.currentAddress, 1))); machine.GoToNextAddress(); }
public static void PerformRMRRAssignmentOperation(LM1 machine) { machine.SetCpuMemoryCell(machine.GetAddressOperand(machine.currentAddress, 1), machine.GetValueOperand(machine.currentAddress, 2)); machine.GoToNextAddress(); }
public static void PerformComparisonOperation(LM1 machine, ComparisonFlag flag) { machine.currentAddress = comparisonOperations[flag] ? machine.GetTransitAddress() : machine.currentAddress += 2; for (int i = 0; i < comparisonOperations.Count; i++) { comparisonOperations[(ComparisonFlag)i] = false; } }
public static void PerformGoToOperation(LM1 machine) { machine.currentAddress = machine.GetTransitAddress(); }