tech-kern archive

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

Re: NVMM missing opcode REPE CMPS implementation



On Sat, Oct 31, 2020 at 11:16:52AM -0500, Robert Nestor wrote:
> Apologies if this isn’t the proper place to bring this up, but the
> discussion on this brings two questions to mind:
> 
> 1) Since the proposed patch isn’t correct and was reverted, and assuming
> there is a problem with this opcode, is there another correct fix coming?

Working on a patch in libnvmm for it and it ought to work fine now, but i'm
stuggling with writing ATF case codes; they are needed to validate the
emulation before committing it.

> 2) Is there some code that one can insert locally into NVMM and/or LIBNVMM
> to help catch other possible problems similar to this?

There are some unhandled cases on Intel support code that can bomb out libnvmm
and thus qemu. They hardly ever come by though and I only see them on one OS
image (OpenServer v5 IIRC) and then consistently at the same place but I have
no idea as to what triggers it there. The VM exit code is
VMCS_EXITCODE_TASK_SWITCH (9) and not handled in nvmm_x86_vmx.c. See section
27.2.4 of
https://www.intel.com/content/dam/www/public/us/en/documents/manuals/64-ia-32-architectures-software-developer-vol-3c-part-3-manual.pdf

> While NVMM is very robust and runs a lot of other systems, there are some
> that it still stumbles over.  I’m sure the vast majority of users don’t care
> about running something like OS X under NVMM for various reasons, it does
> seem to be a real good test of emulation capabilities.  Various versions can
> be installed from standard, non-hacked distributions and run successfully
> without hacks or modifications under KVM on Linux (macOS-Simple-KVM comes to
> mind), but not under NVMM.  Maybe the reason is that there are similar
> missing opcodes being used that aren’t currently handled by NVMM?

I have never tried to boot MacOS-X with qemu+nvmm. I think lots of other
things will need to be prepared for qemu to even start.

Do you know of other possible (more recent) OSs I could try to boot?

With regards,
Reinoud



Home | Main Index | Thread Index | Old Index