Re: [PATCH] KVM: x86: emulate SAHF instruction

2013-10-31 Thread Gleb Natapov
On Thu, Oct 31, 2013 at 03:49:04PM +0100, Paolo Bonzini wrote: > Il 31/10/2013 15:34, Gleb Natapov ha scritto: > > I haven't checked AMD doc, but if it is documented that lahf/sahf #UDs at 64 > > bit we should emulate it correctly. > > It says "The LAHF instruction can only be executed in 64-bit m

Re: [PATCH] KVM: x86: emulate SAHF instruction

2013-10-31 Thread Borislav Petkov
On Thu, Oct 31, 2013 at 03:49:04PM +0100, Paolo Bonzini wrote: > Il 31/10/2013 15:34, Gleb Natapov ha scritto: > > I haven't checked AMD doc, but if it is documented that lahf/sahf #UDs at 64 > > bit we should emulate it correctly. > > It says "The LAHF instruction can only be executed in 64-bit m

Re: [PATCH] KVM: x86: emulate SAHF instruction

2013-10-31 Thread Paolo Bonzini
Il 31/10/2013 15:34, Gleb Natapov ha scritto: > I haven't checked AMD doc, but if it is documented that lahf/sahf #UDs at 64 > bit we should emulate it correctly. It says "The LAHF instruction can only be executed in 64-bit mode if supported by the processor implementation. Check the status of ECX

Re: [PATCH] KVM: x86: emulate SAHF instruction

2013-10-31 Thread Gleb Natapov
On Thu, Oct 31, 2013 at 03:27:48PM +0100, Paolo Bonzini wrote: > Il 31/10/2013 15:21, Gleb Natapov ha scritto: > > On Thu, Oct 31, 2013 at 11:29:42AM +0100, Paolo Bonzini wrote: > >> Yet another instruction that we fail to emulate, this time found > >> in Windows 2008R2 32-bit. > >> > >> Cc: sta...

Re: [PATCH] KVM: x86: emulate SAHF instruction

2013-10-31 Thread Paolo Bonzini
Il 31/10/2013 15:21, Gleb Natapov ha scritto: > On Thu, Oct 31, 2013 at 11:29:42AM +0100, Paolo Bonzini wrote: >> Yet another instruction that we fail to emulate, this time found >> in Windows 2008R2 32-bit. >> >> Cc: sta...@vger.kernel.org >> Signed-off-by: Paolo Bonzini >> --- >> Testcase o

Re: [PATCH] KVM: x86: emulate SAHF instruction

2013-10-31 Thread Gleb Natapov
On Thu, Oct 31, 2013 at 11:29:42AM +0100, Paolo Bonzini wrote: > Yet another instruction that we fail to emulate, this time found > in Windows 2008R2 32-bit. > > Cc: sta...@vger.kernel.org > Signed-off-by: Paolo Bonzini > --- > Testcase on its way. BTW, lahf/sahf is another candidate for >