mirror of https://github.com/x64dbg/zydis
Refactored docstrings to use uppercase abbreviations
This commit is contained in:
parent
a9514fbfea
commit
689708fbd3
|
@ -96,35 +96,35 @@ enum ZydisOperandEncodings
|
||||||
{
|
{
|
||||||
ZYDIS_OPERAND_ENCODING_NONE,
|
ZYDIS_OPERAND_ENCODING_NONE,
|
||||||
/**
|
/**
|
||||||
* @brief The operand is encoded in the modrm.reg field.
|
* @brief The operand is encoded in the ModRM.reg field.
|
||||||
*/
|
*/
|
||||||
ZYDIS_OPERAND_ENCODING_REG,
|
ZYDIS_OPERAND_ENCODING_REG,
|
||||||
/**
|
/**
|
||||||
* @brief The operand is encoded in the modrm.rm field.
|
* @brief The operand is encoded in the ModRM.rm field.
|
||||||
*/
|
*/
|
||||||
ZYDIS_OPERAND_ENCODING_RM,
|
ZYDIS_OPERAND_ENCODING_RM,
|
||||||
/**
|
/**
|
||||||
* @brief The operand is encoded in the modrm.rm field and uses the compressed-disp8 form.
|
* @brief The operand is encoded in the ModRM.rm field and uses the compressed-disp8 form.
|
||||||
*/
|
*/
|
||||||
ZYDIS_OPERAND_ENCODING_RM_CD2,
|
ZYDIS_OPERAND_ENCODING_RM_CD2,
|
||||||
/**
|
/**
|
||||||
* @brief The operand is encoded in the modrm.rm field and uses the compressed-disp8 form.
|
* @brief The operand is encoded in the ModRM.rm field and uses the compressed-disp8 form.
|
||||||
*/
|
*/
|
||||||
ZYDIS_OPERAND_ENCODING_RM_CD4,
|
ZYDIS_OPERAND_ENCODING_RM_CD4,
|
||||||
/**
|
/**
|
||||||
* @brief The operand is encoded in the modrm.rm field and uses the compressed-disp8 form.
|
* @brief The operand is encoded in the ModRM.rm field and uses the compressed-disp8 form.
|
||||||
*/
|
*/
|
||||||
ZYDIS_OPERAND_ENCODING_RM_CD8,
|
ZYDIS_OPERAND_ENCODING_RM_CD8,
|
||||||
/**
|
/**
|
||||||
* @brief The operand is encoded in the modrm.rm field and uses the compressed-disp8 form.
|
* @brief The operand is encoded in the ModRM.rm field and uses the compressed-disp8 form.
|
||||||
*/
|
*/
|
||||||
ZYDIS_OPERAND_ENCODING_RM_CD16,
|
ZYDIS_OPERAND_ENCODING_RM_CD16,
|
||||||
/**
|
/**
|
||||||
* @brief The operand is encoded in the modrm.rm field and uses the compressed-disp8 form.
|
* @brief The operand is encoded in the ModRM.rm field and uses the compressed-disp8 form.
|
||||||
*/
|
*/
|
||||||
ZYDIS_OPERAND_ENCODING_RM_CD32,
|
ZYDIS_OPERAND_ENCODING_RM_CD32,
|
||||||
/**
|
/**
|
||||||
* @brief The operand is encoded in the modrm.rm field and uses the compressed-disp8 form.
|
* @brief The operand is encoded in the ModRM.rm field and uses the compressed-disp8 form.
|
||||||
*/
|
*/
|
||||||
ZYDIS_OPERAND_ENCODING_RM_CD64,
|
ZYDIS_OPERAND_ENCODING_RM_CD64,
|
||||||
/**
|
/**
|
||||||
|
@ -132,11 +132,11 @@ enum ZydisOperandEncodings
|
||||||
*/
|
*/
|
||||||
ZYDIS_OPERAND_ENCODING_OPCODE,
|
ZYDIS_OPERAND_ENCODING_OPCODE,
|
||||||
/**
|
/**
|
||||||
* @brief The operand is encoded in the vex/evex.vvvv field.
|
* @brief The operand is encoded in the VEX/EVEX.vvvv field.
|
||||||
*/
|
*/
|
||||||
ZYDIS_OPERAND_ENCODING_VVVV,
|
ZYDIS_OPERAND_ENCODING_VVVV,
|
||||||
/**
|
/**
|
||||||
* @brief The operand is encoded in the evex.aaa field.
|
* @brief The operand is encoded in the EVEX.aaa field.
|
||||||
*/
|
*/
|
||||||
ZYDIS_OPERAND_ENCODING_AAA,
|
ZYDIS_OPERAND_ENCODING_AAA,
|
||||||
/**
|
/**
|
||||||
|
@ -468,27 +468,27 @@ enum ZydisOpcodeMaps
|
||||||
typedef uint64_t ZydisInstructionAttributes;
|
typedef uint64_t ZydisInstructionAttributes;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief The instruction has the modrm byte.
|
* @brief The instruction has the ModRM byte.
|
||||||
*/
|
*/
|
||||||
#define ZYDIS_ATTRIB_HAS_MODRM 0x0000000000000001
|
#define ZYDIS_ATTRIB_HAS_MODRM 0x0000000000000001
|
||||||
/**
|
/**
|
||||||
* @brief The instruction has the sib byte.
|
* @brief The instruction has the SUB byte.
|
||||||
*/
|
*/
|
||||||
#define ZYDIS_ATTRIB_HAS_SIB 0x0000000000000002
|
#define ZYDIS_ATTRIB_HAS_SIB 0x0000000000000002
|
||||||
/**
|
/**
|
||||||
* @brief The instruction has the rex prefix.
|
* @brief The instruction has the REX prefix.
|
||||||
*/
|
*/
|
||||||
#define ZYDIS_ATTRIB_HAS_REX 0x0000000000000004
|
#define ZYDIS_ATTRIB_HAS_REX 0x0000000000000004
|
||||||
/**
|
/**
|
||||||
* @brief The instruction has the xop prefix.
|
* @brief The instruction has the XOP prefix.
|
||||||
*/
|
*/
|
||||||
#define ZYDIS_ATTRIB_HAS_XOP 0x0000000000000008
|
#define ZYDIS_ATTRIB_HAS_XOP 0x0000000000000008
|
||||||
/**
|
/**
|
||||||
* @brief The instruction has the vex prefix.
|
* @brief The instruction has the VEX prefix.
|
||||||
*/
|
*/
|
||||||
#define ZYDIS_ATTRIB_HAS_VEX 0x0000000000000010
|
#define ZYDIS_ATTRIB_HAS_VEX 0x0000000000000010
|
||||||
/**
|
/**
|
||||||
* @brief The instruction has the evex prefix.
|
* @brief The instruction has the EVEX prefix.
|
||||||
*/
|
*/
|
||||||
#define ZYDIS_ATTRIB_HAS_EVEX 0x0000000000000020
|
#define ZYDIS_ATTRIB_HAS_EVEX 0x0000000000000020
|
||||||
/**
|
/**
|
||||||
|
@ -687,7 +687,7 @@ enum ZydisAVX512MaskModes
|
||||||
{
|
{
|
||||||
ZYDIS_AVX512_MASKMODE_INVALID,
|
ZYDIS_AVX512_MASKMODE_INVALID,
|
||||||
/**
|
/**
|
||||||
* @brief Merge mode. This is the default mode for all evex-instructions.
|
* @brief Merge mode. This is the default mode for all EVEX-instructions.
|
||||||
*/
|
*/
|
||||||
ZYDIS_AVX512_MASKMODE_MERGE,
|
ZYDIS_AVX512_MASKMODE_MERGE,
|
||||||
/**
|
/**
|
||||||
|
@ -788,7 +788,7 @@ typedef struct ZydisInstructionInfo_
|
||||||
*/
|
*/
|
||||||
uint8_t data[15];
|
uint8_t data[15];
|
||||||
/**
|
/**
|
||||||
* @brief The instruction-encoding (default, 3dnow, vex, evex, xop).
|
* @brief The instruction-encoding (default, 3DNow, VEX, EVEX, XOP).
|
||||||
*/
|
*/
|
||||||
ZydisInstructionEncoding encoding;
|
ZydisInstructionEncoding encoding;
|
||||||
/**
|
/**
|
||||||
|
@ -854,7 +854,7 @@ typedef struct ZydisInstructionInfo_
|
||||||
ZydisBool hasSAE;
|
ZydisBool hasSAE;
|
||||||
} avx;
|
} avx;
|
||||||
/**
|
/**
|
||||||
* @brief Extended info about different instruction-parts like modrm, sib or
|
* @brief Extended info about different instruction-parts like ModRM, SIB or
|
||||||
* encoding-prefixes.
|
* encoding-prefixes.
|
||||||
*/
|
*/
|
||||||
struct
|
struct
|
||||||
|
@ -877,7 +877,7 @@ typedef struct ZydisInstructionInfo_
|
||||||
uint8_t has67;
|
uint8_t has67;
|
||||||
} prefixes;
|
} prefixes;
|
||||||
/**
|
/**
|
||||||
* @brief Detailed info about the rex-prefix.
|
* @brief Detailed info about the REX-prefix.
|
||||||
*/
|
*/
|
||||||
struct
|
struct
|
||||||
{
|
{
|
||||||
|
@ -894,20 +894,20 @@ typedef struct ZydisInstructionInfo_
|
||||||
*/
|
*/
|
||||||
uint8_t W;
|
uint8_t W;
|
||||||
/**
|
/**
|
||||||
* @brief Extension of the modrm.reg field.
|
* @brief Extension of the ModRM.reg field.
|
||||||
*/
|
*/
|
||||||
uint8_t R;
|
uint8_t R;
|
||||||
/**
|
/**
|
||||||
* @brief Extension of the sib.index field.
|
* @brief Extension of the SIB.index field.
|
||||||
*/
|
*/
|
||||||
uint8_t X;
|
uint8_t X;
|
||||||
/**
|
/**
|
||||||
* @brief Extension of the modrm.rm, sib.base, or opcode.reg field.
|
* @brief Extension of the ModRM.rm, SIB.base, or opcode.reg field.
|
||||||
*/
|
*/
|
||||||
uint8_t B;
|
uint8_t B;
|
||||||
} rex;
|
} rex;
|
||||||
/**
|
/**
|
||||||
* @brief Detailed info about the xop-prefix.
|
* @brief Detailed info about the XOP-prefix.
|
||||||
*/
|
*/
|
||||||
struct
|
struct
|
||||||
{
|
{
|
||||||
|
@ -920,15 +920,15 @@ typedef struct ZydisInstructionInfo_
|
||||||
*/
|
*/
|
||||||
uint8_t data[3];
|
uint8_t data[3];
|
||||||
/**
|
/**
|
||||||
* @brief Extension of the modrm.reg field (inverted).
|
* @brief Extension of the ModRM.reg field (inverted).
|
||||||
*/
|
*/
|
||||||
uint8_t R;
|
uint8_t R;
|
||||||
/**
|
/**
|
||||||
* @brief Extension of the sib.index field (inverted).
|
* @brief Extension of the SIB.index field (inverted).
|
||||||
*/
|
*/
|
||||||
uint8_t X;
|
uint8_t X;
|
||||||
/**
|
/**
|
||||||
* @brief Extension of the modrm.rm, sib.base, or opcode.reg field (inverted).
|
* @brief Extension of the ModRM.rm, SIB.base, or opcode.reg field (inverted).
|
||||||
*/
|
*/
|
||||||
uint8_t B;
|
uint8_t B;
|
||||||
/**
|
/**
|
||||||
|
@ -953,7 +953,7 @@ typedef struct ZydisInstructionInfo_
|
||||||
uint8_t pp;
|
uint8_t pp;
|
||||||
} xop;
|
} xop;
|
||||||
/**
|
/**
|
||||||
* @brief Detailed info about the vex-prefix.
|
* @brief Detailed info about the VEX-prefix.
|
||||||
*/
|
*/
|
||||||
struct
|
struct
|
||||||
{
|
{
|
||||||
|
@ -966,15 +966,15 @@ typedef struct ZydisInstructionInfo_
|
||||||
*/
|
*/
|
||||||
uint8_t data[3];
|
uint8_t data[3];
|
||||||
/**
|
/**
|
||||||
* @brief Extension of the modrm.reg field (inverted).
|
* @brief Extension of the ModRM.reg field (inverted).
|
||||||
*/
|
*/
|
||||||
uint8_t R;
|
uint8_t R;
|
||||||
/**
|
/**
|
||||||
* @brief Extension of the sib.index field (inverted).
|
* @brief Extension of the SIB.index field (inverted).
|
||||||
*/
|
*/
|
||||||
uint8_t X;
|
uint8_t X;
|
||||||
/**
|
/**
|
||||||
* @brief Extension of the modrm.rm, sib.base, or opcode.reg field (inverted).
|
* @brief Extension of the ModRM.rm, SIB.base, or opcode.reg field (inverted).
|
||||||
*/
|
*/
|
||||||
uint8_t B;
|
uint8_t B;
|
||||||
/**
|
/**
|
||||||
|
@ -999,7 +999,7 @@ typedef struct ZydisInstructionInfo_
|
||||||
uint8_t pp;
|
uint8_t pp;
|
||||||
} vex;
|
} vex;
|
||||||
/**
|
/**
|
||||||
* @brief Detailed info about the evex-prefix.
|
* @brief Detailed info about the EVEX-prefix.
|
||||||
*/
|
*/
|
||||||
struct
|
struct
|
||||||
{
|
{
|
||||||
|
@ -1012,15 +1012,15 @@ typedef struct ZydisInstructionInfo_
|
||||||
*/
|
*/
|
||||||
uint8_t data[4];
|
uint8_t data[4];
|
||||||
/**
|
/**
|
||||||
* @brief Extension of the modrm.reg field (inverted).
|
* @brief Extension of the ModRM.reg field (inverted).
|
||||||
*/
|
*/
|
||||||
uint8_t R;
|
uint8_t R;
|
||||||
/**
|
/**
|
||||||
* @brief Extension of the sib.index/vidx field (inverted).
|
* @brief Extension of the SIB.index/vidx field (inverted).
|
||||||
*/
|
*/
|
||||||
uint8_t X;
|
uint8_t X;
|
||||||
/**
|
/**
|
||||||
* @brief Extension of the modrm.rm or sib.base field (inverted).
|
* @brief Extension of the ModRM.rm or SIB.base field (inverted).
|
||||||
*/
|
*/
|
||||||
uint8_t B;
|
uint8_t B;
|
||||||
/**
|
/**
|
||||||
|
@ -1069,7 +1069,7 @@ typedef struct ZydisInstructionInfo_
|
||||||
uint8_t aaa;
|
uint8_t aaa;
|
||||||
} evex;
|
} evex;
|
||||||
/**
|
/**
|
||||||
* @brief Detailed info about the modrm-byte.
|
* @brief Detailed info about the ModRM-byte.
|
||||||
*/
|
*/
|
||||||
struct
|
struct
|
||||||
{
|
{
|
||||||
|
@ -1080,7 +1080,7 @@ typedef struct ZydisInstructionInfo_
|
||||||
uint8_t rm;
|
uint8_t rm;
|
||||||
} modrm;
|
} modrm;
|
||||||
/**
|
/**
|
||||||
* @brief Detailed info about the sib-byte.
|
* @brief Detailed info about the SIB-byte.
|
||||||
*/
|
*/
|
||||||
struct
|
struct
|
||||||
{
|
{
|
||||||
|
|
|
@ -138,11 +138,11 @@ enum ZydisInstructionTableNodeTypes
|
||||||
*/
|
*/
|
||||||
ZYDIS_NODETYPE_FILTER_OPCODE = 0x07,
|
ZYDIS_NODETYPE_FILTER_OPCODE = 0x07,
|
||||||
/**
|
/**
|
||||||
* @brief Reference to an vex/evex-map filter.
|
* @brief Reference to an VEX/EVEX-map filter.
|
||||||
*/
|
*/
|
||||||
ZYDIS_NODETYPE_FILTER_VEX = 0x08,
|
ZYDIS_NODETYPE_FILTER_VEX = 0x08,
|
||||||
/**
|
/**
|
||||||
* @brief Reference to an xop-map filter.
|
* @brief Reference to an XOP-map filter.
|
||||||
*/
|
*/
|
||||||
ZYDIS_NODETYPE_FILTER_XOP = 0x09,
|
ZYDIS_NODETYPE_FILTER_XOP = 0x09,
|
||||||
/**
|
/**
|
||||||
|
@ -154,15 +154,15 @@ enum ZydisInstructionTableNodeTypes
|
||||||
*/
|
*/
|
||||||
ZYDIS_NODETYPE_FILTER_MANDATORYPREFIX = 0x0B,
|
ZYDIS_NODETYPE_FILTER_MANDATORYPREFIX = 0x0B,
|
||||||
/**
|
/**
|
||||||
* @brief Reference to a modrm.mod filter.
|
* @brief Reference to a ModRM.mod filter.
|
||||||
*/
|
*/
|
||||||
ZYDIS_NODETYPE_FILTER_MODRMMOD = 0x0C,
|
ZYDIS_NODETYPE_FILTER_MODRMMOD = 0x0C,
|
||||||
/**
|
/**
|
||||||
* @brief Reference to a modrm.reg filter.
|
* @brief Reference to a ModRM.reg filter.
|
||||||
*/
|
*/
|
||||||
ZYDIS_NODETYPE_FILTER_MODRMREG = 0x0D,
|
ZYDIS_NODETYPE_FILTER_MODRMREG = 0x0D,
|
||||||
/**
|
/**
|
||||||
* @brief Reference to a modrm.rm filter.
|
* @brief Reference to a ModRM.rm filter.
|
||||||
*/
|
*/
|
||||||
ZYDIS_NODETYPE_FILTER_MODRMRM = 0x0E,
|
ZYDIS_NODETYPE_FILTER_MODRMRM = 0x0E,
|
||||||
/**
|
/**
|
||||||
|
@ -174,19 +174,19 @@ enum ZydisInstructionTableNodeTypes
|
||||||
*/
|
*/
|
||||||
ZYDIS_NODETYPE_FILTER_ADDRESSSIZE = 0x10,
|
ZYDIS_NODETYPE_FILTER_ADDRESSSIZE = 0x10,
|
||||||
/**
|
/**
|
||||||
* @brief Reference to an rex/vex/evex.w filter.
|
* @brief Reference to an REX/VEX/EVEX.w filter.
|
||||||
*/
|
*/
|
||||||
ZYDIS_NODETYPE_FILTER_REXW = 0x11,
|
ZYDIS_NODETYPE_FILTER_REXW = 0x11,
|
||||||
/**
|
/**
|
||||||
* @brief Reference to an vex/evex.l filter.
|
* @brief Reference to an VEX/EVEX.l filter.
|
||||||
*/
|
*/
|
||||||
ZYDIS_NODETYPE_FILTER_VEXL = 0x12,
|
ZYDIS_NODETYPE_FILTER_VEXL = 0x12,
|
||||||
/**
|
/**
|
||||||
* @brief Reference to an evex.l' filter.
|
* @brief Reference to an EVEX.l' filter.
|
||||||
*/
|
*/
|
||||||
ZYDIS_NODETYPE_FILTER_EVEXL2 = 0x13,
|
ZYDIS_NODETYPE_FILTER_EVEXL2 = 0x13,
|
||||||
/**
|
/**
|
||||||
* @brief Reference to an evex.b filter.
|
* @brief Reference to an EVEX.b filter.
|
||||||
*/
|
*/
|
||||||
ZYDIS_NODETYPE_FILTER_EVEXB = 0x14
|
ZYDIS_NODETYPE_FILTER_EVEXB = 0x14
|
||||||
};
|
};
|
||||||
|
@ -289,7 +289,7 @@ enum ZydisSemanticOperandTypes
|
||||||
/* ---------------------------------------------------------------------------------------------- */
|
/* ---------------------------------------------------------------------------------------------- */
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Values that represent zydis evex.b-contexts.
|
* @brief Values that represent zydis EVEX.b-contexts.
|
||||||
*/
|
*/
|
||||||
enum ZydisEvexBFunctionalities
|
enum ZydisEvexBFunctionalities
|
||||||
{
|
{
|
||||||
|
|
|
@ -92,19 +92,19 @@ enum ZydisStatusCode
|
||||||
*/
|
*/
|
||||||
ZYDIS_STATUS_ILLEGAL_LOCK,
|
ZYDIS_STATUS_ILLEGAL_LOCK,
|
||||||
/**
|
/**
|
||||||
* @brief A legacy-prefix (F2, F3, 66) was found while decoding a xop/vex/evex instruction.
|
* @brief A legacy-prefix (F2, F3, 66) was found while decoding a XOP/VEX/EVEX instruction.
|
||||||
*/
|
*/
|
||||||
ZYDIS_STATUS_ILLEGAL_LEGACY_PFX,
|
ZYDIS_STATUS_ILLEGAL_LEGACY_PFX,
|
||||||
/**
|
/**
|
||||||
* @brief A rex-prefix was found while decoding a xop/vex/evex instruction.
|
* @brief A rex-prefix was found while decoding a XOP/VEX/EVEX instruction.
|
||||||
*/
|
*/
|
||||||
ZYDIS_STATUS_ILLEGAL_REX,
|
ZYDIS_STATUS_ILLEGAL_REX,
|
||||||
/**
|
/**
|
||||||
* @brief An invalid opcode-map value was found while decoding a xop/vex/evex-prefix.
|
* @brief An invalid opcode-map value was found while decoding a XOP/VEX/EVEX-prefix.
|
||||||
*/
|
*/
|
||||||
ZYDIS_STATUS_INVALID_MAP,
|
ZYDIS_STATUS_INVALID_MAP,
|
||||||
/**
|
/**
|
||||||
* @brief An error occured while decoding the evex-prefix.
|
* @brief An error occured while decoding the EVEX-prefix.
|
||||||
*/
|
*/
|
||||||
ZYDIS_STATUS_MALFORMED_EVEX,
|
ZYDIS_STATUS_MALFORMED_EVEX,
|
||||||
// TODO:
|
// TODO:
|
||||||
|
|
|
@ -137,9 +137,9 @@ static ZydisStatus ZydisInputNext(ZydisInstructionDecoder* decoder, ZydisInstruc
|
||||||
/* ---------------------------------------------------------------------------------------------- */
|
/* ---------------------------------------------------------------------------------------------- */
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Decodes the rex-prefix.
|
* @brief Decodes the REX-prefix.
|
||||||
*
|
*
|
||||||
* @param rexByte The rex byte.
|
* @param rexByte The REX byte.
|
||||||
* @param info A pointer to the @c ZydisInstructionInfo struct.
|
* @param info A pointer to the @c ZydisInstructionInfo struct.
|
||||||
*/
|
*/
|
||||||
static void ZydisDecodeREX(ZydisInstructionInfo* info, uint8_t rexByte)
|
static void ZydisDecodeREX(ZydisInstructionInfo* info, uint8_t rexByte)
|
||||||
|
@ -162,10 +162,10 @@ static void ZydisDecodeREX(ZydisInstructionInfo* info, uint8_t rexByte)
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Decodes the xop-prefix.
|
* @brief Decodes the XOP-prefix.
|
||||||
*
|
*
|
||||||
* @param xopByte1 The first xop byte.
|
* @param xopByte1 The first XOP byte.
|
||||||
* @param xopByte2 The second xop byte.
|
* @param xopByte2 The second XOP byte.
|
||||||
* @param info A pointer to the @c ZydisInstructionInfo struct.
|
* @param info A pointer to the @c ZydisInstructionInfo struct.
|
||||||
*
|
*
|
||||||
* @return A zydis status code.
|
* @return A zydis status code.
|
||||||
|
@ -203,11 +203,11 @@ static ZydisStatus ZydisDecodeXOP(uint8_t xopByte1, uint8_t xopByte2, ZydisInstr
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Decodes the vex-prefix.
|
* @brief Decodes the VEX-prefix.
|
||||||
*
|
*
|
||||||
* @param vexOpcode The vex opcode.
|
* @param vexOpcode The VEX opcode.
|
||||||
* @param vexByte1 The first vex byte.
|
* @param vexByte1 The first VEX byte.
|
||||||
* @param vexByte2 The second vex byte.
|
* @param vexByte2 The second VEX byte.
|
||||||
* @param info A pointer to the @c ZydisInstructionInfo struct.
|
* @param info A pointer to the @c ZydisInstructionInfo struct.
|
||||||
*
|
*
|
||||||
* @return A zydis status code.
|
* @return A zydis status code.
|
||||||
|
@ -264,11 +264,11 @@ static ZydisStatus ZydisDecodeVEX(uint8_t vexOpcode, uint8_t vexByte1, uint8_t v
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Decodes the evex-prefix.
|
* @brief Decodes the EVEX-prefix.
|
||||||
*
|
*
|
||||||
* @param evexByte1 The first evex byte.
|
* @param evexByte1 The first EVEX byte.
|
||||||
* @param evexByte2 The second evex byte.
|
* @param evexByte2 The second EVEX byte.
|
||||||
* @param evexByte3 The third evex byte.
|
* @param evexByte3 The third EVEX byte.
|
||||||
* @param info A pointer to the @c ZydisInstructionInfo struct.
|
* @param info A pointer to the @c ZydisInstructionInfo struct.
|
||||||
*
|
*
|
||||||
* @return A zydis status code.
|
* @return A zydis status code.
|
||||||
|
@ -325,9 +325,9 @@ static ZydisStatus ZydisDecodeEVEX(uint8_t evexByte1, uint8_t evexByte2, uint8_t
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Decodes the modrm-byte.
|
* @brief Decodes the ModRM-byte.
|
||||||
*
|
*
|
||||||
* @param modrmByte The modrm byte.
|
* @param modrmByte The ModRM byte.
|
||||||
* @param info A pointer to the @c ZydisInstructionInfo struct.
|
* @param info A pointer to the @c ZydisInstructionInfo struct.
|
||||||
*/
|
*/
|
||||||
static void ZydisDecodeModRM(uint8_t modrmByte, ZydisInstructionInfo* info)
|
static void ZydisDecodeModRM(uint8_t modrmByte, ZydisInstructionInfo* info)
|
||||||
|
@ -343,9 +343,9 @@ static void ZydisDecodeModRM(uint8_t modrmByte, ZydisInstructionInfo* info)
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Decodes the sib-byte.
|
* @brief Decodes the SIB-byte.
|
||||||
*
|
*
|
||||||
* @param sibByte The sib byte.
|
* @param sibByte The SIB byte.
|
||||||
* @param info A pointer to the @c ZydisInstructionInfo struct
|
* @param info A pointer to the @c ZydisInstructionInfo struct
|
||||||
*/
|
*/
|
||||||
static void ZydisDecodeSIB(uint8_t sibByte, ZydisInstructionInfo* info)
|
static void ZydisDecodeSIB(uint8_t sibByte, ZydisInstructionInfo* info)
|
||||||
|
@ -373,7 +373,7 @@ static void ZydisDecodeSIB(uint8_t sibByte, ZydisInstructionInfo* info)
|
||||||
* @return A zydis status code.
|
* @return A zydis status code.
|
||||||
*
|
*
|
||||||
* This function sets the corresponding flag for each prefix and automatically decodes the last
|
* This function sets the corresponding flag for each prefix and automatically decodes the last
|
||||||
* rex-prefix (if exists).
|
* REX-prefix (if exists).
|
||||||
*/
|
*/
|
||||||
static ZydisStatus ZydisCollectOptionalPrefixes(ZydisInstructionDecoder* decoder,
|
static ZydisStatus ZydisCollectOptionalPrefixes(ZydisInstructionDecoder* decoder,
|
||||||
ZydisInstructionInfo* info)
|
ZydisInstructionInfo* info)
|
||||||
|
@ -608,7 +608,7 @@ static ZydisStatus ZydisDecodeOperandRegister(ZydisInstructionInfo* info,
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Decodes a memory or register operand encoded in the modrm.rm field.
|
* @brief Decodes a memory or register operand encoded in the ModRM.rm field.
|
||||||
*
|
*
|
||||||
* @param decoder A pointer to the @c ZydisInstructionDecoder decoder instance.
|
* @param decoder A pointer to the @c ZydisInstructionDecoder decoder instance.
|
||||||
* @param info A pointer to the @c ZydisInstructionInfo struct.
|
* @param info A pointer to the @c ZydisInstructionInfo struct.
|
||||||
|
|
|
@ -43,7 +43,7 @@
|
||||||
extern const ZydisInstructionTableNode filterOpcode[][256];
|
extern const ZydisInstructionTableNode filterOpcode[][256];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Contains all vex-map filters.
|
* @brief Contains all VEX-map filters.
|
||||||
*
|
*
|
||||||
* Index values:
|
* Index values:
|
||||||
* 0 = LES, LDS or BOUND instruction (default encoding)
|
* 0 = LES, LDS or BOUND instruction (default encoding)
|
||||||
|
@ -66,7 +66,7 @@ extern const ZydisInstructionTableNode filterOpcode[][256];
|
||||||
extern const ZydisInstructionTableNode filterVEX[][16];
|
extern const ZydisInstructionTableNode filterVEX[][16];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Contains all xop-map filters.
|
* @brief Contains all XOP-map filters.
|
||||||
*
|
*
|
||||||
* Index values:
|
* Index values:
|
||||||
* 0 = POP instruction (default encoding)
|
* 0 = POP instruction (default encoding)
|
||||||
|
@ -97,7 +97,7 @@ extern const ZydisInstructionTableNode filterMode[][2];
|
||||||
extern const ZydisInstructionTableNode filterMandatoryPrefix[][4];
|
extern const ZydisInstructionTableNode filterMandatoryPrefix[][4];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Contains all modrm.mod filters.
|
* @brief Contains all ModRM.mod filters.
|
||||||
*
|
*
|
||||||
* Index values:
|
* Index values:
|
||||||
* 0 = [modrm_mod == !11] = memory
|
* 0 = [modrm_mod == !11] = memory
|
||||||
|
@ -106,14 +106,14 @@ extern const ZydisInstructionTableNode filterMandatoryPrefix[][4];
|
||||||
extern const ZydisInstructionTableNode filterModrmMod[][2];
|
extern const ZydisInstructionTableNode filterModrmMod[][2];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Contains all modrm.reg filters.
|
* @brief Contains all ModRM.reg filters.
|
||||||
*
|
*
|
||||||
* Indexed by the numeric value of the modrm_reg field.
|
* Indexed by the numeric value of the modrm_reg field.
|
||||||
*/
|
*/
|
||||||
extern const ZydisInstructionTableNode filterModrmReg[][8];
|
extern const ZydisInstructionTableNode filterModrmReg[][8];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Contains all modrm.rm filters.
|
* @brief Contains all ModRM.rm filters.
|
||||||
*
|
*
|
||||||
* Indexed by the numeric value of the modrm_rm field.
|
* Indexed by the numeric value of the modrm_rm field.
|
||||||
*/
|
*/
|
||||||
|
@ -139,30 +139,30 @@ extern const ZydisInstructionTableNode filterOperandSize[][2];
|
||||||
extern const ZydisInstructionTableNode filterAddressSize[][3];
|
extern const ZydisInstructionTableNode filterAddressSize[][3];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Contains all rex/vex/evex.w filters.
|
* @brief Contains all REX/VEX/EVEX.w filters.
|
||||||
*
|
*
|
||||||
* Indexed by the numeric value of the rex/vex/evex.w field.
|
* Indexed by the numeric value of the REX/VEX/EVEX.w field.
|
||||||
*/
|
*/
|
||||||
extern const ZydisInstructionTableNode filterREXW[][2];
|
extern const ZydisInstructionTableNode filterREXW[][2];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Contains all vex.l filters.
|
* @brief Contains all VEX.l filters.
|
||||||
*
|
*
|
||||||
* Indexed by the numeric value of the vex/evex.l field.
|
* Indexed by the numeric value of the VEX/EVEX.l field.
|
||||||
*/
|
*/
|
||||||
extern const ZydisInstructionTableNode filterVEXL[][2];
|
extern const ZydisInstructionTableNode filterVEXL[][2];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Contains all evex.l' filters.
|
* @brief Contains all EVEX.l' filters.
|
||||||
*
|
*
|
||||||
* Indexed by the numeric value of the evex.l' field.
|
* Indexed by the numeric value of the EVEX.l' field.
|
||||||
*/
|
*/
|
||||||
extern const ZydisInstructionTableNode filterEVEXL2[][2];
|
extern const ZydisInstructionTableNode filterEVEXL2[][2];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Contains all evex.b filters.
|
* @brief Contains all EVEX.b filters.
|
||||||
*
|
*
|
||||||
* Indexed by the numeric value of the evex.b field.
|
* Indexed by the numeric value of the EVEX.b field.
|
||||||
*/
|
*/
|
||||||
extern const ZydisInstructionTableNode filterEVEXB[][2];
|
extern const ZydisInstructionTableNode filterEVEXB[][2];
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue