2006-04-27 19:11:45 +04:00
|
|
|
/////////////////////////////////////////////////////////////////////////
|
2011-02-25 01:05:47 +03:00
|
|
|
// $Id$
|
2006-04-27 19:11:45 +04:00
|
|
|
/////////////////////////////////////////////////////////////////////////
|
2009-10-15 00:45:29 +04:00
|
|
|
//
|
2012-10-09 19:16:48 +04:00
|
|
|
// Copyright (c) 2005-2012 Stanislav Shwartsman
|
2009-10-15 00:45:29 +04:00
|
|
|
// Written by Stanislav Shwartsman [sshwarts at sourceforge net]
|
|
|
|
//
|
|
|
|
// 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
2006-04-27 19:11:45 +04:00
|
|
|
|
2003-12-27 12:27:26 +03:00
|
|
|
#ifndef _BX_DISASM_TABLES_
|
|
|
|
#define _BX_DISASM_TABLES_
|
|
|
|
|
2004-12-10 17:04:57 +03:00
|
|
|
// opcode table attributes
|
2005-12-23 17:15:13 +03:00
|
|
|
#define _GROUPN 1
|
|
|
|
#define _SPLIT11B 2
|
|
|
|
#define _GRPFP 3
|
|
|
|
#define _GRP3DNOW 4
|
|
|
|
#define _GRPSSE 5
|
2010-01-31 12:45:27 +03:00
|
|
|
#define _GRPSSE66 6
|
|
|
|
#define _GRPSSEF2 7
|
2010-02-09 22:44:25 +03:00
|
|
|
#define _GRPSSEF3 8
|
2012-10-09 19:16:48 +04:00
|
|
|
#define _GRPSSENONE 9
|
2013-10-11 01:00:26 +04:00
|
|
|
#define _GRPSSE2 10
|
|
|
|
#define _GRPRM 11
|
|
|
|
#define _GRP3BOP 12
|
|
|
|
#define _GRP64B 13
|
|
|
|
#define _GRPVEXW 14
|
2003-12-27 12:27:26 +03:00
|
|
|
|
2004-12-10 17:04:57 +03:00
|
|
|
/* ************************************************************************ */
|
2005-12-23 17:15:13 +03:00
|
|
|
#define GRPSSE(n) _GRPSSE, BxDisasmGroupSSE_##n
|
2013-10-11 01:00:26 +04:00
|
|
|
#define GRPSSE2(n) _GRPSSE2, BxDisasmGroupSSE_##n
|
2011-03-19 23:09:34 +03:00
|
|
|
#define GRPAVX(n) _GRPSSE, BxDisasmGroupAVX_##n
|
2013-10-12 00:09:51 +04:00
|
|
|
#define GRPAVX2(n) _GRPSSE2, BxDisasmGroupAVX_##n
|
2005-12-23 17:15:13 +03:00
|
|
|
#define GRPN(n) _GROUPN, BxDisasmGroup##n
|
|
|
|
#define GRPRM(n) _GRPRM, BxDisasmGroupRm##n
|
|
|
|
#define GRPMOD(n) _SPLIT11B, BxDisasmGroupMod##n
|
|
|
|
#define GRPFP(n) _GRPFP, BxDisasmFPGroup##n
|
|
|
|
#define GRP3DNOW _GRP3DNOW, BxDisasm3DNowGroup
|
2008-02-29 06:02:03 +03:00
|
|
|
#define GR3BTAB(n) _GRP3BOP, BxDisasm3ByteOpTable##n
|
2007-04-19 20:12:21 +04:00
|
|
|
#define GR64BIT(n) _GRP64B, BxDisasmGrpOs64B_##n
|
2011-08-25 00:55:23 +04:00
|
|
|
#define GRPVEXW(n) _GRPVEXW, BxDisasmGrpVexW_##n
|
2003-12-27 12:27:26 +03:00
|
|
|
/* ************************************************************************ */
|
|
|
|
|
2010-01-31 13:17:42 +03:00
|
|
|
/* ************************************************************************ */
|
2012-10-09 19:16:48 +04:00
|
|
|
#define GRPSSE66(n) _GRPSSE66, &n
|
|
|
|
#define GRPSSEF2(n) _GRPSSEF2, &n
|
|
|
|
#define GRPSSEF3(n) _GRPSSEF3, &n
|
|
|
|
#define GRPSSENONE(n) _GRPSSENONE, &n
|
2010-01-31 13:17:42 +03:00
|
|
|
/* ************************************************************************ */
|
|
|
|
|
2005-12-23 17:15:13 +03:00
|
|
|
#define Apw &disassembler::Apw
|
|
|
|
#define Apd &disassembler::Apd
|
|
|
|
|
2009-01-19 22:01:03 +03:00
|
|
|
#define AL_Reg &disassembler::AL_Reg
|
|
|
|
#define CL_Reg &disassembler::CL_Reg
|
|
|
|
#define AX_Reg &disassembler::AX_Reg
|
|
|
|
#define DX_Reg &disassembler::DX_Reg
|
2005-12-23 17:15:13 +03:00
|
|
|
|
2009-01-19 22:01:03 +03:00
|
|
|
#define EAX_Reg &disassembler::EAX_Reg
|
|
|
|
#define RAX_Reg &disassembler::RAX_Reg
|
2011-12-25 23:35:29 +04:00
|
|
|
#define RCX_Reg &disassembler::RCX_Reg
|
2005-12-23 17:15:13 +03:00
|
|
|
|
2009-01-19 22:01:03 +03:00
|
|
|
#define CS &disassembler::CS
|
|
|
|
#define DS &disassembler::DS
|
|
|
|
#define ES &disassembler::ES
|
|
|
|
#define SS &disassembler::SS
|
|
|
|
#define FS &disassembler::FS
|
|
|
|
#define GS &disassembler::GS
|
2005-12-23 17:15:13 +03:00
|
|
|
|
2009-01-19 22:01:03 +03:00
|
|
|
#define Sw &disassembler::Sw
|
2005-12-23 17:15:13 +03:00
|
|
|
|
2009-01-19 22:01:03 +03:00
|
|
|
#define Cd &disassembler::Cd
|
|
|
|
#define Cq &disassembler::Cq
|
2005-12-23 17:15:13 +03:00
|
|
|
|
2009-01-19 22:01:03 +03:00
|
|
|
#define Dd &disassembler::Dd
|
|
|
|
#define Dq &disassembler::Dq
|
2005-12-23 17:15:13 +03:00
|
|
|
|
2009-01-19 22:01:03 +03:00
|
|
|
#define Reg8 &disassembler::Reg8
|
|
|
|
#define RX &disassembler::RX
|
|
|
|
#define ERX &disassembler::ERX
|
|
|
|
#define RRX &disassembler::RRX
|
2005-12-23 17:15:13 +03:00
|
|
|
|
2010-04-02 23:01:17 +04:00
|
|
|
#define Eb &disassembler::Eb
|
|
|
|
#define Ew &disassembler::Ew
|
|
|
|
#define Ed &disassembler::Ed
|
|
|
|
#define Eq &disassembler::Eq
|
|
|
|
#define Ey &disassembler::Ey
|
|
|
|
#define Ebd &disassembler::Ebd
|
|
|
|
#define Ewd &disassembler::Ewd
|
2005-12-23 17:15:13 +03:00
|
|
|
|
2009-01-19 22:01:03 +03:00
|
|
|
#define Gb &disassembler::Gb
|
|
|
|
#define Gw &disassembler::Gw
|
|
|
|
#define Gd &disassembler::Gd
|
|
|
|
#define Gq &disassembler::Gq
|
2010-03-26 13:39:40 +03:00
|
|
|
#define Gy &disassembler::Gy
|
2005-12-23 17:15:13 +03:00
|
|
|
|
2011-08-27 17:47:16 +04:00
|
|
|
#define By &disassembler::By
|
|
|
|
|
2009-01-19 22:01:03 +03:00
|
|
|
#define I1 &disassembler::I1
|
|
|
|
#define Ib &disassembler::Ib
|
|
|
|
#define Iw &disassembler::Iw
|
|
|
|
#define Id &disassembler::Id
|
|
|
|
#define Iq &disassembler::Iq
|
2005-12-23 17:15:13 +03:00
|
|
|
|
2007-09-19 23:38:10 +04:00
|
|
|
#define IbIb &disassembler::IbIb
|
2006-03-23 20:43:39 +03:00
|
|
|
#define IwIb &disassembler::IwIb
|
|
|
|
|
2005-12-23 17:15:13 +03:00
|
|
|
#define sIbw &disassembler::sIbw
|
|
|
|
#define sIbd &disassembler::sIbd
|
|
|
|
#define sIbq &disassembler::sIbq
|
|
|
|
#define sIdq &disassembler::sIdq
|
|
|
|
|
|
|
|
#define ST0 &disassembler::ST0
|
|
|
|
#define STi &disassembler::STi
|
|
|
|
|
2009-01-19 22:01:03 +03:00
|
|
|
#define Rw &disassembler::Rw
|
|
|
|
#define Rd &disassembler::Rd
|
|
|
|
#define Rq &disassembler::Rq
|
2010-07-22 19:12:08 +04:00
|
|
|
#define Ry &disassembler::Ry
|
2005-12-23 17:15:13 +03:00
|
|
|
|
2009-01-19 22:01:03 +03:00
|
|
|
#define Pq &disassembler::Pq
|
|
|
|
#define Qd &disassembler::Qd
|
|
|
|
#define Qq &disassembler::Qq
|
|
|
|
#define Nq &disassembler::Nq
|
2005-12-23 17:15:13 +03:00
|
|
|
|
|
|
|
#define Vq &disassembler::Vq
|
|
|
|
#define Vdq &disassembler::Vdq
|
|
|
|
#define Vss &disassembler::Vss
|
|
|
|
#define Vsd &disassembler::Vsd
|
|
|
|
#define Vps &disassembler::Vps
|
|
|
|
#define Vpd &disassembler::Vpd
|
2011-03-19 23:09:34 +03:00
|
|
|
#define VIb &disassembler::VIb
|
2010-03-19 17:43:13 +03:00
|
|
|
|
|
|
|
#define Ups &disassembler::Ups
|
|
|
|
#define Upd &disassembler::Upd
|
2006-02-17 16:33:05 +03:00
|
|
|
#define Udq &disassembler::Udq
|
2011-09-18 20:18:22 +04:00
|
|
|
#define Uq &disassembler::Uq
|
2005-12-23 17:15:13 +03:00
|
|
|
|
2011-08-25 00:55:23 +04:00
|
|
|
#define Wb &disassembler::Wb
|
2007-04-19 20:12:21 +04:00
|
|
|
#define Ww &disassembler::Ww
|
|
|
|
#define Wd &disassembler::Wd
|
2005-12-23 17:15:13 +03:00
|
|
|
#define Wq &disassembler::Wq
|
|
|
|
#define Wdq &disassembler::Wdq
|
|
|
|
#define Wss &disassembler::Wss
|
|
|
|
#define Wsd &disassembler::Wsd
|
|
|
|
#define Wps &disassembler::Wps
|
|
|
|
#define Wpd &disassembler::Wpd
|
|
|
|
|
2011-03-19 23:09:34 +03:00
|
|
|
#define Hdq &disassembler::Hdq
|
|
|
|
#define Hps &disassembler::Hps
|
|
|
|
#define Hpd &disassembler::Hpd
|
2011-09-29 23:50:27 +04:00
|
|
|
#define Hss &disassembler::Hss
|
|
|
|
#define Hsd &disassembler::Hsd
|
2011-03-19 23:09:34 +03:00
|
|
|
|
2009-01-19 22:01:03 +03:00
|
|
|
#define Ob &disassembler::Ob
|
|
|
|
#define Ow &disassembler::Ow
|
|
|
|
#define Od &disassembler::Od
|
|
|
|
#define Oq &disassembler::Oq
|
2005-12-23 17:15:13 +03:00
|
|
|
|
|
|
|
#define Ma &disassembler::Ma
|
|
|
|
#define Mp &disassembler::Mp
|
|
|
|
#define Ms &disassembler::Ms
|
|
|
|
#define Mx &disassembler::Mx
|
|
|
|
#define Mb &disassembler::Mb
|
|
|
|
#define Mw &disassembler::Mw
|
|
|
|
#define Md &disassembler::Md
|
|
|
|
#define Mq &disassembler::Mq
|
|
|
|
#define Mt &disassembler::Mt
|
|
|
|
#define Mdq &disassembler::Mdq
|
|
|
|
#define Mps &disassembler::Mps
|
|
|
|
#define Mpd &disassembler::Mpd
|
2007-08-31 22:09:34 +04:00
|
|
|
#define Mss &disassembler::Mss
|
|
|
|
#define Msd &disassembler::Msd
|
2005-12-23 17:15:13 +03:00
|
|
|
|
2011-08-29 01:38:53 +04:00
|
|
|
#define VSib &disassembler::VSib
|
|
|
|
|
2009-01-19 22:01:03 +03:00
|
|
|
#define Xb &disassembler::Xb
|
|
|
|
#define Xw &disassembler::Xw
|
|
|
|
#define Xd &disassembler::Xd
|
|
|
|
#define Xq &disassembler::Xq
|
2005-12-23 17:15:13 +03:00
|
|
|
|
2009-01-19 22:01:03 +03:00
|
|
|
#define Yb &disassembler::Yb
|
|
|
|
#define Yw &disassembler::Yw
|
|
|
|
#define Yd &disassembler::Yd
|
|
|
|
#define Yq &disassembler::Yq
|
2005-12-23 17:15:13 +03:00
|
|
|
|
2009-08-21 17:45:38 +04:00
|
|
|
#define sYq &disassembler::sYq
|
|
|
|
#define sYdq &disassembler::sYdq
|
|
|
|
|
2009-01-19 22:01:03 +03:00
|
|
|
#define Jb &disassembler::Jb
|
|
|
|
#define Jw &disassembler::Jw
|
|
|
|
#define Jd &disassembler::Jd
|
2005-12-23 17:15:13 +03:00
|
|
|
|
2009-01-19 22:01:03 +03:00
|
|
|
#define XX 0
|
2005-12-23 17:15:13 +03:00
|
|
|
|
|
|
|
const struct BxDisasmOpcodeInfo_t
|
|
|
|
#include "opcodes.inc"
|
2010-02-08 18:11:58 +03:00
|
|
|
#include "dis_tables_x87.inc"
|
|
|
|
#include "dis_tables_sse.inc"
|
2011-03-19 23:09:34 +03:00
|
|
|
#include "dis_tables_avx.inc"
|
2011-10-30 12:58:49 +04:00
|
|
|
#include "dis_tables_xop.inc"
|
2005-12-23 17:15:13 +03:00
|
|
|
#include "dis_tables.inc"
|
2003-12-27 12:27:26 +03:00
|
|
|
|
|
|
|
#undef XX
|
|
|
|
|
|
|
|
#endif
|