From 06ab2d99bb43afb091d928f4bced7e7eb5e017b3 Mon Sep 17 00:00:00 2001 From: Sjoerd van der Berg Date: Thu, 1 May 2003 18:06:20 +0000 Subject: [PATCH] Added VERR and VERW Added BSWAP Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@976 --- src/cpu/core_full/op.h | 10 ++++++++++ src/cpu/core_full/optable.h | 16 ++++++++-------- src/cpu/core_full/support.h | 1 + 3 files changed, 19 insertions(+), 8 deletions(-) diff --git a/src/cpu/core_full/op.h b/src/cpu/core_full/op.h index 7e6a7578..651c01ea 100644 --- a/src/cpu/core_full/op.h +++ b/src/cpu/core_full/op.h @@ -408,6 +408,13 @@ switch (inst.code.op) { case 0x03: /* LTR */ CPU_LTR(inst.op1.d); goto nextopcode; /* Else value will saved */ + case 0x04: /* VERR */ + CPU_VERR(inst.op1.d); + goto nextopcode; /* Else value will saved */ + case 0x05: /* VERW */ + CPU_VERW(inst.op1.d); + goto nextopcode; /* Else value will saved */ + default: LOG(LOG_ERROR|LOG_CPU,"Group 6 Illegal subfunction %X",inst.rm_index); @@ -528,6 +535,9 @@ switch (inst.code.op) { } } break; + case O_BSWAP: + BSWAP(inst.op1.d); + break; case 0: break; default: diff --git a/src/cpu/core_full/optable.h b/src/cpu/core_full/optable.h index 83bf1dcb..7999ef97 100644 --- a/src/cpu/core_full/optable.h +++ b/src/cpu/core_full/optable.h @@ -320,10 +320,10 @@ static OpCode OpCodeTable[1024]={ {0 ,0 ,0 ,0 },{0 ,0 ,0 ,0 }, {0 ,0 ,0 ,0 },{0 ,0 ,0 ,0 }, /* 0x1c8 - 0x1cf */ -{0 ,0 ,0 ,0 },{0 ,0 ,0 ,0 }, -{0 ,0 ,0 ,0 },{0 ,0 ,0 ,0 }, -{0 ,0 ,0 ,0 },{0 ,0 ,0 ,0 }, -{0 ,0 ,0 ,0 },{0 ,0 ,0 ,0 }, +{L_REGd ,O_BSWAP ,S_REGd ,REGI_AX},{L_REGd ,O_BSWAP ,S_REGd ,REGI_CX}, +{L_REGd ,O_BSWAP ,S_REGd ,REGI_DX},{L_REGd ,O_BSWAP ,S_REGd ,REGI_BX}, +{L_REGd ,O_BSWAP ,S_REGd ,REGI_SP},{L_REGd ,O_BSWAP ,S_REGd ,REGI_BP}, +{L_REGd ,O_BSWAP ,S_REGd ,REGI_SI},{L_REGd ,O_BSWAP ,S_REGd ,REGI_DI}, /* 0x1d0 - 0x1d7 */ {0 ,0 ,0 ,0 },{0 ,0 ,0 ,0 }, @@ -678,10 +678,10 @@ static OpCode OpCodeTable[1024]={ {0 ,0 ,0 ,0 },{0 ,0 ,0 ,0 }, {0 ,0 ,0 ,0 },{0 ,0 ,0 ,0 }, /* 0x3c8 - 0x3cf */ -{0 ,0 ,0 ,0 },{0 ,0 ,0 ,0 }, -{0 ,0 ,0 ,0 },{0 ,0 ,0 ,0 }, -{0 ,0 ,0 ,0 },{0 ,0 ,0 ,0 }, -{0 ,0 ,0 ,0 },{0 ,0 ,0 ,0 }, +{L_REGd ,O_BSWAP ,S_REGd ,REGI_AX},{L_REGd ,O_BSWAP ,S_REGd ,REGI_CX}, +{L_REGd ,O_BSWAP ,S_REGd ,REGI_DX},{L_REGd ,O_BSWAP ,S_REGd ,REGI_BX}, +{L_REGd ,O_BSWAP ,S_REGd ,REGI_SP},{L_REGd ,O_BSWAP ,S_REGd ,REGI_BP}, +{L_REGd ,O_BSWAP ,S_REGd ,REGI_SI},{L_REGd ,O_BSWAP ,S_REGd ,REGI_DI}, /* 0x3d0 - 0x3d7 */ {0 ,0 ,0 ,0 },{0 ,0 ,0 ,0 }, diff --git a/src/cpu/core_full/support.h b/src/cpu/core_full/support.h index 995f56c1..abaa6143 100644 --- a/src/cpu/core_full/support.h +++ b/src/cpu/core_full/support.h @@ -89,6 +89,7 @@ enum { O_BTd,O_BTSd,O_BTRd,O_BTCd, O_BSFw,O_BSRw, + O_BSWAP, };