FD.io VPP  v20.01-48-g3e0dafb74
Vector Packet Processing
asm_x86.c File Reference
+ Include dependency graph for asm_x86.c:

Go to the source code of this file.

Data Structures

union  x86_insn_modrm_byte_t
 
union  x86_insn_sib_byte_t
 
struct  x86_insn_group8_t
 

Macros

#define foreach_x86_gp_register
 
#define foreach_x86_insn_modrm_reg_group
 
#define foreach_x86_insn_sse_group
 
#define foreach_x86_gp_reg
 
#define foreach_x86_condition
 

Enumerations

enum  x86_insn_gp_register_t { foreach_x86_gp_register }
 
enum  { foreach_x86_insn_sse_group }
 
enum  { foreach_x86_insn_sse_group }
 

Functions

static uword x86_insn_has_modrm_byte (x86_insn_t *insn)
 
static uword x86_insn_immediate_type (x86_insn_t *insn)
 
static u8x86_insn_parse_number (u32 log2_n_bytes, u8 *code, u8 *code_end, i64 *result)
 
static u32 x86_insn_log2_immediate_bytes (x86_insn_parse_t *p, x86_insn_t *insn)
 
static u8x86_insn_parse_modrm_byte (x86_insn_parse_t *x, x86_insn_modrm_byte_t modrm, u32 parse_flags, u8 *code, u8 *code_end)
 
u8x86_insn_parse (x86_insn_parse_t *p, u8 *code_start)
 
static u8format_x86_gp_reg_operand (u8 *s, va_list *va)
 
static u8format_x86_reg_operand (u8 *s, va_list *va)
 
static u8format_x86_mem_operand (u8 *s, va_list *va)
 
static u8format_x86_insn_operand (u8 *s, va_list *va)
 
u8format_x86_insn_parse (u8 *s, va_list *va)
 

Variables

static x86_insn_t x86_insns_one_byte [256]
 
static x86_insn_t x86_insns_two_byte [256]
 
static x86_insn_group8_t x86_insn_modrm_reg_groups []
 
static x86_insn_group8_t x86_insn_sse_groups_repz []
 
static x86_insn_group8_t x86_insn_sse_groups_operand_size []
 
static x86_insn_group8_t x86_insn_sse_groups_repnz []
 

Macro Definition Documentation

◆ foreach_x86_condition

#define foreach_x86_condition
Value:
_ (o) _ (no) _ (b) _ (nb) \
_ (z) _ (nz) _ (be) _ (nbe) \
_ (s) _ (ns) _ (p) _ (np) \
_ (l) _ (nl) _ (le) _ (nle)

Definition at line 119 of file asm_x86.c.

◆ foreach_x86_gp_reg

#define foreach_x86_gp_reg
Value:
_ (AX) _ (CX) _ (DX) _ (BX) \
_ (SP) _ (BP) _ (SI) _ (DI)

Definition at line 115 of file asm_x86.c.

◆ foreach_x86_gp_register

#define foreach_x86_gp_register
Value:
_ (AX) _ (CX) _ (DX) _ (BX) \
_ (SP) _ (BP) _ (SI) _ (DI)

Definition at line 26 of file asm_x86.c.

◆ foreach_x86_insn_modrm_reg_group

#define foreach_x86_insn_modrm_reg_group
Value:
_ (1) _ (1a) _ (2) _ (3) _ (4) _ (5) _ (6) _ (7) \
_ (8) _ (9) _ (10) _ (11) _ (12) _ (13) _ (14) \
_ (15) _ (16) _ (p)
a
Definition: bitmap.h:538

Definition at line 83 of file asm_x86.c.

◆ foreach_x86_insn_sse_group

foreach_x86_insn_sse_group
Value:
_ (10) _ (28) _ (50) _ (58) _ (60) _ (68) _ (70) _ (78) \
_ (c0) _ (d0) _ (d8) _ (e0) _ (e8) _ (f0) _ (f8)

Definition at line 88 of file asm_x86.c.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
foreach_x86_insn_sse_group 

Definition at line 92 of file asm_x86.c.

◆ anonymous enum

anonymous enum
Enumerator
foreach_x86_insn_sse_group 

Definition at line 101 of file asm_x86.c.

◆ x86_insn_gp_register_t

Enumerator
foreach_x86_gp_register 

Definition at line 30 of file asm_x86.c.

Function Documentation

◆ format_x86_gp_reg_operand()

static u8* format_x86_gp_reg_operand ( u8 s,
va_list *  va 
)
static

Definition at line 1682 of file asm_x86.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ format_x86_insn_operand()

static u8* format_x86_insn_operand ( u8 s,
va_list *  va 
)
static

Definition at line 1798 of file asm_x86.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ format_x86_insn_parse()

u8* format_x86_insn_parse ( u8 s,
va_list *  va 
)

Definition at line 1906 of file asm_x86.c.

+ Here is the call graph for this function:

◆ format_x86_mem_operand()

static u8* format_x86_mem_operand ( u8 s,
va_list *  va 
)
static

Definition at line 1768 of file asm_x86.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ format_x86_reg_operand()

static u8* format_x86_reg_operand ( u8 s,
va_list *  va 
)
static

Definition at line 1729 of file asm_x86.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ x86_insn_has_modrm_byte()

static uword x86_insn_has_modrm_byte ( x86_insn_t insn)
inlinestatic

Definition at line 55 of file asm_x86.c.

+ Here is the caller graph for this function:

◆ x86_insn_immediate_type()

static uword x86_insn_immediate_type ( x86_insn_t insn)
inlinestatic

Definition at line 68 of file asm_x86.c.

+ Here is the caller graph for this function:

◆ x86_insn_log2_immediate_bytes()

static u32 x86_insn_log2_immediate_bytes ( x86_insn_parse_t p,
x86_insn_t insn 
)
static

Definition at line 1317 of file asm_x86.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ x86_insn_parse()

u8* x86_insn_parse ( x86_insn_parse_t p,
u8 code_start 
)

Definition at line 1494 of file asm_x86.c.

+ Here is the call graph for this function:

◆ x86_insn_parse_modrm_byte()

static u8* x86_insn_parse_modrm_byte ( x86_insn_parse_t x,
x86_insn_modrm_byte_t  modrm,
u32  parse_flags,
u8 code,
u8 code_end 
)
static

Definition at line 1345 of file asm_x86.c.

+ Here is the call graph for this function:

◆ x86_insn_parse_number()

static u8* x86_insn_parse_number ( u32  log2_n_bytes,
u8 code,
u8 code_end,
i64 result 
)
static

Definition at line 1281 of file asm_x86.c.

+ Here is the caller graph for this function:

Variable Documentation

◆ x86_insn_modrm_reg_groups

x86_insn_group8_t x86_insn_modrm_reg_groups[]
static

Definition at line 618 of file asm_x86.c.

◆ x86_insn_sse_groups_operand_size

x86_insn_group8_t x86_insn_sse_groups_operand_size[]
static

Definition at line 944 of file asm_x86.c.

◆ x86_insn_sse_groups_repnz

x86_insn_group8_t x86_insn_sse_groups_repnz[]
static

Definition at line 1111 of file asm_x86.c.

◆ x86_insn_sse_groups_repz

x86_insn_group8_t x86_insn_sse_groups_repz[]
static

Definition at line 777 of file asm_x86.c.

◆ x86_insns_one_byte

x86_insn_t x86_insns_one_byte[256]
static

Definition at line 143 of file asm_x86.c.

◆ x86_insns_two_byte

x86_insn_t x86_insns_two_byte[256]
static

Definition at line 367 of file asm_x86.c.