Re: [PATCH 6/6] KVM: x86: Emulator support for TF

Gleb Natapov
2010-02-23T10:32:57Z

On Tue, Feb 23, 2010 at 12:29:25PM +0200, Avi Kivity wrote:
> On 02/23/2010 12:26 PM, Gleb Natapov wrote:
> >On Tue, Feb 23, 2010 at 11:10:57AM +0100, Jan Kiszka wrote:
> >>Gleb Natapov wrote:
> >>>On Mon, Feb 22, 2010 at 06:51:23PM +0100, Jan Kiszka wrote:
> >>>>Support both guest- as well as host-owned EFLAGS.TF while emulating
> >>>>instructions. For guest-owned TF, we simply inject DB and update DR6.BS
> >>>>after completing an instruction that has TF set on entry. To support
> >>>>guest single-stepping under host control, we store the pending step
> >>>>along with its CS and RIP and trigger a corresponding user space exit
> >>>>once guest execution is about to resume. This check is is also required
> >>>>in the VMX emulation loop during invalid guest states.
> >>>>
> >>>Emulator currently is a total mess. It is not a good time to add more mess
> >>>there right now IMO.
> >>Then let's clean up what you consider "mess" in this feature. Unless
> >>there are plans to clean up the emulator for the next or next-but-one
> >>kernel release, I do not want to wait for this.
> >>
> >There are plans to cleanup the emulator.
>
> That shouldn't stop the code.
>
If the code is correct and doesn't make emulator code even messier.

--
Gleb.