⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 disassemblerdefines.h

📁 Linux下的类似softice的调试工具
💻 H
📖 第 1 页 / 共 2 页
字号:
/****************************************************************************** * * Copyright (c) 2003 Gerhard W. Gruber * * PROJECT: pICE * $Source: /cvsroot/pice/pice/module/disassemblerdefines.h,v $ * $Revision: 1.3 $ * $Date: 2004/02/17 23:07:36 $ * $Author: lightweave $ * $Name:  $ * * $Log: disassemblerdefines.h,v $ * Revision 1.3  2004/02/17 23:07:36  lightweave * * Improved the DEBUG facillity and replaced the configuration handler with a * new code which now can read MS Windows INI style files. See CHANGES.txt for * more details. * Also added a macro which prevents compiling for kernels before 2.4.19. * * Revision 1.2  2003/06/18 22:00:22  lightweave * DEBUG and DEBUG_SERIAL added * * *****************************************************************************//*******************************************************************************                                                                             **   Module:     disassemblerdefines.h                                         **                                                                             **   Revision:   1.00                                                          **                                                                             **   Date:       3/17/2000                                                     **                                                                             **   Copyright (c) 2000 Goran Devic                                            **                                                                             **   Author:     Goran Devic                                                   **                                                                             ********************************************************************************    Module Description:        This is a header file containing the disassembler defines that are        used in DisassemblerData.h********************************************************************************                                                                             **   Changes:                                                                  **                                                                             **   DATE     DESCRIPTION OF CHANGES                               AUTHOR      ** --------   ---------------------------------------------------  ----------- ** 4/28/2000  Original                                             Goran Devic ** 11/4/2000  Modified for LinIce                                  Goran Devic ** --------   ---------------------------------------------------  ----------- *********************************************************************************   Important Defines                                                         *******************************************************************************/#ifndef _DISASSEMBLERDEFINES_H#define _DISASSEMBLERDEFINES_H/********************************************************************************   Groups and special codes in place of name index*******************************************************************************/#define _NDEF          0x00     // Udefined/reserved opcode#define _2BESC         0x01     // 2 byte escape code#define _S_ES          0x02     // Segment ES override | these defines#define _S_CS          0x03     // Segment CS override | must have#define _S_SS          0x04     // Segment SS override | consecutive#define _S_DS          0x05     // Segment DS override | enumeration#define _S_FS          0x06     // Segment FS override | numbers.#define _S_GS          0x07     // Segment GS override |#define _OPSIZ         0x08     // Operand size override#define _ADSIZ         0x09     // Address size override#define _REPNE         0x0A     // REPNE/REPNZ prefix#define _REP           0x0B     // REP/REPE/REPZ prefix#define _EscD8         0x0C     // Escape to coprocessor set: prefix D8#define _EscD9         0x0D     // Escape to coprocessor set: prefix D9#define _EscDA         0x0E     // Escape to coprocessor set: prefix DA#define _EscDB         0x0F     // Escape to coprocessor set: prefix DB#define _EscDC         0x10     // Escape to coprocessor set: prefix DC#define _EscDD         0x11     // Escape to coprocessor set: prefix DD#define _EscDE         0x12     // Escape to coprocessor set: prefix DE#define _EscDF         0x13     // Escape to coprocessor set: prefix DF#define _GRP1a         0x14     // Group 1a extended opcode#define _GRP1b         0x15     // Group 1b extended opcode#define _GRP1c         0x16     // Group 1c extended opcode#define _GRP2a         0x17     // Group 2a extended opcode#define _GRP2b         0x18     // Group 2b extended opcode#define _GRP2c         0x19     // Group 2c extended opcode#define _GRP2d         0x1A     // Group 2d extended opcode#define _GRP2e         0x1B     // Group 2e extended opcode#define _GRP2f         0x1C     // Group 2f extended opcode#define _GRP3a         0x1D     // Group 3a extended opcode#define _GRP3b         0x1E     // Group 3b extended opcode#define _GRP4          0x1F     // Group 4 extended opcode#define _GRP5          0x20     // Group 5 extended opcode#define _GRP6          0x21     // Group 6 extended opcode#define _GRP7          0x22     // Group 7 extended opcode#define _GRP8          0x23     // Group 8 extended opcode#define _GRP9          0x24     // Group 9 extended opcode/********************************************************************************   Addressing modes argument definiton for the opcodes in a table*******************************************************************************/#define _O             0x01#define _Ib            0x03#define _Iv            0x04#define _Iw            0x05#define _Yb            0x06#define _Yv            0x07#define _Xb            0x08#define _Xv            0x09#define _Jb            0x0A#define _Jv            0x0B#define _Ap            0x0C#define _1             0x10#define _3             0x11#define _DX            0x12#define _AL            0x13#define _AH            0x14#define _BL            0x15#define _BH            0x16#define _CL            0x17#define _CH            0x18#define _DL            0x19#define _DH            0x1A#define _CS            0x1B#define _DS            0x1C#define _ES            0x1D#define _SS            0x1E#define _FS            0x1F#define _GS            0x20#define _eAX           0x21#define _eCX           0x22#define _eDX           0x23#define _eBX           0x24#define _eSP           0x25#define _eBP           0x26#define _eSI           0x27#define _eDI           0x28#define _Eb            0x2F#define _Ev            0x30#define _Ew            0x31#define _Ep            0x32#define _Gb            0x33#define _Gv            0x34#define _M             0x35#define _Ma            0x36#define _Mp            0x37#define _Ms            0x38#define _Mq            0x39#define _Rd            0x3A#define _Rw            0x3B#define _Sw            0x3C#define _Cd            0x3D#define _Dd            0x3E#define _Td            0x3F#define _ST            0x40#define _ST0           0x41#define _ST1           0x42#define _ST2           0x43#define _ST3           0x44#define _ST4           0x45#define _ST5           0x46#define _ST6           0x47#define _ST7           0x48#define _AX            0x49/********************************************************************************   Define holding structure for opcode*******************************************************************************/typedef struct{    UCHAR    name;               // Index into the opcode name table    UCHAR    args;               // Number of addressing codes that follow    UCHAR    dest;               // Destination operand addressing code    UCHAR    src;                // Source operand addressing code    UCHAR    thrid;              // Third operand addressing code    UCHAR    v_instruction;      // Virtual instruction index    UCHAR    access;             // Instruction data access type    UCHAR    flags;              // Miscellaneous flags} TOpcodeData;// `access' field:// Data access flags are used with memory access instructions#define INSTR_READ                  0x80      // Faulting instruction reads memory#define INSTR_WRITE                 0x40      // Faulting instruction writes to memory#define INSTR_READ_WRITE            0x20      // Faulting instruction is read-modify-write// Low nibble contains the data length code - do not change these values as// they represent the data width value as well#define INSTR_BYTE                  0x01      // Byte access instruction#define INSTR_WORD                  0x02      // Word access instruction#define INSTR_WORD_DWORD            0x03      // Word or dword, depending on operand size#define INSTR_DWORD                 0x04      // Dword access instruction// `flags' field:// Disassembler flags; bottom 4 bits are used by the scanner flags#define DIS_SPECIAL                 0x80      // Special opcode#define DIS_NAME_FLAG               0x40      // Name changes#define   DIS_GETNAMEFLAG(flags)    (((flags)>>6)&1)#define DIS_COPROC                  0x20      // Coprocessor instruction#define DIS_MODRM                   0x10      // Use additional Mod R/M byte// Scanner enums: 4 bits wide#define SCAN_NATIVE                 0x0     // Native instruction are default 0#define SCAN_JUMP                   0x1     // Evaluate new path#define SCAN_COND_JUMP              0x2     // Evaluate both paths#define SCAN_TERMINATING            0x3     // Terminating instruction needs virtualization#define SCAN_TERM_PMODE             0x4     // Terminating instruction in protected mode only#define SCAN_SINGLE_STEP            0x5     // Single-step instruction// Define values stored in meta pages (bits [7:4])#define META_NATIVE                 0x0     // Native instruction are default 0#define META_UNDEF                  0x1     // Undefined/illegal instruction#define META_TERMINATING            0x2     // Terminating instruction#define META_SINGLE_STEP            0x3     // Execute natively single step/*******************************************************************************                                                                             **   Define opcode values for the main table                                   **                                                                             *******************************************************************************/#define _aaa           0x001#define _aad           0x002#define _aam           0x003#define _aas           0x004#define _adc           0x005#define _add           0x006#define _and           0x007#define _arpl          0x008#define _bound         0x009#define _bsf           0x00a#define _bsr           0x00b#define _bt            0x00c#define _btc           0x00d#define _btr           0x00e#define _bts           0x00f#define _call          0x010#define _cbw           0x011#define _cwde          0x012#define _clc           0x013#define _cld           0x014#define _cli           0x015#define _clts          0x016#define _cmc           0x017#define _cmp           0x018#define _cmps          0x019#define _cmpsb         0x01a#define _cmpsw         0x01b#define _cmpsd         0x01c#define _cwd           0x01d#define _cdq           0x01e#define _daa           0x01f#define _das           0x020#define _dec           0x021#define _div           0x022#define _enter         0x023

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -