11 messages in com.xensource.lists.xen-develRe: [Xen-devel] [PATCH] [RFC] More fp...| From | Sent On | Attachments |
|---|---|---|
| Trolle Selander | 29 Feb 2008 14:13 | .patch |
| Keir Fraser | 01 Mar 2008 00:46 | |
| Keir Fraser | 01 Mar 2008 01:17 | |
| Trolle Selander | 03 Mar 2008 04:18 | |
| Keir Fraser | 03 Mar 2008 04:21 | |
| Andi Kleen | 03 Mar 2008 06:52 | |
| Keir Fraser | 03 Mar 2008 07:00 | |
| Andi Kleen | 03 Mar 2008 08:59 | |
| Keir Fraser | 03 Mar 2008 09:29 | |
| Andi Kleen | 03 Mar 2008 10:11 | |
| Keir Fraser | 04 Mar 2008 02:12 |
| Subject: | Re: [Xen-devel] [PATCH] [RFC] More fp instructions for realmode emulation (Enables booting OS/2 as a HVM guest on Intel/VT hardware)![]() |
|---|---|
| From: | Keir Fraser (keir...@eu.citrix.com) |
| Date: | 03/01/2008 12:46:36 AM |
| List: | com.xensource.lists.xen-devel |
This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.
Regarding point 1: Don¹t FPU instructions that raise an exception only log that in the status word, to be picked up by the next FPU instruction which checks for exceptions? It strikes me that we can have previously loaded up a status word that requires an exception to occur on FWAIT, in which case semantics are broken. More worryingly, if any of the instructions you have added can cause an exception, we will crash Xen because you have not added fixup handling. Unfortunately I¹m not really up on exactly how FPU exception handling works: are you?
Regarding point 2: Yes, direct use of the FPU instructions is fine as we already loaded guest FPU context.
-- Keir
On 29/2/08 22:14, "Trolle Selander" <trol...@gmail.com> wrote:
I'm a little concerned about the "correctness" of the FSTSW emulation and the use of inline assembly directly using the corresponding ops for emulation. Wrt FSTSW, it is really two ops FNSTSW immediately preceeded by an FWAIT. I've left FWAIT defined, but a no-op because after looking at realmode.c it seems in the emulation, exceptions are always processed if a call to x86_emulate returns an exception, so there should be no way for there to be "pending" exceptions for FWAIT to wait for. I may have missed something, though, hence the RFC.
Secondly, about the inline assembly - i saw that this was how many of the other FP instructions were done, so I did it that way as well. However, none of the previous instructions done that way referenced the fp registers. Does this make a difference, or is it ok the way i've done it here?





.patch