qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] kvm_arch_put_registers and xsave


From: Alex Bligh
Subject: Re: [Qemu-devel] kvm_arch_put_registers and xsave
Date: Sun, 19 Jun 2016 23:00:42 +0100

On 19 Jun 2016, at 21:54, Peter Maydell <address@hidden> wrote:

> The purpose of the get/put functions, broadly, is "copy
> state from the hypervisor into QEMU's cpu state struct
> and vice-versa". The specific details are down to KVM's ABI
> (and to historical details like some KVM ioctls being newer
> or optional). For a from-scratch hypervisor I think all
> you need to do is copy the state from env->regs,
> env->xmm_regs, etc etc into the hypervisor and back,
> however is best suited to the hypervisor's APIs.

Thanks.

Hypervisor.framework provides register by register access:

https://developer.apple.com/library/mac/documentation/Hypervisor/Reference/Hypervisor_Reference/index.html#//apple_ref/doc/uid/TP40016756-CH2-DontLinkElementID_22

so I guess I should do that with every register, and ignore the explicit xsave 
support.

XMM registers and FPState (for instance) appear to be in an opaque format:

https://developer.apple.com/library/mac/documentation/Hypervisor/Reference/Hypervisor_Reference/index.html#//apple_ref/c/func/hv_vcpu_read_fpstate

-- 
Alex Bligh







reply via email to

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