Data Structures | |
struct | xed_state_s |
Encapsulates machine modes for decoder/encoder requests. More... | |
Address width | |
static XED_INLINE xed_address_width_enum_t | xed_state_get_address_width (const xed_state_t *p) |
return the address width | |
Machine mode | |
static XED_INLINE xed_machine_mode_enum_t | xed_state_get_machine_mode (const xed_state_t *p) |
return the machine mode | |
static XED_INLINE xed_bool_t | xed_state_long64_mode (const xed_state_t *p) |
true iff the machine is in LONG_64 mode | |
static XED_INLINE xed_bool_t | xed_state_mode_width_16 (const xed_state_t *p) |
static XED_INLINE xed_bool_t | xed_state_mode_width_32 (const xed_state_t *p) |
static XED_INLINE xed_bool_t | xed_state_real_mode (const xed_state_t *p) |
static XED_INLINE void | xed_state_set_machine_mode (xed_state_t *p, xed_machine_mode_enum_t arg_mode) |
Set the machine mode which corresponds to the default data operand size. | |
Stack address width | |
static XED_INLINE xed_address_width_enum_t | xed_state_get_stack_address_width (const xed_state_t *p) |
Return the STACK address width. | |
static XED_INLINE void | xed_state_set_stack_address_width (xed_state_t *p, xed_address_width_enum_t arg_addr_width) |
set the STACK address width | |
Initialization | |
static XED_INLINE void | xed_state_init (xed_state_t *p, xed_machine_mode_enum_t arg_mmode, xed_address_width_enum_t arg_ignored, xed_address_width_enum_t arg_stack_addr_width) |
Constructor. | |
static XED_INLINE void | xed_state_init2 (xed_state_t *p, xed_machine_mode_enum_t arg_mmode, xed_address_width_enum_t arg_stack_addr_width) |
Constructor. | |
static XED_INLINE void | xed_state_zero (xed_state_t *p) |
clear the xed_state_t | |
Typedefs | |
typedef xed_state_s | xed_state_t |
Encapsulates machine modes for decoder/encoder requests. | |
Functions | |
XED_DLL_EXPORT char const * | xed_get_copyright (void) |
Returns a copyright string. | |
XED_DLL_EXPORT char const * | xed_get_version (void) |
Returns a string representing XED svn commit revision and time stamp. | |
XED_DLL_EXPORT void | xed_register_abort_function (xed_user_abort_function_t fn, void *other) |
This is for registering a function to be called during XED's assert processing. | |
XED_DLL_EXPORT int | xed_state_print (const xed_state_t *p, char *buf, int buflen) |
void XED_DLL_EXPORT | xed_tables_init (void) |
This is the call to initialize the XED encode and decode tables. |
All XED functions reside in the XED namespace. To use XED, you must include "xed-interface.h" and then use the name space:
#include "xed-interface.h"
If you are calling XED2 from C++, you must wrap this include:
extern "C" { #include "xed-interface.h" }
Once, before using XED, you must call xed_tables_init() to initialize the tables XED uses for encoding and decoding:
Once initialized, XED is reentrant (multithread safe). All values used for encoding and decoding live on the caller's stack or in the passed-in parameters.
If your program is multithreaded, initialize XED once (and only once) using the above call before you attempt to decode or encode from any thread. Each thread does NOT need to initialize XED. The idea is to initialize XED before creating your threads.
|
Encapsulates machine modes for decoder/encoder requests. It specifies the machine operating mode as a xed_machine_mode_enum_t for decoding and encoding. The machine mode corresponds to the default data operand width for that mode. For all modes other than the 64b long mode (XED_MACHINE_MODE_LONG_64), a default addressing width, and a stack addressing width must be supplied of type xed_address_width_enum_t . |
|
Returns a copyright string.
|
|
Returns a string representing XED svn commit revision and time stamp.
|
|
This is for registering a function to be called during XED's assert processing. If you do not register an abort function, then the system's abort function will be called. If your supplied function returns, then abort() will still be called.
|
|
return the address width
Definition at line 155 of file xed-state.h. |
|
return the machine mode
Definition at line 112 of file xed-state.h. |
|
Return the STACK address width.
Definition at line 194 of file xed-state.h. |
|
Constructor. DEPRECATED: use xed_state_init2(). The mode, and addresses widths are enumerations that specify the number of bits. In 64b mode (XED_MACHINE_MODE_LONG_64) the address width and stack address widths are 64b (XED_ADDRESS_WIDTH_64b). In other machine modes, you must specify valid addressing widths.
Definition at line 73 of file xed-state.h. |
|
Constructor. The mode, and addresses widths are enumerations that specify the number of bits. In 64b mode (XED_MACHINE_MODE_LONG_64) the address width and stack address widths are 64b (XED_ADDRESS_WIDTH_64b). In other machine modes, you must specify valid addressing widths.
Definition at line 92 of file xed-state.h. |
|
true iff the machine is in LONG_64 mode
Definition at line 119 of file xed-state.h. |
|
Definition at line 129 of file xed-state.h. |
|
Definition at line 135 of file xed-state.h. |
|
|
|
Definition at line 124 of file xed-state.h. |
|
Set the machine mode which corresponds to the default data operand size.
Definition at line 143 of file xed-state.h. |
|
set the STACK address width
Definition at line 185 of file xed-state.h. |
|
clear the xed_state_t
Definition at line 101 of file xed-state.h. |
|
This is the call to initialize the XED encode and decode tables. It must be called once before using XED. |