Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

x86: update read/write registers for transfer instructions #2578

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 0 additions & 19 deletions arch/X86/X86Mapping.c
Original file line number Diff line number Diff line change
Expand Up @@ -1153,25 +1153,6 @@ void X86_get_insn_id(cs_struct *h, cs_insn *insn, unsigned int id)
break;
}
break;

case X86_INS_RET:
switch(h->mode) {
case CS_MODE_16:
insn->detail->regs_write[0] = X86_REG_SP;
insn->detail->regs_read[0] = X86_REG_SP;
break;
case CS_MODE_32:
insn->detail->regs_write[0] = X86_REG_ESP;
insn->detail->regs_read[0] = X86_REG_ESP;
break;
default: // 64-bit
insn->detail->regs_write[0] = X86_REG_RSP;
insn->detail->regs_read[0] = X86_REG_RSP;
break;
}
insn->detail->regs_write_count = 1;
insn->detail->regs_read_count = 1;
break;
}

memcpy(insn->detail->groups, insns[i].groups, sizeof(insns[i].groups));
Expand Down
Loading
Loading