fixed more missing functions
This commit is contained in:
3
Makefile
3
Makefile
@@ -116,13 +116,14 @@ CSRCS= \
|
||||
radeon_cursor.c \
|
||||
radeon_monitor.c \
|
||||
\
|
||||
biosemu.c \
|
||||
decode.c \
|
||||
sys.c \
|
||||
debug.c \
|
||||
prim_ops.c \
|
||||
ops.c \
|
||||
ops2.c \
|
||||
fpu.c \
|
||||
biosemu.c \
|
||||
x86pcibios.c \
|
||||
\
|
||||
basflash.c \
|
||||
|
||||
@@ -86,11 +86,12 @@ SECTIONS
|
||||
OBJDIR/fbmodedb.o
|
||||
OBJDIR/offscreen.o
|
||||
|
||||
OBJDIR/biosemu.o
|
||||
OBJDIR/decode.o
|
||||
OBJDIR/ops.o
|
||||
OBJDIR/ops2.o
|
||||
OBJDIR/fpu.o
|
||||
OBJDIR/sys.o
|
||||
OBJDIR/biosemu.o
|
||||
OBJDIR/debug.o
|
||||
OBJDIR/prim_ops.o
|
||||
OBJDIR/x86pcibios.o
|
||||
|
||||
@@ -99,7 +99,7 @@ int run_bios_int(int num)
|
||||
return 1;
|
||||
}
|
||||
|
||||
static uint8_t inb(uint16_t port)
|
||||
uint8_t inb(uint16_t port)
|
||||
{
|
||||
uint8_t val = 0;
|
||||
|
||||
@@ -113,7 +113,7 @@ static uint8_t inb(uint16_t port)
|
||||
return val;
|
||||
}
|
||||
|
||||
static uint16_t inw(uint16_t port)
|
||||
uint16_t inw(uint16_t port)
|
||||
{
|
||||
uint16_t val = 0;
|
||||
|
||||
@@ -126,7 +126,7 @@ static uint16_t inw(uint16_t port)
|
||||
return val;
|
||||
}
|
||||
|
||||
static uint32_t inl(uint16_t port)
|
||||
uint32_t inl(uint16_t port)
|
||||
{
|
||||
uint32_t val = 0;
|
||||
if ((port >= offset_port) && (port <= offset_port+0xFF))
|
||||
|
||||
@@ -176,26 +176,27 @@ void x86emu_decode_printf2 (char *x, int y)
|
||||
{
|
||||
char temp[100], *p;
|
||||
|
||||
doprnt(xaddchar, x, y);
|
||||
#ifdef DBG_X86EMU
|
||||
{
|
||||
p = temp;
|
||||
while(x[0] != 0)
|
||||
while (x[0] != 0)
|
||||
{
|
||||
if(x[0]=='%' && x[1]=='d')
|
||||
if (x[0] =='%' && x[1] =='d')
|
||||
{
|
||||
x+=2;
|
||||
x += 2;
|
||||
Funcs_ltoa(p, y, 10);
|
||||
while(p[0] != 0)
|
||||
while (p[0] != 0)
|
||||
p++;
|
||||
}
|
||||
else if(x[0]=='%' && x[1]=='x')
|
||||
else if (x[0]=='%' && x[1]=='x')
|
||||
{
|
||||
x+=2;
|
||||
x += 2;
|
||||
*p++ = '0';
|
||||
*p++ = 'x';
|
||||
y &= 0xffff;
|
||||
Funcs_ltoa(p, y, 16);
|
||||
while(p[0] != 0)
|
||||
while (p[0] != 0)
|
||||
p++;
|
||||
}
|
||||
else
|
||||
@@ -376,7 +377,7 @@ static int parse_line (char *s, int *ps, int *n)
|
||||
int cmd;
|
||||
|
||||
*n = 0;
|
||||
while(*s == ' ' || *s == '\t') s++;
|
||||
while (*s == ' ' || *s == '\t') s++;
|
||||
ps[*n] = *s;
|
||||
switch (*s) {
|
||||
case '\n':
|
||||
@@ -393,7 +394,7 @@ static int parse_line (char *s, int *ps, int *n)
|
||||
if (*s == '\n')
|
||||
return cmd;
|
||||
|
||||
while(*s == ' ' || *s == '\t') s++;
|
||||
while (*s == ' ' || *s == '\t') s++;
|
||||
|
||||
sscanf(s,"%x",&ps[*n]);
|
||||
*n += 1;
|
||||
|
||||
946
x86emu/ops.c
946
x86emu/ops.c
File diff suppressed because it is too large
Load Diff
656
x86emu/ops2.c
656
x86emu/ops2.c
@@ -1,42 +1,42 @@
|
||||
/****************************************************************************
|
||||
*
|
||||
* Realmode X86 Emulator Library
|
||||
*
|
||||
* Copyright (C) 1991-2004 SciTech Software, Inc.
|
||||
* Copyright (C) David Mosberger-Tang
|
||||
* Copyright (C) 1999 Egbert Eich
|
||||
*
|
||||
* ========================================================================
|
||||
*
|
||||
* Permission to use, copy, modify, distribute, and sell this software and
|
||||
* its documentation for any purpose is hereby granted without fee,
|
||||
* provided that the above copyright notice appear in all copies and that
|
||||
* both that copyright notice and this permission notice appear in
|
||||
* supporting documentation, and that the name of the authors not be used
|
||||
* in advertising or publicity pertaining to distribution of the software
|
||||
* without specific, written prior permission. The authors makes no
|
||||
* representations about the suitability of this software for any purpose.
|
||||
* It is provided "as is" without express or implied warranty.
|
||||
*
|
||||
* THE AUTHORS DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
|
||||
* INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
|
||||
* EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL, INDIRECT OR
|
||||
* CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF
|
||||
* USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
||||
* OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
||||
* PERFORMANCE OF THIS SOFTWARE.
|
||||
*
|
||||
* ========================================================================
|
||||
*
|
||||
* Language: ANSI C
|
||||
* Environment: Any
|
||||
* Developer: Kendall Bennett
|
||||
*
|
||||
* Description: This file includes subroutines to implement the decoding
|
||||
* and emulation of all the x86 extended two-byte processor
|
||||
* instructions.
|
||||
*
|
||||
****************************************************************************/
|
||||
*
|
||||
* Realmode X86 Emulator Library
|
||||
*
|
||||
* Copyright (C) 1991-2004 SciTech Software, Inc.
|
||||
* Copyright (C) David Mosberger-Tang
|
||||
* Copyright (C) 1999 Egbert Eich
|
||||
*
|
||||
* ========================================================================
|
||||
*
|
||||
* Permission to use, copy, modify, distribute, and sell this software and
|
||||
* its documentation for any purpose is hereby granted without fee,
|
||||
* provided that the above copyright notice appear in all copies and that
|
||||
* both that copyright notice and this permission notice appear in
|
||||
* supporting documentation, and that the name of the authors not be used
|
||||
* in advertising or publicity pertaining to distribution of the software
|
||||
* without specific, written prior permission. The authors makes no
|
||||
* representations about the suitability of this software for any purpose.
|
||||
* It is provided "as is" without express or implied warranty.
|
||||
*
|
||||
* THE AUTHORS DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
|
||||
* INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
|
||||
* EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL, INDIRECT OR
|
||||
* CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF
|
||||
* USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
||||
* OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
||||
* PERFORMANCE OF THIS SOFTWARE.
|
||||
*
|
||||
* ========================================================================
|
||||
*
|
||||
* Language: ANSI C
|
||||
* Environment: Any
|
||||
* Developer: Kendall Bennett
|
||||
*
|
||||
* Description: This file includes subroutines to implement the decoding
|
||||
* and emulation of all the x86 extended two-byte processor
|
||||
* instructions.
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
#include "x86debug.h"
|
||||
#include "x86emui.h"
|
||||
@@ -51,17 +51,15 @@ op1 - Instruction op code
|
||||
|
||||
REMARKS:
|
||||
Handles illegal opcodes.
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_illegal_op(
|
||||
uint8_t op2)
|
||||
{
|
||||
START_OF_INSTR();
|
||||
DECODE_PRINTF("ILLEGAL EXTENDED X86 OPCODE\r\n");
|
||||
TRACE_REGS();
|
||||
DPRINTVALHEXWORD("", M.x86.R_CS);
|
||||
DPRINTVALHEXWORD(":", M.x86.R_IP-2);
|
||||
DPRINTVALHEXBYTE(": ", op2);
|
||||
DPRINT(" ILLEGAL EXTENDED X86 OPCODE!\r\n");
|
||||
dbg("%x:%x: %x", M.x86.R_CS, M.x86.R_IP - 2, op2);
|
||||
dbg(" ILLEGAL EXTENDED X86 OPCODE!\r\n");
|
||||
HALT_SYS();
|
||||
END_OF_INSTR();
|
||||
}
|
||||
@@ -71,7 +69,7 @@ void x86emuOp2_illegal_op(
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0x80-0x8F
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
int x86emu_check_jump_condition(uint8_t op)
|
||||
{
|
||||
switch (op) {
|
||||
@@ -163,7 +161,7 @@ void x86emuOp2_long_jump(uint8_t op2)
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0x90-0x9F
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_set_byte(uint8_t op2)
|
||||
{
|
||||
int mod, rl, rh;
|
||||
@@ -259,7 +257,7 @@ void x86emuOp2_set_byte(uint8_t op2)
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0xa0
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_push_FS(uint8_t X86EMU_UNUSED(op2))
|
||||
{
|
||||
START_OF_INSTR();
|
||||
@@ -273,7 +271,7 @@ void x86emuOp2_push_FS(uint8_t X86EMU_UNUSED(op2))
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0xa1
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_pop_FS(uint8_t X86EMU_UNUSED(op2))
|
||||
{
|
||||
START_OF_INSTR();
|
||||
@@ -287,7 +285,7 @@ void x86emuOp2_pop_FS(uint8_t X86EMU_UNUSED(op2))
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0xa3
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_bt_R(uint8_t X86EMU_UNUSED(op2))
|
||||
{
|
||||
int mod, rl, rh;
|
||||
@@ -350,7 +348,7 @@ void x86emuOp2_bt_R(uint8_t X86EMU_UNUSED(op2))
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0xa4
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_shld_IMM(uint8_t X86EMU_UNUSED(op2))
|
||||
{
|
||||
int mod, rl, rh;
|
||||
@@ -421,7 +419,7 @@ void x86emuOp2_shld_IMM(uint8_t X86EMU_UNUSED(op2))
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0xa5
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_shld_CL(uint8_t X86EMU_UNUSED(op2))
|
||||
{
|
||||
int mod, rl, rh;
|
||||
@@ -483,7 +481,7 @@ void x86emuOp2_shld_CL(uint8_t X86EMU_UNUSED(op2))
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0xa8
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_push_GS(uint8_t X86EMU_UNUSED(op2))
|
||||
{
|
||||
START_OF_INSTR();
|
||||
@@ -497,7 +495,7 @@ void x86emuOp2_push_GS(uint8_t X86EMU_UNUSED(op2))
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0xa9
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_pop_GS(uint8_t X86EMU_UNUSED(op2))
|
||||
{
|
||||
START_OF_INSTR();
|
||||
@@ -511,7 +509,7 @@ void x86emuOp2_pop_GS(uint8_t X86EMU_UNUSED(op2))
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0xaa
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_bts_R(uint8_t X86EMU_UNUSED(op2))
|
||||
{
|
||||
int mod, rl, rh;
|
||||
@@ -584,7 +582,7 @@ void x86emuOp2_bts_R(uint8_t X86EMU_UNUSED(op2))
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0xac
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_shrd_IMM(uint8_t X86EMU_UNUSED(op2))
|
||||
{
|
||||
int mod, rl, rh;
|
||||
@@ -655,7 +653,7 @@ void x86emuOp2_shrd_IMM(uint8_t X86EMU_UNUSED(op2))
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0xad
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_shrd_CL(uint8_t X86EMU_UNUSED(op2))
|
||||
{
|
||||
int mod, rl, rh;
|
||||
@@ -716,7 +714,7 @@ void x86emuOp2_shrd_CL(uint8_t X86EMU_UNUSED(op2))
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0xaf
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_imul_R_RM(uint8_t X86EMU_UNUSED(op2))
|
||||
{
|
||||
int mod, rl, rh;
|
||||
@@ -808,7 +806,7 @@ void x86emuOp2_imul_R_RM(uint8_t X86EMU_UNUSED(op2))
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0xb2
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_lss_R_IMM(uint8_t X86EMU_UNUSED(op2))
|
||||
{
|
||||
int mod, rh, rl;
|
||||
@@ -837,7 +835,7 @@ void x86emuOp2_lss_R_IMM(uint8_t X86EMU_UNUSED(op2))
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0xb3
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_btr_R(uint8_t X86EMU_UNUSED(op2))
|
||||
{
|
||||
int mod, rl, rh;
|
||||
@@ -909,7 +907,7 @@ void x86emuOp2_btr_R(uint8_t X86EMU_UNUSED(op2))
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0xb4
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_lfs_R_IMM(uint8_t X86EMU_UNUSED(op2))
|
||||
{
|
||||
int mod, rh, rl;
|
||||
@@ -938,7 +936,7 @@ void x86emuOp2_lfs_R_IMM(uint8_t X86EMU_UNUSED(op2))
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0xb5
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_lgs_R_IMM(uint8_t X86EMU_UNUSED(op2))
|
||||
{
|
||||
int mod, rh, rl;
|
||||
@@ -967,7 +965,7 @@ void x86emuOp2_lgs_R_IMM(uint8_t X86EMU_UNUSED(op2))
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0xb6
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_movzx_byte_R_RM(uint8_t X86EMU_UNUSED(op2))
|
||||
{
|
||||
int mod, rl, rh;
|
||||
@@ -1030,7 +1028,7 @@ void x86emuOp2_movzx_byte_R_RM(uint8_t X86EMU_UNUSED(op2))
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0xb7
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_movzx_word_R_RM(uint8_t X86EMU_UNUSED(op2))
|
||||
{
|
||||
int mod, rl, rh;
|
||||
@@ -1065,7 +1063,7 @@ void x86emuOp2_movzx_word_R_RM(uint8_t X86EMU_UNUSED(op2))
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0xba
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_btX_I(uint8_t X86EMU_UNUSED(op2))
|
||||
{
|
||||
int mod, rl, rh;
|
||||
@@ -1089,13 +1087,11 @@ void x86emuOp2_btX_I(uint8_t X86EMU_UNUSED(op2))
|
||||
DECODE_PRINTF("BTC\t");
|
||||
break;
|
||||
default:
|
||||
DECODE_PRINTF("ILLEGAL EXTENDED X86 OPCODE\n");
|
||||
dbg("ILLEGAL EXTENDED X86 OPCODE\n");
|
||||
TRACE_REGS();
|
||||
DPRINTVALHEXWORD("", M.x86.R_CS);
|
||||
DPRINTVALHEXWORD(":", M.x86.R_IP-3);
|
||||
DPRINTVALHEXBYTE(": ", op2);
|
||||
DPRINTVALHEXBYTE("", (mod<<6)|(rh<<3)|rl);
|
||||
DPRINT(" ILLEGAL EXTENDED X86 OPCODE EXTENSION!\r\n");
|
||||
dbg("%x:%x: %x", M.x86.R_CS, M.x86.R_IP - 3, op2);
|
||||
dbg(" %x", (mod << 6) | (rh << 3) | rl);
|
||||
dbg(" ILLEGAL EXTENDED X86 OPCODE EXTENSION!\r\n");
|
||||
HALT_SYS();
|
||||
}
|
||||
if (mod < 3) {
|
||||
@@ -1204,7 +1200,7 @@ void x86emuOp2_btX_I(uint8_t X86EMU_UNUSED(op2))
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0xbb
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_btc_R(uint8_t X86EMU_UNUSED(op2))
|
||||
{
|
||||
int mod, rl, rh;
|
||||
@@ -1276,7 +1272,7 @@ void x86emuOp2_btc_R(uint8_t X86EMU_UNUSED(op2))
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0xbc
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_bsf(uint8_t X86EMU_UNUSED(op2))
|
||||
{
|
||||
int mod, rl, rh;
|
||||
@@ -1337,7 +1333,7 @@ void x86emuOp2_bsf(uint8_t X86EMU_UNUSED(op2))
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0xbd
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_bsr(uint8_t X86EMU_UNUSED(op2))
|
||||
{
|
||||
int mod, rl, rh;
|
||||
@@ -1398,7 +1394,7 @@ void x86emuOp2_bsr(uint8_t X86EMU_UNUSED(op2))
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0xbe
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_movsx_byte_R_RM(uint8_t X86EMU_UNUSED(op2))
|
||||
{
|
||||
int mod, rl, rh;
|
||||
@@ -1461,7 +1457,7 @@ void x86emuOp2_movsx_byte_R_RM(uint8_t X86EMU_UNUSED(op2))
|
||||
/****************************************************************************
|
||||
REMARKS:
|
||||
Handles opcode 0x0f,0xbf
|
||||
****************************************************************************/
|
||||
****************************************************************************/
|
||||
void x86emuOp2_movsx_word_R_RM(uint8_t X86EMU_UNUSED(op2))
|
||||
{
|
||||
int mod, rl, rh;
|
||||
@@ -1498,275 +1494,275 @@ void x86emuOp2_movsx_word_R_RM(uint8_t X86EMU_UNUSED(op2))
|
||||
**************************************************************************/
|
||||
void (*x86emu_optab2[256])(uint8_t) =
|
||||
{
|
||||
/* 0x00 */ x86emuOp2_illegal_op, /* Group F (ring 0 PM) */
|
||||
/* 0x01 */ x86emuOp2_illegal_op, /* Group G (ring 0 PM) */
|
||||
/* 0x02 */ x86emuOp2_illegal_op, /* lar (ring 0 PM) */
|
||||
/* 0x03 */ x86emuOp2_illegal_op, /* lsl (ring 0 PM) */
|
||||
/* 0x04 */ x86emuOp2_illegal_op,
|
||||
/* 0x05 */ x86emuOp2_illegal_op, /* loadall (undocumented) */
|
||||
/* 0x06 */ x86emuOp2_illegal_op, /* clts (ring 0 PM) */
|
||||
/* 0x07 */ x86emuOp2_illegal_op, /* loadall (undocumented) */
|
||||
/* 0x08 */ x86emuOp2_illegal_op, /* invd (ring 0 PM) */
|
||||
/* 0x09 */ x86emuOp2_illegal_op, /* wbinvd (ring 0 PM) */
|
||||
/* 0x0a */ x86emuOp2_illegal_op,
|
||||
/* 0x0b */ x86emuOp2_illegal_op,
|
||||
/* 0x0c */ x86emuOp2_illegal_op,
|
||||
/* 0x0d */ x86emuOp2_illegal_op,
|
||||
/* 0x0e */ x86emuOp2_illegal_op,
|
||||
/* 0x0f */ x86emuOp2_illegal_op,
|
||||
/* 0x00 */ x86emuOp2_illegal_op, /* Group F (ring 0 PM) */
|
||||
/* 0x01 */ x86emuOp2_illegal_op, /* Group G (ring 0 PM) */
|
||||
/* 0x02 */ x86emuOp2_illegal_op, /* lar (ring 0 PM) */
|
||||
/* 0x03 */ x86emuOp2_illegal_op, /* lsl (ring 0 PM) */
|
||||
/* 0x04 */ x86emuOp2_illegal_op,
|
||||
/* 0x05 */ x86emuOp2_illegal_op, /* loadall (undocumented) */
|
||||
/* 0x06 */ x86emuOp2_illegal_op, /* clts (ring 0 PM) */
|
||||
/* 0x07 */ x86emuOp2_illegal_op, /* loadall (undocumented) */
|
||||
/* 0x08 */ x86emuOp2_illegal_op, /* invd (ring 0 PM) */
|
||||
/* 0x09 */ x86emuOp2_illegal_op, /* wbinvd (ring 0 PM) */
|
||||
/* 0x0a */ x86emuOp2_illegal_op,
|
||||
/* 0x0b */ x86emuOp2_illegal_op,
|
||||
/* 0x0c */ x86emuOp2_illegal_op,
|
||||
/* 0x0d */ x86emuOp2_illegal_op,
|
||||
/* 0x0e */ x86emuOp2_illegal_op,
|
||||
/* 0x0f */ x86emuOp2_illegal_op,
|
||||
|
||||
/* 0x10 */ x86emuOp2_illegal_op,
|
||||
/* 0x11 */ x86emuOp2_illegal_op,
|
||||
/* 0x12 */ x86emuOp2_illegal_op,
|
||||
/* 0x13 */ x86emuOp2_illegal_op,
|
||||
/* 0x14 */ x86emuOp2_illegal_op,
|
||||
/* 0x15 */ x86emuOp2_illegal_op,
|
||||
/* 0x16 */ x86emuOp2_illegal_op,
|
||||
/* 0x17 */ x86emuOp2_illegal_op,
|
||||
/* 0x18 */ x86emuOp2_illegal_op,
|
||||
/* 0x19 */ x86emuOp2_illegal_op,
|
||||
/* 0x1a */ x86emuOp2_illegal_op,
|
||||
/* 0x1b */ x86emuOp2_illegal_op,
|
||||
/* 0x1c */ x86emuOp2_illegal_op,
|
||||
/* 0x1d */ x86emuOp2_illegal_op,
|
||||
/* 0x1e */ x86emuOp2_illegal_op,
|
||||
/* 0x1f */ x86emuOp2_illegal_op,
|
||||
/* 0x10 */ x86emuOp2_illegal_op,
|
||||
/* 0x11 */ x86emuOp2_illegal_op,
|
||||
/* 0x12 */ x86emuOp2_illegal_op,
|
||||
/* 0x13 */ x86emuOp2_illegal_op,
|
||||
/* 0x14 */ x86emuOp2_illegal_op,
|
||||
/* 0x15 */ x86emuOp2_illegal_op,
|
||||
/* 0x16 */ x86emuOp2_illegal_op,
|
||||
/* 0x17 */ x86emuOp2_illegal_op,
|
||||
/* 0x18 */ x86emuOp2_illegal_op,
|
||||
/* 0x19 */ x86emuOp2_illegal_op,
|
||||
/* 0x1a */ x86emuOp2_illegal_op,
|
||||
/* 0x1b */ x86emuOp2_illegal_op,
|
||||
/* 0x1c */ x86emuOp2_illegal_op,
|
||||
/* 0x1d */ x86emuOp2_illegal_op,
|
||||
/* 0x1e */ x86emuOp2_illegal_op,
|
||||
/* 0x1f */ x86emuOp2_illegal_op,
|
||||
|
||||
/* 0x20 */ x86emuOp2_illegal_op, /* mov reg32,creg (ring 0 PM) */
|
||||
/* 0x21 */ x86emuOp2_illegal_op, /* mov reg32,dreg (ring 0 PM) */
|
||||
/* 0x22 */ x86emuOp2_illegal_op, /* mov creg,reg32 (ring 0 PM) */
|
||||
/* 0x23 */ x86emuOp2_illegal_op, /* mov dreg,reg32 (ring 0 PM) */
|
||||
/* 0x24 */ x86emuOp2_illegal_op, /* mov reg32,treg (ring 0 PM) */
|
||||
/* 0x25 */ x86emuOp2_illegal_op,
|
||||
/* 0x26 */ x86emuOp2_illegal_op, /* mov treg,reg32 (ring 0 PM) */
|
||||
/* 0x27 */ x86emuOp2_illegal_op,
|
||||
/* 0x28 */ x86emuOp2_illegal_op,
|
||||
/* 0x29 */ x86emuOp2_illegal_op,
|
||||
/* 0x2a */ x86emuOp2_illegal_op,
|
||||
/* 0x2b */ x86emuOp2_illegal_op,
|
||||
/* 0x2c */ x86emuOp2_illegal_op,
|
||||
/* 0x2d */ x86emuOp2_illegal_op,
|
||||
/* 0x2e */ x86emuOp2_illegal_op,
|
||||
/* 0x2f */ x86emuOp2_illegal_op,
|
||||
/* 0x20 */ x86emuOp2_illegal_op, /* mov reg32,creg (ring 0 PM) */
|
||||
/* 0x21 */ x86emuOp2_illegal_op, /* mov reg32,dreg (ring 0 PM) */
|
||||
/* 0x22 */ x86emuOp2_illegal_op, /* mov creg,reg32 (ring 0 PM) */
|
||||
/* 0x23 */ x86emuOp2_illegal_op, /* mov dreg,reg32 (ring 0 PM) */
|
||||
/* 0x24 */ x86emuOp2_illegal_op, /* mov reg32,treg (ring 0 PM) */
|
||||
/* 0x25 */ x86emuOp2_illegal_op,
|
||||
/* 0x26 */ x86emuOp2_illegal_op, /* mov treg,reg32 (ring 0 PM) */
|
||||
/* 0x27 */ x86emuOp2_illegal_op,
|
||||
/* 0x28 */ x86emuOp2_illegal_op,
|
||||
/* 0x29 */ x86emuOp2_illegal_op,
|
||||
/* 0x2a */ x86emuOp2_illegal_op,
|
||||
/* 0x2b */ x86emuOp2_illegal_op,
|
||||
/* 0x2c */ x86emuOp2_illegal_op,
|
||||
/* 0x2d */ x86emuOp2_illegal_op,
|
||||
/* 0x2e */ x86emuOp2_illegal_op,
|
||||
/* 0x2f */ x86emuOp2_illegal_op,
|
||||
|
||||
/* 0x30 */ x86emuOp2_illegal_op,
|
||||
/* 0x31 */ x86emuOp2_illegal_op,
|
||||
/* 0x32 */ x86emuOp2_illegal_op,
|
||||
/* 0x33 */ x86emuOp2_illegal_op,
|
||||
/* 0x34 */ x86emuOp2_illegal_op,
|
||||
/* 0x35 */ x86emuOp2_illegal_op,
|
||||
/* 0x36 */ x86emuOp2_illegal_op,
|
||||
/* 0x37 */ x86emuOp2_illegal_op,
|
||||
/* 0x38 */ x86emuOp2_illegal_op,
|
||||
/* 0x39 */ x86emuOp2_illegal_op,
|
||||
/* 0x3a */ x86emuOp2_illegal_op,
|
||||
/* 0x3b */ x86emuOp2_illegal_op,
|
||||
/* 0x3c */ x86emuOp2_illegal_op,
|
||||
/* 0x3d */ x86emuOp2_illegal_op,
|
||||
/* 0x3e */ x86emuOp2_illegal_op,
|
||||
/* 0x3f */ x86emuOp2_illegal_op,
|
||||
/* 0x30 */ x86emuOp2_illegal_op,
|
||||
/* 0x31 */ x86emuOp2_illegal_op,
|
||||
/* 0x32 */ x86emuOp2_illegal_op,
|
||||
/* 0x33 */ x86emuOp2_illegal_op,
|
||||
/* 0x34 */ x86emuOp2_illegal_op,
|
||||
/* 0x35 */ x86emuOp2_illegal_op,
|
||||
/* 0x36 */ x86emuOp2_illegal_op,
|
||||
/* 0x37 */ x86emuOp2_illegal_op,
|
||||
/* 0x38 */ x86emuOp2_illegal_op,
|
||||
/* 0x39 */ x86emuOp2_illegal_op,
|
||||
/* 0x3a */ x86emuOp2_illegal_op,
|
||||
/* 0x3b */ x86emuOp2_illegal_op,
|
||||
/* 0x3c */ x86emuOp2_illegal_op,
|
||||
/* 0x3d */ x86emuOp2_illegal_op,
|
||||
/* 0x3e */ x86emuOp2_illegal_op,
|
||||
/* 0x3f */ x86emuOp2_illegal_op,
|
||||
|
||||
/* 0x40 */ x86emuOp2_illegal_op,
|
||||
/* 0x41 */ x86emuOp2_illegal_op,
|
||||
/* 0x42 */ x86emuOp2_illegal_op,
|
||||
/* 0x43 */ x86emuOp2_illegal_op,
|
||||
/* 0x44 */ x86emuOp2_illegal_op,
|
||||
/* 0x45 */ x86emuOp2_illegal_op,
|
||||
/* 0x46 */ x86emuOp2_illegal_op,
|
||||
/* 0x47 */ x86emuOp2_illegal_op,
|
||||
/* 0x48 */ x86emuOp2_illegal_op,
|
||||
/* 0x49 */ x86emuOp2_illegal_op,
|
||||
/* 0x4a */ x86emuOp2_illegal_op,
|
||||
/* 0x4b */ x86emuOp2_illegal_op,
|
||||
/* 0x4c */ x86emuOp2_illegal_op,
|
||||
/* 0x4d */ x86emuOp2_illegal_op,
|
||||
/* 0x4e */ x86emuOp2_illegal_op,
|
||||
/* 0x4f */ x86emuOp2_illegal_op,
|
||||
/* 0x40 */ x86emuOp2_illegal_op,
|
||||
/* 0x41 */ x86emuOp2_illegal_op,
|
||||
/* 0x42 */ x86emuOp2_illegal_op,
|
||||
/* 0x43 */ x86emuOp2_illegal_op,
|
||||
/* 0x44 */ x86emuOp2_illegal_op,
|
||||
/* 0x45 */ x86emuOp2_illegal_op,
|
||||
/* 0x46 */ x86emuOp2_illegal_op,
|
||||
/* 0x47 */ x86emuOp2_illegal_op,
|
||||
/* 0x48 */ x86emuOp2_illegal_op,
|
||||
/* 0x49 */ x86emuOp2_illegal_op,
|
||||
/* 0x4a */ x86emuOp2_illegal_op,
|
||||
/* 0x4b */ x86emuOp2_illegal_op,
|
||||
/* 0x4c */ x86emuOp2_illegal_op,
|
||||
/* 0x4d */ x86emuOp2_illegal_op,
|
||||
/* 0x4e */ x86emuOp2_illegal_op,
|
||||
/* 0x4f */ x86emuOp2_illegal_op,
|
||||
|
||||
/* 0x50 */ x86emuOp2_illegal_op,
|
||||
/* 0x51 */ x86emuOp2_illegal_op,
|
||||
/* 0x52 */ x86emuOp2_illegal_op,
|
||||
/* 0x53 */ x86emuOp2_illegal_op,
|
||||
/* 0x54 */ x86emuOp2_illegal_op,
|
||||
/* 0x55 */ x86emuOp2_illegal_op,
|
||||
/* 0x56 */ x86emuOp2_illegal_op,
|
||||
/* 0x57 */ x86emuOp2_illegal_op,
|
||||
/* 0x58 */ x86emuOp2_illegal_op,
|
||||
/* 0x59 */ x86emuOp2_illegal_op,
|
||||
/* 0x5a */ x86emuOp2_illegal_op,
|
||||
/* 0x5b */ x86emuOp2_illegal_op,
|
||||
/* 0x5c */ x86emuOp2_illegal_op,
|
||||
/* 0x5d */ x86emuOp2_illegal_op,
|
||||
/* 0x5e */ x86emuOp2_illegal_op,
|
||||
/* 0x5f */ x86emuOp2_illegal_op,
|
||||
/* 0x50 */ x86emuOp2_illegal_op,
|
||||
/* 0x51 */ x86emuOp2_illegal_op,
|
||||
/* 0x52 */ x86emuOp2_illegal_op,
|
||||
/* 0x53 */ x86emuOp2_illegal_op,
|
||||
/* 0x54 */ x86emuOp2_illegal_op,
|
||||
/* 0x55 */ x86emuOp2_illegal_op,
|
||||
/* 0x56 */ x86emuOp2_illegal_op,
|
||||
/* 0x57 */ x86emuOp2_illegal_op,
|
||||
/* 0x58 */ x86emuOp2_illegal_op,
|
||||
/* 0x59 */ x86emuOp2_illegal_op,
|
||||
/* 0x5a */ x86emuOp2_illegal_op,
|
||||
/* 0x5b */ x86emuOp2_illegal_op,
|
||||
/* 0x5c */ x86emuOp2_illegal_op,
|
||||
/* 0x5d */ x86emuOp2_illegal_op,
|
||||
/* 0x5e */ x86emuOp2_illegal_op,
|
||||
/* 0x5f */ x86emuOp2_illegal_op,
|
||||
|
||||
/* 0x60 */ x86emuOp2_illegal_op,
|
||||
/* 0x61 */ x86emuOp2_illegal_op,
|
||||
/* 0x62 */ x86emuOp2_illegal_op,
|
||||
/* 0x63 */ x86emuOp2_illegal_op,
|
||||
/* 0x64 */ x86emuOp2_illegal_op,
|
||||
/* 0x65 */ x86emuOp2_illegal_op,
|
||||
/* 0x66 */ x86emuOp2_illegal_op,
|
||||
/* 0x67 */ x86emuOp2_illegal_op,
|
||||
/* 0x68 */ x86emuOp2_illegal_op,
|
||||
/* 0x69 */ x86emuOp2_illegal_op,
|
||||
/* 0x6a */ x86emuOp2_illegal_op,
|
||||
/* 0x6b */ x86emuOp2_illegal_op,
|
||||
/* 0x6c */ x86emuOp2_illegal_op,
|
||||
/* 0x6d */ x86emuOp2_illegal_op,
|
||||
/* 0x6e */ x86emuOp2_illegal_op,
|
||||
/* 0x6f */ x86emuOp2_illegal_op,
|
||||
/* 0x60 */ x86emuOp2_illegal_op,
|
||||
/* 0x61 */ x86emuOp2_illegal_op,
|
||||
/* 0x62 */ x86emuOp2_illegal_op,
|
||||
/* 0x63 */ x86emuOp2_illegal_op,
|
||||
/* 0x64 */ x86emuOp2_illegal_op,
|
||||
/* 0x65 */ x86emuOp2_illegal_op,
|
||||
/* 0x66 */ x86emuOp2_illegal_op,
|
||||
/* 0x67 */ x86emuOp2_illegal_op,
|
||||
/* 0x68 */ x86emuOp2_illegal_op,
|
||||
/* 0x69 */ x86emuOp2_illegal_op,
|
||||
/* 0x6a */ x86emuOp2_illegal_op,
|
||||
/* 0x6b */ x86emuOp2_illegal_op,
|
||||
/* 0x6c */ x86emuOp2_illegal_op,
|
||||
/* 0x6d */ x86emuOp2_illegal_op,
|
||||
/* 0x6e */ x86emuOp2_illegal_op,
|
||||
/* 0x6f */ x86emuOp2_illegal_op,
|
||||
|
||||
/* 0x70 */ x86emuOp2_illegal_op,
|
||||
/* 0x71 */ x86emuOp2_illegal_op,
|
||||
/* 0x72 */ x86emuOp2_illegal_op,
|
||||
/* 0x73 */ x86emuOp2_illegal_op,
|
||||
/* 0x74 */ x86emuOp2_illegal_op,
|
||||
/* 0x75 */ x86emuOp2_illegal_op,
|
||||
/* 0x76 */ x86emuOp2_illegal_op,
|
||||
/* 0x77 */ x86emuOp2_illegal_op,
|
||||
/* 0x78 */ x86emuOp2_illegal_op,
|
||||
/* 0x79 */ x86emuOp2_illegal_op,
|
||||
/* 0x7a */ x86emuOp2_illegal_op,
|
||||
/* 0x7b */ x86emuOp2_illegal_op,
|
||||
/* 0x7c */ x86emuOp2_illegal_op,
|
||||
/* 0x7d */ x86emuOp2_illegal_op,
|
||||
/* 0x7e */ x86emuOp2_illegal_op,
|
||||
/* 0x7f */ x86emuOp2_illegal_op,
|
||||
/* 0x70 */ x86emuOp2_illegal_op,
|
||||
/* 0x71 */ x86emuOp2_illegal_op,
|
||||
/* 0x72 */ x86emuOp2_illegal_op,
|
||||
/* 0x73 */ x86emuOp2_illegal_op,
|
||||
/* 0x74 */ x86emuOp2_illegal_op,
|
||||
/* 0x75 */ x86emuOp2_illegal_op,
|
||||
/* 0x76 */ x86emuOp2_illegal_op,
|
||||
/* 0x77 */ x86emuOp2_illegal_op,
|
||||
/* 0x78 */ x86emuOp2_illegal_op,
|
||||
/* 0x79 */ x86emuOp2_illegal_op,
|
||||
/* 0x7a */ x86emuOp2_illegal_op,
|
||||
/* 0x7b */ x86emuOp2_illegal_op,
|
||||
/* 0x7c */ x86emuOp2_illegal_op,
|
||||
/* 0x7d */ x86emuOp2_illegal_op,
|
||||
/* 0x7e */ x86emuOp2_illegal_op,
|
||||
/* 0x7f */ x86emuOp2_illegal_op,
|
||||
|
||||
/* 0x80 */ x86emuOp2_long_jump,
|
||||
/* 0x81 */ x86emuOp2_long_jump,
|
||||
/* 0x82 */ x86emuOp2_long_jump,
|
||||
/* 0x83 */ x86emuOp2_long_jump,
|
||||
/* 0x84 */ x86emuOp2_long_jump,
|
||||
/* 0x85 */ x86emuOp2_long_jump,
|
||||
/* 0x86 */ x86emuOp2_long_jump,
|
||||
/* 0x87 */ x86emuOp2_long_jump,
|
||||
/* 0x88 */ x86emuOp2_long_jump,
|
||||
/* 0x89 */ x86emuOp2_long_jump,
|
||||
/* 0x8a */ x86emuOp2_long_jump,
|
||||
/* 0x8b */ x86emuOp2_long_jump,
|
||||
/* 0x8c */ x86emuOp2_long_jump,
|
||||
/* 0x8d */ x86emuOp2_long_jump,
|
||||
/* 0x8e */ x86emuOp2_long_jump,
|
||||
/* 0x8f */ x86emuOp2_long_jump,
|
||||
/* 0x80 */ x86emuOp2_long_jump,
|
||||
/* 0x81 */ x86emuOp2_long_jump,
|
||||
/* 0x82 */ x86emuOp2_long_jump,
|
||||
/* 0x83 */ x86emuOp2_long_jump,
|
||||
/* 0x84 */ x86emuOp2_long_jump,
|
||||
/* 0x85 */ x86emuOp2_long_jump,
|
||||
/* 0x86 */ x86emuOp2_long_jump,
|
||||
/* 0x87 */ x86emuOp2_long_jump,
|
||||
/* 0x88 */ x86emuOp2_long_jump,
|
||||
/* 0x89 */ x86emuOp2_long_jump,
|
||||
/* 0x8a */ x86emuOp2_long_jump,
|
||||
/* 0x8b */ x86emuOp2_long_jump,
|
||||
/* 0x8c */ x86emuOp2_long_jump,
|
||||
/* 0x8d */ x86emuOp2_long_jump,
|
||||
/* 0x8e */ x86emuOp2_long_jump,
|
||||
/* 0x8f */ x86emuOp2_long_jump,
|
||||
|
||||
/* 0x90 */ x86emuOp2_set_byte,
|
||||
/* 0x91 */ x86emuOp2_set_byte,
|
||||
/* 0x92 */ x86emuOp2_set_byte,
|
||||
/* 0x93 */ x86emuOp2_set_byte,
|
||||
/* 0x94 */ x86emuOp2_set_byte,
|
||||
/* 0x95 */ x86emuOp2_set_byte,
|
||||
/* 0x96 */ x86emuOp2_set_byte,
|
||||
/* 0x97 */ x86emuOp2_set_byte,
|
||||
/* 0x98 */ x86emuOp2_set_byte,
|
||||
/* 0x99 */ x86emuOp2_set_byte,
|
||||
/* 0x9a */ x86emuOp2_set_byte,
|
||||
/* 0x9b */ x86emuOp2_set_byte,
|
||||
/* 0x9c */ x86emuOp2_set_byte,
|
||||
/* 0x9d */ x86emuOp2_set_byte,
|
||||
/* 0x9e */ x86emuOp2_set_byte,
|
||||
/* 0x9f */ x86emuOp2_set_byte,
|
||||
/* 0x90 */ x86emuOp2_set_byte,
|
||||
/* 0x91 */ x86emuOp2_set_byte,
|
||||
/* 0x92 */ x86emuOp2_set_byte,
|
||||
/* 0x93 */ x86emuOp2_set_byte,
|
||||
/* 0x94 */ x86emuOp2_set_byte,
|
||||
/* 0x95 */ x86emuOp2_set_byte,
|
||||
/* 0x96 */ x86emuOp2_set_byte,
|
||||
/* 0x97 */ x86emuOp2_set_byte,
|
||||
/* 0x98 */ x86emuOp2_set_byte,
|
||||
/* 0x99 */ x86emuOp2_set_byte,
|
||||
/* 0x9a */ x86emuOp2_set_byte,
|
||||
/* 0x9b */ x86emuOp2_set_byte,
|
||||
/* 0x9c */ x86emuOp2_set_byte,
|
||||
/* 0x9d */ x86emuOp2_set_byte,
|
||||
/* 0x9e */ x86emuOp2_set_byte,
|
||||
/* 0x9f */ x86emuOp2_set_byte,
|
||||
|
||||
/* 0xa0 */ x86emuOp2_push_FS,
|
||||
/* 0xa1 */ x86emuOp2_pop_FS,
|
||||
/* 0xa2 */ x86emuOp2_illegal_op,
|
||||
/* 0xa3 */ x86emuOp2_bt_R,
|
||||
/* 0xa4 */ x86emuOp2_shld_IMM,
|
||||
/* 0xa5 */ x86emuOp2_shld_CL,
|
||||
/* 0xa6 */ x86emuOp2_illegal_op,
|
||||
/* 0xa7 */ x86emuOp2_illegal_op,
|
||||
/* 0xa8 */ x86emuOp2_push_GS,
|
||||
/* 0xa9 */ x86emuOp2_pop_GS,
|
||||
/* 0xaa */ x86emuOp2_illegal_op,
|
||||
/* 0xab */ x86emuOp2_bt_R,
|
||||
/* 0xac */ x86emuOp2_shrd_IMM,
|
||||
/* 0xad */ x86emuOp2_shrd_CL,
|
||||
/* 0xae */ x86emuOp2_illegal_op,
|
||||
/* 0xaf */ x86emuOp2_imul_R_RM,
|
||||
/* 0xa0 */ x86emuOp2_push_FS,
|
||||
/* 0xa1 */ x86emuOp2_pop_FS,
|
||||
/* 0xa2 */ x86emuOp2_illegal_op,
|
||||
/* 0xa3 */ x86emuOp2_bt_R,
|
||||
/* 0xa4 */ x86emuOp2_shld_IMM,
|
||||
/* 0xa5 */ x86emuOp2_shld_CL,
|
||||
/* 0xa6 */ x86emuOp2_illegal_op,
|
||||
/* 0xa7 */ x86emuOp2_illegal_op,
|
||||
/* 0xa8 */ x86emuOp2_push_GS,
|
||||
/* 0xa9 */ x86emuOp2_pop_GS,
|
||||
/* 0xaa */ x86emuOp2_illegal_op,
|
||||
/* 0xab */ x86emuOp2_bt_R,
|
||||
/* 0xac */ x86emuOp2_shrd_IMM,
|
||||
/* 0xad */ x86emuOp2_shrd_CL,
|
||||
/* 0xae */ x86emuOp2_illegal_op,
|
||||
/* 0xaf */ x86emuOp2_imul_R_RM,
|
||||
|
||||
/* 0xb0 */ x86emuOp2_illegal_op, /* TODO: cmpxchg */
|
||||
/* 0xb1 */ x86emuOp2_illegal_op, /* TODO: cmpxchg */
|
||||
/* 0xb2 */ x86emuOp2_lss_R_IMM,
|
||||
/* 0xb3 */ x86emuOp2_btr_R,
|
||||
/* 0xb4 */ x86emuOp2_lfs_R_IMM,
|
||||
/* 0xb5 */ x86emuOp2_lgs_R_IMM,
|
||||
/* 0xb6 */ x86emuOp2_movzx_byte_R_RM,
|
||||
/* 0xb7 */ x86emuOp2_movzx_word_R_RM,
|
||||
/* 0xb8 */ x86emuOp2_illegal_op,
|
||||
/* 0xb9 */ x86emuOp2_illegal_op,
|
||||
/* 0xba */ x86emuOp2_btX_I,
|
||||
/* 0xbb */ x86emuOp2_btc_R,
|
||||
/* 0xbc */ x86emuOp2_bsf,
|
||||
/* 0xbd */ x86emuOp2_bsr,
|
||||
/* 0xbe */ x86emuOp2_movsx_byte_R_RM,
|
||||
/* 0xbf */ x86emuOp2_movsx_word_R_RM,
|
||||
/* 0xb0 */ x86emuOp2_illegal_op, /* TODO: cmpxchg */
|
||||
/* 0xb1 */ x86emuOp2_illegal_op, /* TODO: cmpxchg */
|
||||
/* 0xb2 */ x86emuOp2_lss_R_IMM,
|
||||
/* 0xb3 */ x86emuOp2_btr_R,
|
||||
/* 0xb4 */ x86emuOp2_lfs_R_IMM,
|
||||
/* 0xb5 */ x86emuOp2_lgs_R_IMM,
|
||||
/* 0xb6 */ x86emuOp2_movzx_byte_R_RM,
|
||||
/* 0xb7 */ x86emuOp2_movzx_word_R_RM,
|
||||
/* 0xb8 */ x86emuOp2_illegal_op,
|
||||
/* 0xb9 */ x86emuOp2_illegal_op,
|
||||
/* 0xba */ x86emuOp2_btX_I,
|
||||
/* 0xbb */ x86emuOp2_btc_R,
|
||||
/* 0xbc */ x86emuOp2_bsf,
|
||||
/* 0xbd */ x86emuOp2_bsr,
|
||||
/* 0xbe */ x86emuOp2_movsx_byte_R_RM,
|
||||
/* 0xbf */ x86emuOp2_movsx_word_R_RM,
|
||||
|
||||
/* 0xc0 */ x86emuOp2_illegal_op, /* TODO: xadd */
|
||||
/* 0xc1 */ x86emuOp2_illegal_op, /* TODO: xadd */
|
||||
/* 0xc2 */ x86emuOp2_illegal_op,
|
||||
/* 0xc3 */ x86emuOp2_illegal_op,
|
||||
/* 0xc4 */ x86emuOp2_illegal_op,
|
||||
/* 0xc5 */ x86emuOp2_illegal_op,
|
||||
/* 0xc6 */ x86emuOp2_illegal_op,
|
||||
/* 0xc7 */ x86emuOp2_illegal_op,
|
||||
/* 0xc8 */ x86emuOp2_illegal_op, /* TODO: bswap */
|
||||
/* 0xc9 */ x86emuOp2_illegal_op, /* TODO: bswap */
|
||||
/* 0xca */ x86emuOp2_illegal_op, /* TODO: bswap */
|
||||
/* 0xcb */ x86emuOp2_illegal_op, /* TODO: bswap */
|
||||
/* 0xcc */ x86emuOp2_illegal_op, /* TODO: bswap */
|
||||
/* 0xcd */ x86emuOp2_illegal_op, /* TODO: bswap */
|
||||
/* 0xce */ x86emuOp2_illegal_op, /* TODO: bswap */
|
||||
/* 0xcf */ x86emuOp2_illegal_op, /* TODO: bswap */
|
||||
/* 0xc0 */ x86emuOp2_illegal_op, /* TODO: xadd */
|
||||
/* 0xc1 */ x86emuOp2_illegal_op, /* TODO: xadd */
|
||||
/* 0xc2 */ x86emuOp2_illegal_op,
|
||||
/* 0xc3 */ x86emuOp2_illegal_op,
|
||||
/* 0xc4 */ x86emuOp2_illegal_op,
|
||||
/* 0xc5 */ x86emuOp2_illegal_op,
|
||||
/* 0xc6 */ x86emuOp2_illegal_op,
|
||||
/* 0xc7 */ x86emuOp2_illegal_op,
|
||||
/* 0xc8 */ x86emuOp2_illegal_op, /* TODO: bswap */
|
||||
/* 0xc9 */ x86emuOp2_illegal_op, /* TODO: bswap */
|
||||
/* 0xca */ x86emuOp2_illegal_op, /* TODO: bswap */
|
||||
/* 0xcb */ x86emuOp2_illegal_op, /* TODO: bswap */
|
||||
/* 0xcc */ x86emuOp2_illegal_op, /* TODO: bswap */
|
||||
/* 0xcd */ x86emuOp2_illegal_op, /* TODO: bswap */
|
||||
/* 0xce */ x86emuOp2_illegal_op, /* TODO: bswap */
|
||||
/* 0xcf */ x86emuOp2_illegal_op, /* TODO: bswap */
|
||||
|
||||
/* 0xd0 */ x86emuOp2_illegal_op,
|
||||
/* 0xd1 */ x86emuOp2_illegal_op,
|
||||
/* 0xd2 */ x86emuOp2_illegal_op,
|
||||
/* 0xd3 */ x86emuOp2_illegal_op,
|
||||
/* 0xd4 */ x86emuOp2_illegal_op,
|
||||
/* 0xd5 */ x86emuOp2_illegal_op,
|
||||
/* 0xd6 */ x86emuOp2_illegal_op,
|
||||
/* 0xd7 */ x86emuOp2_illegal_op,
|
||||
/* 0xd8 */ x86emuOp2_illegal_op,
|
||||
/* 0xd9 */ x86emuOp2_illegal_op,
|
||||
/* 0xda */ x86emuOp2_illegal_op,
|
||||
/* 0xdb */ x86emuOp2_illegal_op,
|
||||
/* 0xdc */ x86emuOp2_illegal_op,
|
||||
/* 0xdd */ x86emuOp2_illegal_op,
|
||||
/* 0xde */ x86emuOp2_illegal_op,
|
||||
/* 0xdf */ x86emuOp2_illegal_op,
|
||||
/* 0xd0 */ x86emuOp2_illegal_op,
|
||||
/* 0xd1 */ x86emuOp2_illegal_op,
|
||||
/* 0xd2 */ x86emuOp2_illegal_op,
|
||||
/* 0xd3 */ x86emuOp2_illegal_op,
|
||||
/* 0xd4 */ x86emuOp2_illegal_op,
|
||||
/* 0xd5 */ x86emuOp2_illegal_op,
|
||||
/* 0xd6 */ x86emuOp2_illegal_op,
|
||||
/* 0xd7 */ x86emuOp2_illegal_op,
|
||||
/* 0xd8 */ x86emuOp2_illegal_op,
|
||||
/* 0xd9 */ x86emuOp2_illegal_op,
|
||||
/* 0xda */ x86emuOp2_illegal_op,
|
||||
/* 0xdb */ x86emuOp2_illegal_op,
|
||||
/* 0xdc */ x86emuOp2_illegal_op,
|
||||
/* 0xdd */ x86emuOp2_illegal_op,
|
||||
/* 0xde */ x86emuOp2_illegal_op,
|
||||
/* 0xdf */ x86emuOp2_illegal_op,
|
||||
|
||||
/* 0xe0 */ x86emuOp2_illegal_op,
|
||||
/* 0xe1 */ x86emuOp2_illegal_op,
|
||||
/* 0xe2 */ x86emuOp2_illegal_op,
|
||||
/* 0xe3 */ x86emuOp2_illegal_op,
|
||||
/* 0xe4 */ x86emuOp2_illegal_op,
|
||||
/* 0xe5 */ x86emuOp2_illegal_op,
|
||||
/* 0xe6 */ x86emuOp2_illegal_op,
|
||||
/* 0xe7 */ x86emuOp2_illegal_op,
|
||||
/* 0xe8 */ x86emuOp2_illegal_op,
|
||||
/* 0xe9 */ x86emuOp2_illegal_op,
|
||||
/* 0xea */ x86emuOp2_illegal_op,
|
||||
/* 0xeb */ x86emuOp2_illegal_op,
|
||||
/* 0xec */ x86emuOp2_illegal_op,
|
||||
/* 0xed */ x86emuOp2_illegal_op,
|
||||
/* 0xee */ x86emuOp2_illegal_op,
|
||||
/* 0xef */ x86emuOp2_illegal_op,
|
||||
/* 0xe0 */ x86emuOp2_illegal_op,
|
||||
/* 0xe1 */ x86emuOp2_illegal_op,
|
||||
/* 0xe2 */ x86emuOp2_illegal_op,
|
||||
/* 0xe3 */ x86emuOp2_illegal_op,
|
||||
/* 0xe4 */ x86emuOp2_illegal_op,
|
||||
/* 0xe5 */ x86emuOp2_illegal_op,
|
||||
/* 0xe6 */ x86emuOp2_illegal_op,
|
||||
/* 0xe7 */ x86emuOp2_illegal_op,
|
||||
/* 0xe8 */ x86emuOp2_illegal_op,
|
||||
/* 0xe9 */ x86emuOp2_illegal_op,
|
||||
/* 0xea */ x86emuOp2_illegal_op,
|
||||
/* 0xeb */ x86emuOp2_illegal_op,
|
||||
/* 0xec */ x86emuOp2_illegal_op,
|
||||
/* 0xed */ x86emuOp2_illegal_op,
|
||||
/* 0xee */ x86emuOp2_illegal_op,
|
||||
/* 0xef */ x86emuOp2_illegal_op,
|
||||
|
||||
/* 0xf0 */ x86emuOp2_illegal_op,
|
||||
/* 0xf1 */ x86emuOp2_illegal_op,
|
||||
/* 0xf2 */ x86emuOp2_illegal_op,
|
||||
/* 0xf3 */ x86emuOp2_illegal_op,
|
||||
/* 0xf4 */ x86emuOp2_illegal_op,
|
||||
/* 0xf5 */ x86emuOp2_illegal_op,
|
||||
/* 0xf6 */ x86emuOp2_illegal_op,
|
||||
/* 0xf7 */ x86emuOp2_illegal_op,
|
||||
/* 0xf8 */ x86emuOp2_illegal_op,
|
||||
/* 0xf9 */ x86emuOp2_illegal_op,
|
||||
/* 0xfa */ x86emuOp2_illegal_op,
|
||||
/* 0xfb */ x86emuOp2_illegal_op,
|
||||
/* 0xfc */ x86emuOp2_illegal_op,
|
||||
/* 0xfd */ x86emuOp2_illegal_op,
|
||||
/* 0xfe */ x86emuOp2_illegal_op,
|
||||
/* 0xff */ x86emuOp2_illegal_op,
|
||||
/* 0xf0 */ x86emuOp2_illegal_op,
|
||||
/* 0xf1 */ x86emuOp2_illegal_op,
|
||||
/* 0xf2 */ x86emuOp2_illegal_op,
|
||||
/* 0xf3 */ x86emuOp2_illegal_op,
|
||||
/* 0xf4 */ x86emuOp2_illegal_op,
|
||||
/* 0xf5 */ x86emuOp2_illegal_op,
|
||||
/* 0xf6 */ x86emuOp2_illegal_op,
|
||||
/* 0xf7 */ x86emuOp2_illegal_op,
|
||||
/* 0xf8 */ x86emuOp2_illegal_op,
|
||||
/* 0xf9 */ x86emuOp2_illegal_op,
|
||||
/* 0xfa */ x86emuOp2_illegal_op,
|
||||
/* 0xfb */ x86emuOp2_illegal_op,
|
||||
/* 0xfc */ x86emuOp2_illegal_op,
|
||||
/* 0xfd */ x86emuOp2_illegal_op,
|
||||
/* 0xfe */ x86emuOp2_illegal_op,
|
||||
/* 0xff */ x86emuOp2_illegal_op,
|
||||
};
|
||||
|
||||
28
x86emu/sys.c
28
x86emu/sys.c
@@ -60,8 +60,6 @@ extern uint32_t inl(uint16_t port);
|
||||
extern void outb(uint8_t val, uint16_t port);
|
||||
extern void outw(uint16_t val, uint16_t port);
|
||||
extern void outl(uint32_t val, uint16_t port);
|
||||
extern uint16_t swap_short(uint16_t val);
|
||||
extern uint32_t swap_long(uint32_t val);
|
||||
|
||||
/*------------------------- Global Variables ------------------------------*/
|
||||
|
||||
@@ -202,7 +200,7 @@ uint32_t X86API rdl(uint32_t addr)
|
||||
#ifdef DEBUG_X86EMU_PCI
|
||||
DPRINTVALHEX("rdl(", addr);
|
||||
#endif
|
||||
val = swap_long(*(uint32_t *)(offset_mem+addr));
|
||||
val = swpl(*(uint32_t *)(offset_mem+addr));
|
||||
#ifdef DEBUG_X86EMU_PCI
|
||||
DPRINTVALHEX(") = ", val);
|
||||
DPRINT("\r\n");
|
||||
@@ -227,7 +225,7 @@ uint32_t X86API rdl(uint32_t addr)
|
||||
DPRINT("\r\n");
|
||||
}
|
||||
#endif
|
||||
val = swap_long(*(uint32_t *)(M.mem_base + addr));
|
||||
val = swpl(*(uint32_t *)(M.mem_base + addr));
|
||||
// val = *(uint32_t *)(M.mem_base + addr);
|
||||
}
|
||||
DB(if (DEBUG_MEM_TRACE())
|
||||
@@ -302,15 +300,7 @@ void X86API wrw(uint32_t addr, uint16_t val)
|
||||
DPRINTVALHEX(") = ", val);
|
||||
DPRINT("\r\n");
|
||||
#endif
|
||||
#ifdef DIRECT_ACCESS
|
||||
*(uint16_t *)(offset_mem+addr) = swap_short(val);
|
||||
#else
|
||||
#ifdef PCI_XBIOS
|
||||
write_mem_word(rinfo_biosemu->handle, offset_mem+addr, val);
|
||||
#else
|
||||
Write_mem_word(rinfo_biosemu->handle, offset_mem+addr, val);
|
||||
#endif
|
||||
#endif
|
||||
*(uint16_t *)(offset_mem+addr) = swpw(val);
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -358,15 +348,7 @@ void X86API wrl(uint32_t addr, uint32_t val)
|
||||
DPRINTVALHEX(") = ", val);
|
||||
DPRINT("\r\n");
|
||||
#endif
|
||||
#ifdef DIRECT_ACCESS
|
||||
*(uint32_t *)(offset_mem+addr) = swap_long(val);
|
||||
#else
|
||||
#ifdef PCI_XBIOS
|
||||
write_mem_longword(rinfo_biosemu->handle, offset_mem+addr, val);
|
||||
#else
|
||||
Write_mem_longword(rinfo_biosemu->handle, offset_mem+addr, val);
|
||||
#endif
|
||||
#endif
|
||||
*(uint32_t *)(offset_mem+addr) = swpl(val);
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -385,7 +367,7 @@ void X86API wrl(uint32_t addr, uint32_t val)
|
||||
DPRINT("\r\n");
|
||||
}
|
||||
#endif
|
||||
*(uint32_t *)(M.mem_base + addr) = swap_long(val);
|
||||
*(uint32_t *)(M.mem_base + addr) = swpl(val);
|
||||
// *(uint32_t *)(M.mem_base + addr) = val;
|
||||
}
|
||||
DB(if (DEBUG_MEM_TRACE())
|
||||
|
||||
Reference in New Issue
Block a user