RE: [patch 13/31] x86/fpu: Move KVMs FPU swapping to FPU core

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

 



On 10/15/2021 3:14 AM, Thomas Gleixner wrote:
> Paolo,
> 
[...]
> >> vcpu_create()
> >>
> >>    fpu_init_fpstate_user(guest_fpu, supported_xcr0)
> >>
> >> That will (it does not today) do:
> >>
> >>       guest_fpu::__state_perm = supported_xcr0 &
> >> xstate_get_group_perm();
> >>
> >> The you have the information you need right in the guest FPU.
> >
> > Good, I wasn't aware of the APIs that will be there.
> 
> Me neither, but that's a pretty obvious consequence of the work I'm doing
> for AMX. So I made it up for you. :)

Do you mean that fpu_init_fpstate_user() will be updated to add
supported_xcr0 later? :) 

I'm thinking if guest_fpu::xfd is good to directly initialize as user's
init_fpstate.xfd. Because before guest initializes XFD, "hardware"
is reset value. So it would be better to make guest_fpu::xfd the
same so no need to reload zero before vmenter during this time.

Thanks,
Jing




[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux