Home
last modified time | relevance | path

Searched refs:modrm (Results 1 – 17 of 17) sorted by relevance

/external/google-breakpad/src/third_party/libdisasm/
Dia32_modrm.c93 static void byte_decode(unsigned char b, struct modRM_byte *modrm) { in byte_decode() argument
96 modrm->mod = b >> 6; /* top 2 bits */ in byte_decode()
97 modrm->reg = (b & 56) >> 3; /* middle 3 bits */ in byte_decode()
98 modrm->rm = b & 7; /* bottom 3 bits */ in byte_decode()
144 x86_op_t *op, struct modRM_byte *modrm ) { in modrm_decode16() argument
149 switch( modrm->rm ) { in modrm_decode16()
174 if ( modrm->mod != MOD16_MOD_NODISP ) { in modrm_decode16()
189 if ( modrm->mod == MOD16_MOD_DISP8 ) { in modrm_decode16()
194 } else if ( modrm->mod == MOD16_MOD_DISP16 ) { in modrm_decode16()
214 struct modRM_byte modrm; in ia32_modrm_decode() local
[all …]
Dia32_invariant.c64 static void byte_decode(unsigned char b, struct modRM_byte *modrm) { argument
66 static inline void byte_decode(unsigned char b, struct modRM_byte *modrm) {
70 modrm->mod = b >> 6; /* top 2 bits */
71 modrm->reg = (b & 56) >> 3; /* middle 3 bits */
72 modrm->rm = b & 7; /* bottom 3 bits */
76 struct modRM_byte modrm; local
84 byte_decode(*in, &modrm); /* get bitfields */
94 if ( ! mode_16 && modrm.rm == MODRM_RM_SIB &&
95 modrm.mod != MODRM_MOD_NOEA ) {
105 if ( sib.base == SIB_BASE_EBP && ! modrm.mod ) {
[all …]
Dia32_operand.c41 unsigned int op_value, unsigned char modrm, in decode_operand_value() argument
90 ia32_reg_decode( modrm, op, REG_CTRL_OFFSET ); in decode_operand_value()
93 ia32_reg_decode( modrm, op, REG_DEBUG_OFFSET ); in decode_operand_value()
96 ia32_reg_decode( modrm, op, gen_regs ); in decode_operand_value()
99 ia32_reg_decode( modrm, op, REG_MMX_OFFSET ); in decode_operand_value()
102 ia32_reg_decode( modrm, op, REG_SEG_OFFSET ); in decode_operand_value()
105 ia32_reg_decode( modrm, op, REG_TEST_OFFSET ); in decode_operand_value()
108 ia32_reg_decode( modrm, op, REG_SIMD_OFFSET ); in decode_operand_value()
382 unsigned char modrm ) { in ia32_decode_operand() argument
417 op_size, raw_op, modrm, gen_regs ); in ia32_decode_operand()
Dia32_insn.c265 unsigned char modrm; in ia32_decode_insn() local
295 modrm = GET_BYTE( buf, buf_len ); in ia32_decode_insn()
307 raw_insn->dest_flag, prefixes, modrm ); in ia32_decode_insn()
314 raw_insn->src_flag, prefixes, modrm ); in ia32_decode_insn()
320 raw_insn->aux_flag, prefixes, modrm ); in ia32_decode_insn()
Dia32_operand.h10 unsigned char modrm );
/external/valgrind/VEX/priv/
Dguest_x86_toIR.c2283 Int delta, UChar modrm, in dis_Grp1() argument
2296 switch (gregOfRM(modrm)) { in dis_Grp1()
2306 if (epartIsReg(modrm)) { in dis_Grp1()
2309 assign(dst0, getIReg(sz,eregOfRM(modrm))); in dis_Grp1()
2312 if (gregOfRM(modrm) == 2 /* ADC */) { in dis_Grp1()
2316 if (gregOfRM(modrm) == 3 /* SBB */) { in dis_Grp1()
2327 if (gregOfRM(modrm) < 7) in dis_Grp1()
2328 putIReg(sz, eregOfRM(modrm), mkexpr(dst1)); in dis_Grp1()
2331 DIP("%s%c $0x%x, %s\n", nameGrp1(gregOfRM(modrm)), nameISize(sz), d32, in dis_Grp1()
2332 nameIReg(sz,eregOfRM(modrm))); in dis_Grp1()
[all …]
Dguest_amd64_toIR.c3404 Long delta, UChar modrm, in dis_Grp1() argument
3417 switch (gregLO3ofRM(modrm)) { in dis_Grp1()
3427 if (epartIsReg(modrm)) { in dis_Grp1()
3430 assign(dst0, getIRegE(sz,pfx,modrm)); in dis_Grp1()
3433 if (gregLO3ofRM(modrm) == 2 /* ADC */) { in dis_Grp1()
3437 if (gregLO3ofRM(modrm) == 3 /* SBB */) { in dis_Grp1()
3448 if (gregLO3ofRM(modrm) < 7) in dis_Grp1()
3449 putIRegE(sz, pfx, modrm, mkexpr(dst1)); in dis_Grp1()
3453 nameGrp1(gregLO3ofRM(modrm)), nameISize(sz), d64, in dis_Grp1()
3454 nameIRegE(sz,pfx,modrm)); in dis_Grp1()
[all …]
/external/elfutils/libcpu/
Di386_data.h49 unsigned int modrm : 1; member
169 uint_fast8_t modrm = data[0]; in general_mod$r_m() local
176 if ((modrm & 0xc7) == 6 || (modrm & 0xc0) == 0x80) in general_mod$r_m()
179 else if ((modrm & 0xc0) == 0x40) in general_mod$r_m()
182 else if ((modrm & 0xc0) == 0) in general_mod$r_m()
187 if ((modrm & 0xc7) == 6) in general_mod$r_m()
196 if ((modrm & 0x4) == 0) in general_mod$r_m()
198 "xp"[(modrm >> 1) & 1], "sd"[modrm & 1]); in general_mod$r_m()
201 ((const char [4][3]) { "si", "di", "bp", "bx" })[modrm & 3]); in general_mod$r_m()
213 if ((modrm & 7) != 4) in general_mod$r_m()
[all …]
Di386_disasm.c591 if (instrtab[cnt].modrm) in i386_disasm()
593 uint_fast8_t modrm = codep[-1]; in i386_disasm() local
599 if ((modrm & 0xc7) == 6 || (modrm & 0xc0) == 0x80) in i386_disasm()
601 else if ((modrm & 0xc0) == 0x40) in i386_disasm()
608 if ((modrm & 0xc0) != 0xc0 && (modrm & 0x7) == 0x4) in i386_disasm()
612 if ((modrm & 0xc7) == 5 || (modrm & 0xc0) == 0x80 in i386_disasm()
613 || ((modrm & 0xc7) == 0x4 && (codep[0] & 0x7) == 0x5)) in i386_disasm()
615 else if ((modrm & 0xc0) == 0x40) in i386_disasm()
906 ADD_STRING (tttn[codep[-1 - instrtab[cnt].modrm] & 0x0f]); in i386_disasm()
Di386_parse.y118 int modrm; member
852 instr->modrm = 1; in fillin_arg()
1205 fprintf (outfile, " .modrm = %d,", instr->modrm); in instrtable_out()
/external/valgrind/VEX/useful/
Dhd_fpu.c691 UChar modrm; in do_one_insn_fp() local
717 modrm = *r_eip; in do_one_insn_fp()
722 if (modrm < 0xC0) { in do_one_insn_fp()
779 switch (modrm) { in do_one_insn_fp()
782 fp_do_op_ST_ST ( modrm - 0xC0, 0, Fp_Add, False ); in do_one_insn_fp()
786 fp_do_op_ST_ST ( modrm - 0xC8, 0, Fp_Mul, False ); in do_one_insn_fp()
790 fp_do_COM_ST_ST ( modrm - 0xD0, 0, 0 ); in do_one_insn_fp()
794 fp_do_COM_ST_ST ( modrm - 0xD8, 0, 1 ); in do_one_insn_fp()
798 fp_do_op_ST_ST ( modrm - 0xE0, 0, Fp_Sub, False ); in do_one_insn_fp()
802 fp_do_op_ST_ST ( modrm - 0xE8, 0, Fp_SubR, False ); in do_one_insn_fp()
[all …]
/external/libchrome/sandbox/win/src/sidestep/
Dmini_disassembler.cpp334 unsigned char modrm = (*start_byte); in ProcessModrm() local
335 unsigned char mod = modrm & 0xC0; // mask out top two bits to get mod field in ProcessModrm()
336 modrm = modrm & 0x07; // mask out bottom 3 bits to get r/m field in ProcessModrm()
338 modrm = mod | modrm; // combine the r/m and mod fields as discussed in ProcessModrm()
346 modrm_entry = &s_ia32_modrm_map_[modrm]; in ProcessModrm()
348 modrm_entry = &s_ia16_modrm_map_[modrm]; in ProcessModrm()
/external/v8/src/x87/
Ddisasm-x87.cc461 byte modrm = *data; in PrintOperands() local
463 get_modrm(modrm, &mod, &regop, &rm); in PrintOperands()
489 byte modrm = *(data+1); in PrintImmediateOp() local
491 get_modrm(modrm, &mod, &regop, &rm); in PrintImmediateOp()
518 byte modrm = *++data; in F7Instruction() local
520 get_modrm(modrm, &mod, &regop, &rm); in F7Instruction()
560 byte modrm = *++data; in D1D3C1Instruction() local
562 get_modrm(modrm, &mod, &regop, &rm); in D1D3C1Instruction()
/external/v8/src/ia32/
Ddisasm-ia32.cc525 byte modrm = *data; in PrintOperands() local
527 get_modrm(modrm, &mod, &regop, &rm); in PrintOperands()
553 byte modrm = *(data+1); in PrintImmediateOp() local
555 get_modrm(modrm, &mod, &regop, &rm); in PrintImmediateOp()
582 byte modrm = *++data; in F7Instruction() local
584 get_modrm(modrm, &mod, &regop, &rm); in F7Instruction()
624 byte modrm = *++data; in D1D3C1Instruction() local
626 get_modrm(modrm, &mod, &regop, &rm); in D1D3C1Instruction()
/external/v8/src/x64/
Ddisasm-x64.cc649 byte modrm = *data; in PrintOperands() local
651 get_modrm(modrm, &mod, &regop, &rm); in PrintOperands()
685 byte modrm = *(data + 1); in PrintImmediateOp() local
687 get_modrm(modrm, &mod, &regop, &rm); in PrintImmediateOp()
730 byte modrm = *(data + 1); in F6F7Instruction() local
732 get_modrm(modrm, &mod, &regop, &rm); in F6F7Instruction()
784 byte modrm = *(data + count); in ShiftInstruction() local
786 get_modrm(modrm, &mod, &regop, &rm); in ShiftInstruction()
Dassembler-x64.cc209 byte modrm = operand.buf_[0]; in Operand() local
210 DCHECK(modrm < 0xC0); // Disallow mode 3 (register target). in Operand()
211 bool has_sib = ((modrm & 0x07) == 0x04); in Operand()
212 byte mode = modrm & 0xC0; in Operand()
214 int base_reg = (has_sib ? operand.buf_[1] : modrm) & 0x07; in Operand()
234 buf_[0] = (modrm & 0x3f) | (is_baseless ? 0x00 : 0x80); in Operand()
239 buf_[0] = (modrm & 0x3f) | 0x40; // Mode 1. in Operand()
244 buf_[0] = (modrm & 0x3f); // Mode 0. in Operand()
/external/valgrind/perf/
Dtinycc.c18835 int modrm; in put_got_entry() local
18839 modrm = 0xa3; in put_got_entry()
18841 modrm = 0x25; in put_got_entry()
18849 p[1] = modrm + 0x10; in put_got_entry()
18852 p[7] = modrm; in put_got_entry()
18858 p[1] = modrm; in put_got_entry()