Zydis
v2.0.3
|
Functions for decoding instructions. More...
#include <Zydis/CommonTypes.h>
#include <Zydis/DecoderTypes.h>
#include <Zydis/Defines.h>
#include <Zydis/Status.h>
Go to the source code of this file.
Data Structures | |
struct | ZydisDecoder_ |
Defines the ZydisDecoder struct. More... | |
Typedefs | |
typedef ZydisU8 | ZydisDecoderMode |
Defines the ZydisDecoderMode datatype. More... | |
typedef struct ZydisDecoder_ | ZydisDecoder |
Defines the ZydisDecoder struct. More... | |
Enumerations | |
enum | ZydisDecoderModes { ZYDIS_DECODER_MODE_MINIMAL , ZYDIS_DECODER_MODE_AMD_BRANCHES , ZYDIS_DECODER_MODE_KNC , ZYDIS_DECODER_MODE_MPX , ZYDIS_DECODER_MODE_CET , ZYDIS_DECODER_MODE_LZCNT , ZYDIS_DECODER_MODE_TZCNT , ZYDIS_DECODER_MODE_WBNOINVD , ZYDIS_DECODER_MODE_MAX_VALUE = ZYDIS_DECODER_MODE_WBNOINVD } |
Values that represent decoder-modes. More... | |
Functions | |
ZYDIS_EXPORT ZydisStatus | ZydisDecoderInit (ZydisDecoder *decoder, ZydisMachineMode machineMode, ZydisAddressWidth addressWidth) |
Initializes the given ZydisDecoder instance. More... | |
ZYDIS_EXPORT ZydisStatus | ZydisDecoderEnableMode (ZydisDecoder *decoder, ZydisDecoderMode mode, ZydisBool enabled) |
Enables or disables the specified decoder-mode. More... | |
ZYDIS_EXPORT ZydisStatus | ZydisDecoderDecodeBuffer (const ZydisDecoder *decoder, const void *buffer, ZydisUSize bufferLen, ZydisU64 instructionPointer, ZydisDecodedInstruction *instruction) |
Decodes the instruction in the given input buffer . More... | |
Functions for decoding instructions.
typedef struct ZydisDecoder_ ZydisDecoder |
Defines the ZydisDecoder
struct.
typedef ZydisU8 ZydisDecoderMode |
Defines the ZydisDecoderMode
datatype.
enum ZydisDecoderModes |
Values that represent decoder-modes.
ZYDIS_EXPORT ZydisStatus ZydisDecoderDecodeBuffer | ( | const ZydisDecoder * | decoder, |
const void * | buffer, | ||
ZydisUSize | bufferLen, | ||
ZydisU64 | instructionPointer, | ||
ZydisDecodedInstruction * | instruction | ||
) |
Decodes the instruction in the given input buffer
.
decoder | A pointer to the ZydisDecoder instance. |
buffer | A pointer to the input buffer. |
bufferLen | The length of the input buffer. |
instructionPointer | The instruction-pointer. |
instruction | A pointer to the ZydisDecodedInstruction struct, that receives the details about the decoded instruction. |
ZYDIS_EXPORT ZydisStatus ZydisDecoderEnableMode | ( | ZydisDecoder * | decoder, |
ZydisDecoderMode | mode, | ||
ZydisBool | enabled | ||
) |
Enables or disables the specified decoder-mode.
decoder | A pointer to the ZydisDecoder instance. |
mode | The decoder mode. |
enabled | ZYDIS_TRUE to enable, or ZYDIS_FALSE to disable the specified decoder-mode. |
ZYDIS_EXPORT ZydisStatus ZydisDecoderInit | ( | ZydisDecoder * | decoder, |
ZydisMachineMode | machineMode, | ||
ZydisAddressWidth | addressWidth | ||
) |
Initializes the given ZydisDecoder
instance.
decoder | A pointer to the ZydisDecoder instance. |
machineMode | The machine mode. |
addressWidth | The address width. |