Author: aandrejevic
Date: Thu Nov 14 02:54:20 2013
New Revision: 60988

URL: http://svn.reactos.org/svn/reactos?rev=60988&view=rev
Log:
[FAST486]
Update the register values in REP LODS.


Modified:
    branches/ntvdm/lib/fast486/opcodes.c

Modified: branches/ntvdm/lib/fast486/opcodes.c
URL: 
http://svn.reactos.org/svn/reactos/branches/ntvdm/lib/fast486/opcodes.c?rev=60988&r1=60987&r2=60988&view=diff
==============================================================================
--- branches/ntvdm/lib/fast486/opcodes.c        [iso-8859-1] (original)
+++ branches/ntvdm/lib/fast486/opcodes.c        [iso-8859-1] Thu Nov 14 
02:54:20 2013
@@ -5885,6 +5885,18 @@
             if (AddressSize) State->GeneralRegs[FAST486_REG_ESI].Long -= 
(Count - 1) * DataSize;
             else State->GeneralRegs[FAST486_REG_ESI].LowWord -= (Count - 1) * 
DataSize;
         }
+
+        /* Update registers */
+        if (OperandSize)
+        {
+            State->GeneralRegs[FAST486_REG_ECX].Long = 0;
+            State->GeneralRegs[FAST486_REG_ESI].Long += Count - 1;
+        }
+        else
+        {
+            State->GeneralRegs[FAST486_REG_ECX].LowWord = 0;
+            State->GeneralRegs[FAST486_REG_ESI].LowWord += Count - 1;
+        }
     }
 
     /* Read from the source operand */


Reply via email to