Author: hbelusca Date: Sun Nov 3 23:13:53 2013 New Revision: 60857
URL: http://svn.reactos.org/svn/reactos?rev=60857&view=rev Log: [FAST486]: Code formatting only.
Modified: branches/ntvdm/lib/fast486/extraops.c branches/ntvdm/lib/fast486/opcodes.c branches/ntvdm/lib/fast486/opgroups.c
Modified: branches/ntvdm/lib/fast486/extraops.c URL: http://svn.reactos.org/svn/reactos/branches/ntvdm/lib/fast486/extraops.c?rev... ============================================================================== --- branches/ntvdm/lib/fast486/extraops.c [iso-8859-1] (original) +++ branches/ntvdm/lib/fast486/extraops.c [iso-8859-1] Sun Nov 3 23:13:53 2013 @@ -739,7 +739,7 @@ Result = Accumulator - Destination;
/* Update the flags */ - State->Flags.Cf = Accumulator < Destination; + State->Flags.Cf = (Accumulator < Destination); State->Flags.Of = ((Accumulator & SIGN_FLAG_BYTE) != (Destination & SIGN_FLAG_BYTE)) && ((Accumulator & SIGN_FLAG_BYTE) != (Result & SIGN_FLAG_BYTE)); State->Flags.Af = (Accumulator & 0x0F) < (Destination & 0x0F); @@ -795,7 +795,7 @@ Result = Accumulator - Destination;
/* Update the flags */ - State->Flags.Cf = Accumulator < Destination; + State->Flags.Cf = (Accumulator < Destination); State->Flags.Of = ((Accumulator & SIGN_FLAG_LONG) != (Destination & SIGN_FLAG_LONG)) && ((Accumulator & SIGN_FLAG_LONG) != (Result & SIGN_FLAG_LONG)); State->Flags.Af = (Accumulator & 0x0F) < (Destination & 0x0F); @@ -830,7 +830,7 @@ Result = Accumulator - Destination;
/* Update the flags */ - State->Flags.Cf = Accumulator < Destination; + State->Flags.Cf = (Accumulator < Destination); State->Flags.Of = ((Accumulator & SIGN_FLAG_WORD) != (Destination & SIGN_FLAG_WORD)) && ((Accumulator & SIGN_FLAG_WORD) != (Result & SIGN_FLAG_WORD)); State->Flags.Af = (Accumulator & 0x0F) < (Destination & 0x0F);
Modified: branches/ntvdm/lib/fast486/opcodes.c URL: http://svn.reactos.org/svn/reactos/branches/ntvdm/lib/fast486/opcodes.c?rev=... ============================================================================== --- branches/ntvdm/lib/fast486/opcodes.c [iso-8859-1] (original) +++ branches/ntvdm/lib/fast486/opcodes.c [iso-8859-1] Sun Nov 3 23:13:53 2013 @@ -3065,7 +3065,7 @@ Result = FirstValue - SecondValue;
/* Update the flags */ - State->Flags.Cf = FirstValue < SecondValue; + State->Flags.Cf = (FirstValue < SecondValue); State->Flags.Of = ((FirstValue & SIGN_FLAG_BYTE) != (SecondValue & SIGN_FLAG_BYTE)) && ((FirstValue & SIGN_FLAG_BYTE) != (Result & SIGN_FLAG_BYTE)); State->Flags.Af = (FirstValue & 0x0F) < (SecondValue & 0x0F); @@ -3134,7 +3134,7 @@ Result = FirstValue - SecondValue;
/* Update the flags */ - State->Flags.Cf = FirstValue < SecondValue; + State->Flags.Cf = (FirstValue < SecondValue); State->Flags.Of = ((FirstValue & SIGN_FLAG_LONG) != (SecondValue & SIGN_FLAG_LONG)) && ((FirstValue & SIGN_FLAG_LONG) != (Result & SIGN_FLAG_LONG)); State->Flags.Af = (FirstValue & 0x0F) < (SecondValue & 0x0F); @@ -3181,7 +3181,7 @@ Result = FirstValue - SecondValue;
/* Update the flags */ - State->Flags.Cf = FirstValue < SecondValue; + State->Flags.Cf = (FirstValue < SecondValue); State->Flags.Of = ((FirstValue & SIGN_FLAG_WORD) != (SecondValue & SIGN_FLAG_WORD)) && ((FirstValue & SIGN_FLAG_WORD) != (Result & SIGN_FLAG_WORD)); State->Flags.Af = (FirstValue & 0x0F) < (SecondValue & 0x0F); @@ -3231,7 +3231,7 @@ Result = FirstValue - SecondValue;
/* Update the flags */ - State->Flags.Cf = FirstValue < SecondValue; + State->Flags.Cf = (FirstValue < SecondValue); State->Flags.Of = ((FirstValue & SIGN_FLAG_BYTE) != (SecondValue & SIGN_FLAG_BYTE)) && ((FirstValue & SIGN_FLAG_BYTE) != (Result & SIGN_FLAG_BYTE)); State->Flags.Af = (FirstValue & 0x0F) < (SecondValue & 0x0F); @@ -3274,7 +3274,7 @@ Result = FirstValue - SecondValue;
/* Update the flags */ - State->Flags.Cf = FirstValue < SecondValue; + State->Flags.Cf = (FirstValue < SecondValue); State->Flags.Of = ((FirstValue & SIGN_FLAG_LONG) != (SecondValue & SIGN_FLAG_LONG)) && ((FirstValue & SIGN_FLAG_LONG) != (Result & SIGN_FLAG_LONG)); State->Flags.Af = (FirstValue & 0x0F) < (SecondValue & 0x0F); @@ -3304,7 +3304,7 @@ Result = FirstValue - SecondValue;
/* Update the flags */ - State->Flags.Cf = FirstValue < SecondValue; + State->Flags.Cf = (FirstValue < SecondValue); State->Flags.Of = ((FirstValue & SIGN_FLAG_WORD) != (SecondValue & SIGN_FLAG_WORD)) && ((FirstValue & SIGN_FLAG_WORD) != (Result & SIGN_FLAG_WORD)); State->Flags.Af = (FirstValue & 0x0F) < (SecondValue & 0x0F); @@ -5566,7 +5566,7 @@ Result = (FirstValue - SecondValue) & DataMask;
/* Update the flags */ - State->Flags.Cf = FirstValue < SecondValue; + State->Flags.Cf = (FirstValue < SecondValue); State->Flags.Of = ((FirstValue & SignFlag) != (SecondValue & SignFlag)) && ((FirstValue & SignFlag) != (Result & SignFlag)); State->Flags.Af = (FirstValue & 0x0F) < (SecondValue & 0x0F); @@ -5890,7 +5890,7 @@ Result = (FirstValue - SecondValue) & DataMask;
/* Update the flags */ - State->Flags.Cf = FirstValue < SecondValue; + State->Flags.Cf = (FirstValue < SecondValue); State->Flags.Of = ((FirstValue & SignFlag) != (SecondValue & SignFlag)) && ((FirstValue & SignFlag) != (Result & SignFlag)); State->Flags.Af = (FirstValue & 0x0F) < (SecondValue & 0x0F);
Modified: branches/ntvdm/lib/fast486/opgroups.c URL: http://svn.reactos.org/svn/reactos/branches/ntvdm/lib/fast486/opgroups.c?rev... ============================================================================== --- branches/ntvdm/lib/fast486/opgroups.c [iso-8859-1] (original) +++ branches/ntvdm/lib/fast486/opgroups.c [iso-8859-1] Sun Nov 3 23:13:53 2013 @@ -120,7 +120,7 @@ Result = (FirstValue - SecondValue) & MaxValue;
/* Update CF, OF and AF */ - State->Flags.Cf = FirstValue < SecondValue; + State->Flags.Cf = (FirstValue < SecondValue); State->Flags.Of = ((FirstValue & SignFlag) != (SecondValue & SignFlag)) && ((FirstValue & SignFlag) != (Result & SignFlag)); State->Flags.Af = (FirstValue & 0x0F) < (SecondValue & 0x0F); @@ -184,8 +184,8 @@
/* Update CF and OF */ State->Flags.Cf = Result & 1; - if (Count == 1) State->Flags.Of = ((Result & HighestBit) != 0) - ^ State->Flags.Cf; + if (Count == 1) State->Flags.Of = State->Flags.Cf + ^ ((Result & HighestBit) != 0);
break; } @@ -212,8 +212,8 @@
/* Update CF and OF */ State->Flags.Cf = ((Value & (1 << (Bits - Count))) != 0); - if (Count == 1) State->Flags.Of = ((Result & HighestBit) != 0) - ^ State->Flags.Cf; + if (Count == 1) State->Flags.Of = State->Flags.Cf + ^ ((Result & HighestBit) != 0);
break; } @@ -241,8 +241,8 @@
/* Update CF and OF */ State->Flags.Cf = ((Value & (1 << (Bits - Count))) != 0); - if (Count == 1) State->Flags.Of = ((Result & HighestBit) != 0) - ^ State->Flags.Cf; + if (Count == 1) State->Flags.Of = State->Flags.Cf + ^ ((Result & HighestBit) != 0);
break; } @@ -994,8 +994,7 @@ SHORT Result = (SHORT)((CHAR)Value) * (SHORT)((CHAR)State->GeneralRegs[FAST486_REG_EAX].LowByte);
/* Update the flags */ - State->Flags.Cf = State->Flags.Of = - ((Result < -128) || (Result > 127)); + State->Flags.Cf = State->Flags.Of = ((Result < -128) || (Result > 127));
/* Write back the result */ State->GeneralRegs[FAST486_REG_EAX].LowWord = (USHORT)Result; @@ -1166,8 +1165,7 @@ ULONGLONG Result = (ULONGLONG)Value * (ULONGLONG)State->GeneralRegs[FAST486_REG_EAX].Long;
/* Update the flags */ - State->Flags.Cf = State->Flags.Of = - ((Result & 0xFFFFFFFF00000000ULL) != 0); + State->Flags.Cf = State->Flags.Of = ((Result & 0xFFFFFFFF00000000ULL) != 0);
/* Write back the result */ State->GeneralRegs[FAST486_REG_EAX].Long = Result & 0xFFFFFFFFULL; @@ -1196,8 +1194,7 @@ LONGLONG Result = (LONGLONG)((LONG)Value) * (LONGLONG)((LONG)State->GeneralRegs[FAST486_REG_EAX].Long);
/* Update the flags */ - State->Flags.Cf = State->Flags.Of = - ((Result < -2147483648LL) || (Result > 2147483647LL)); + State->Flags.Cf = State->Flags.Of = ((Result < -2147483648LL) || (Result > 2147483647LL));
/* Write back the result */ State->GeneralRegs[FAST486_REG_EAX].Long = Result & 0xFFFFFFFFULL; @@ -1208,8 +1205,7 @@ LONG Result = (LONG)((SHORT)Value) * (LONG)((SHORT)State->GeneralRegs[FAST486_REG_EAX].LowWord);
/* Update the flags */ - State->Flags.Cf = State->Flags.Of = - ((Result < -32768) || (Result > 32767)); + State->Flags.Cf = State->Flags.Of = ((Result < -32768) || (Result > 32767));
/* Write back the result */ State->GeneralRegs[FAST486_REG_EAX].LowWord = LOWORD(Result);