Author: aandrejevic
Date: Tue May 12 20:08:39 2015
New Revision: 67702
URL:
http://svn.reactos.org/svn/reactos?rev=67702&view=rev
Log:
[FAST486]
Superfluous prefixes don't usually generate #UD, except for LOCK.
Modified:
trunk/reactos/lib/fast486/opcodes.c
Modified: trunk/reactos/lib/fast486/opcodes.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/lib/fast486/opcodes.c?rev=…
==============================================================================
--- trunk/reactos/lib/fast486/opcodes.c [iso-8859-1] (original)
+++ trunk/reactos/lib/fast486/opcodes.c [iso-8859-1] Tue May 12 20:08:39 2015
@@ -1046,12 +1046,7 @@
/* Make sure this is the right instruction */
ASSERT((Opcode & 0xF8) == 0xB0);
- if (State->PrefixFlags != 0)
- {
- /* Invalid prefix */
- Fast486Exception(State, FAST486_EXCEPTION_UD);
- return;
- }
+ NO_LOCK_PREFIX();
/* Fetch the byte */
if (!Fast486FetchByte(State, &Value))
@@ -1211,12 +1206,7 @@
/* Make sure this is the right instruction */
ASSERT(Opcode == 0x04);
- if (State->PrefixFlags)
- {
- /* This opcode doesn't take any prefixes */
- Fast486Exception(State, FAST486_EXCEPTION_UD);
- return;
- }
+ NO_LOCK_PREFIX();
if (!Fast486FetchByte(State, &SecondValue))
{
@@ -1437,12 +1427,7 @@
/* Make sure this is the right instruction */
ASSERT(Opcode == 0x0C);
- if (State->PrefixFlags)
- {
- /* This opcode doesn't take any prefixes */
- Fast486Exception(State, FAST486_EXCEPTION_UD);
- return;
- }
+ NO_LOCK_PREFIX();
if (!Fast486FetchByte(State, &SecondValue))
{
@@ -1872,12 +1857,7 @@
/* Make sure this is the right instruction */
ASSERT(Opcode == 0x34);
- if (State->PrefixFlags)
- {
- /* This opcode doesn't take any prefixes */
- Fast486Exception(State, FAST486_EXCEPTION_UD);
- return;
- }
+ NO_LOCK_PREFIX();
if (!Fast486FetchByte(State, &SecondValue))
{
@@ -2073,12 +2053,7 @@
/* Make sure this is the right instruction */
ASSERT(Opcode == 0xA8);
- if (State->PrefixFlags)
- {
- /* This opcode doesn't take any prefixes */
- Fast486Exception(State, FAST486_EXCEPTION_UD);
- return;
- }
+ NO_LOCK_PREFIX();
if (!Fast486FetchByte(State, &SecondValue))
{
@@ -2454,12 +2429,7 @@
/* Make sure this is the right instruction */
ASSERT(Opcode == 0x14);
- if (State->PrefixFlags)
- {
- /* This opcode doesn't take any prefixes */
- Fast486Exception(State, FAST486_EXCEPTION_UD);
- return;
- }
+ NO_LOCK_PREFIX();
if (!Fast486FetchByte(State, &SecondValue))
{
@@ -2746,12 +2716,7 @@
/* Make sure this is the right instruction */
ASSERT(Opcode == 0x1C);
- if (State->PrefixFlags)
- {
- /* This opcode doesn't take any prefixes */
- Fast486Exception(State, FAST486_EXCEPTION_UD);
- return;
- }
+ NO_LOCK_PREFIX();
if (!Fast486FetchByte(State, &SecondValue))
{
@@ -3073,12 +3038,7 @@
/* Make sure this is the right instruction */
ASSERT((Opcode & 0xEF) == 0x2C);
- if (State->PrefixFlags)
- {
- /* This opcode doesn't take any prefixes */
- Fast486Exception(State, FAST486_EXCEPTION_UD);
- return;
- }
+ NO_LOCK_PREFIX();
if (!Fast486FetchByte(State, &SecondValue))
{