Lines Matching defs:pc
93 static uint32_t GetInstructionSize(const uint8_t* pc) {
100 const uint8_t* startpc = pc;
102 uint8_t opcode = *pc++;
134 opcode = *pc++;
144 opcode = *pc++;
150 opcode = *pc++;
163 modrm = *pc++;
182 modrm = *pc++;
189 modrm = *pc++;
196 modrm = *pc++;
217 ++pc; // SIB
230 pc += displacement_size + immediate_size;
232 VLOG(signals) << "x86 instruction length calculated as " << (pc - startpc);
233 return pc - startpc;
277 uint8_t* pc = reinterpret_cast<uint8_t*>(uc->CTX_EIP);
278 VLOG(signals) << HexDump(pc, 32, true, "PC ");
280 if (pc == nullptr) {
286 uint32_t instr_size = GetInstructionSize(pc);
292 *out_return_pc = reinterpret_cast<uintptr_t>(pc + instr_size);
297 uint8_t* pc = reinterpret_cast<uint8_t*>(uc->CTX_EIP);
300 uint32_t instr_size = GetInstructionSize(pc);
312 uintptr_t retaddr = reinterpret_cast<uintptr_t>(pc + instr_size);
355 uint8_t* pc = reinterpret_cast<uint8_t*>(uc->CTX_EIP);
358 if (pc[0] != checkinst2[0] || pc[1] != checkinst2[1]) {
366 uint8_t* limit = pc - 100; // Compiler will hoist to a max of 20 instructions.
367 uint8_t* ptr = pc - sizeof(checkinst1);
386 uintptr_t retaddr = reinterpret_cast<uintptr_t>(pc + 2);