qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] Re: Suggestion - trap window-close of VM


From: Lennert Buytenhek
Subject: Re: [Qemu-devel] Re: Suggestion - trap window-close of VM
Date: Wed, 30 Mar 2005 20:22:55 +0200
User-agent: Mutt/1.4.1i

On Wed, Mar 30, 2005 at 03:26:34PM +0200, Struan Bartlett wrote:

> >>It subtracts one from the EIP (to find the address of 
> >>the previously-executed instruction) and examines the virtual memory 
> >>location pointed to. If the memory location contains 0xF4 (HLT) then it 
> >>examines the EFLAGS register. If the IF (Interrupt-enable) flag is 
> >>cleared, then one might in fact assume that Windows 2000 is sitting 
> >>there just waiting for you to turn it off. The assumption here is that 
> >>if interrupts are disabled then there is no way the processor's halt 
> >>state can be interrupted.
> >
> >What happens if the previous instruction is a multi-byte instruction
> >that happens to have 0xf4 as its last byte?
> 
> Before I did the IF check, that was a problem but now it should be ok. 
> In your scenario, the IF flag would probably be found still to be set so 
> it would be (correctly) assumed that Windows 2000 was not waiting to be 
> turned off and qemu would continue normally.

So now you're implying that disabling interrupts is something that
only very rarely happens, for example when shutting down the machine?
I don't think that is a very realistic assumption.


--L




reply via email to

[Prev in Thread] Current Thread [Next in Thread]