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

some question about x86_emulate_instruction in arch/x86/kvm/x86.c #38

Open
wangbaba523 opened this issue Jun 27, 2020 · 2 comments
Open

Comments

@wangbaba523
Copy link

Hello, Is that x86_emulate_instruction can emulate all instructions? I want to emulate some call instruction,but I don't know how to do it,Do you have any information about this problem,Thanks.

@Wenzel
Copy link
Member

Wenzel commented Jun 27, 2020

Hi @wangbaba523,

I'm not knowledgable about the kvm part, but an emulator is complicated piece of software to implement and will always be incomplete.
Althought, the call instruction is very common and should be implemented I believe.

Maybe @mdontu and @adlazar can provide more information ?

@adlazar
Copy link
Collaborator

adlazar commented Jun 29, 2020

@wangbaba523, the KVM emulator cannot emulate any instruction, but those instructions that cannot be emulated can be transparently single-stepped. Just track the execute access and allow the access to happen (when you handle the memory access event). If the instruction cannot be emulated, the vCPU will be single-stepped.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants