2002-09-13 19:53:22 +04:00
|
|
|
/////////////////////////////////////////////////////////////////////////
|
2003-03-17 03:41:01 +03:00
|
|
|
// $Id: resolve64.cc,v 1.6 2003-03-17 00:41:00 cbothamy Exp $
|
2002-09-13 19:53:22 +04:00
|
|
|
/////////////////////////////////////////////////////////////////////////
|
|
|
|
//
|
|
|
|
// Copyright (C) 2001 MandrakeSoft S.A.
|
|
|
|
//
|
|
|
|
// MandrakeSoft S.A.
|
|
|
|
// 43, rue d'Aboukir
|
|
|
|
// 75002 Paris - France
|
|
|
|
// http://www.linux-mandrake.com/
|
|
|
|
// http://www.mandrakesoft.com/
|
|
|
|
//
|
|
|
|
// This library is free software; you can redistribute it and/or
|
|
|
|
// modify it under the terms of the GNU Lesser General Public
|
|
|
|
// License as published by the Free Software Foundation; either
|
|
|
|
// version 2 of the License, or (at your option) any later version.
|
|
|
|
//
|
|
|
|
// This library is distributed in the hope that it will be useful,
|
|
|
|
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
|
// Lesser General Public License for more details.
|
|
|
|
//
|
|
|
|
// You should have received a copy of the GNU Lesser General Public
|
|
|
|
// License along with this library; if not, write to the Free Software
|
|
|
|
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#define NEED_CPU_REG_SHORTCUTS 1
|
|
|
|
#include "bochs.h"
|
|
|
|
#define LOG_THIS BX_CPU_THIS_PTR
|
|
|
|
|
|
|
|
|
2002-11-19 08:47:45 +03:00
|
|
|
#if BX_SUPPORT_X86_64
|
2002-09-13 19:53:22 +04:00
|
|
|
|
|
|
|
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Rm0(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RAX;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Rm1(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RCX;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Rm2(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RDX;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Rm3(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RBX;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Rm5(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
|
|
|
// eip hasn't been bumped yet when this is called. must choose the saved value.
|
2002-09-18 12:00:43 +04:00
|
|
|
RMAddr(i) = BX_CPU_THIS_PTR prev_eip + i->ilen() + (Bit32s)i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Rm6(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RSI;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Rm7(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RDI;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Rm8(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R8;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Rm9(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R9;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Rm10(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R10;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Rm11(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R11;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Rm12(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R12;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Rm13(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R13;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
|
|
|
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Rm14(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R14;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
|
|
|
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Rm15(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R15;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
|
|
|
|
|
|
|
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Rm0(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RAX + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Rm1(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RCX + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Rm2(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RDX + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Rm3(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RBX + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Rm5(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RBP + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Rm6(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RSI + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Rm7(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RDI + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Rm8(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R8 + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Rm9(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R9 + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Rm10(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R10 + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Rm11(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R11 + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Rm12(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R12 + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Rm13(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R13 + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Rm14(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R14 + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Rm15(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R15 + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Base0(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RAX + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale());
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RAX;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Base1(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RCX + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale());
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RCX;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Base2(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RDX + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale());
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RDX;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Base3(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RBX + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale());
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RBX;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Base4(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RSP + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale());
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RSP;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Base5(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4) {
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale()) + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Base6(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RSI + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale());
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RSI;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Base7(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RDI + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale());
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RDI;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Base8(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R8 + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale());
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R8;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Base9(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R9 + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale());
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R9;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Base10(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R10 + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale());
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R10;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Base11(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R11 + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale());
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R11;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Base12(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R12 + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale());
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R12;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Base13(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R13 + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale());
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R13;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Base14(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R14 + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale());
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R14;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod0Base15(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R15 + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale());
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R15;
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Base0(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RAX + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale()) + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RAX + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Base1(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RCX + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale()) + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RCX + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Base2(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RDX + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale()) + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RDX + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Base3(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RBX + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale()) + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RBX + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Base4(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RSP + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale()) + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RSP + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Base5(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RBP + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale()) + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RBP + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Base6(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RSI + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale()) + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RSI + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Base7(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RDI + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale()) + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = RDI + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Base8(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R8 + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale()) + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R8 + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Base9(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R9 + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale()) + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R9 + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Base10(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R10 + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale()) + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R10 + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Base11(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R11 + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale()) + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R11 + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Base12(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R12 + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale()) + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R12 + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Base13(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R13 + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale()) + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R13 + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Base14(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R14 + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale()) + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R14 + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
2003-03-17 03:41:01 +03:00
|
|
|
void BX_CPP_AttrRegparmN(1)
|
2002-09-18 02:50:53 +04:00
|
|
|
BX_CPU_C::Resolve64Mod1or2Base15(bxInstruction_c *i)
|
2002-09-13 19:53:22 +04:00
|
|
|
{
|
2002-09-18 02:50:53 +04:00
|
|
|
if (i->sibIndex() != 4)
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R15 + (BX_READ_64BIT_REG(i->sibIndex()) << i->sibScale()) + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
else
|
2002-09-18 09:36:48 +04:00
|
|
|
RMAddr(i) = R15 + (Bit32s) i->displ32u();
|
2002-09-13 19:53:22 +04:00
|
|
|
}
|
|
|
|
|
2002-11-19 08:47:45 +03:00
|
|
|
#endif /* if BX_SUPPORT_X86_64 */
|