Re: [Xen-devel] [PATCH RFC v5 7/8] pvqspinlock, x86: Add qspinlock para-virtualization support

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

 



On 27/02/14 15:50, Paolo Bonzini wrote:
> Il 27/02/2014 16:22, Raghavendra K T ha scritto:
>> On 02/27/2014 08:15 PM, Paolo Bonzini wrote:
>> [...]
>>>> But neither of the VCPUs being kicked here are halted -- they're either
>>>> running or runnable (descheduled by the hypervisor).
>>>
>>> /me actually looks at Waiman's code...
>>>
>>> Right, this is really different from pvticketlocks, where the *unlock*
>>> primitive wakes up a sleeping VCPU.  It is more similar to PLE
>>> (pause-loop exiting).
>>
>> Adding to the discussion, I see there are two possibilities here,
>> considering that in undercommit cases we should not exceed
>> HEAD_SPIN_THRESHOLD,
>>
>> 1. the looping vcpu in pv_head_spin_check() should do halt()
>> considering that we have done enough spinning (more than typical
>> lock-hold time), and hence we are in potential overcommit.
>>
>> 2. multiplex kick_cpu to do directed yield in qspinlock case.
>> But this may result in some ping ponging?
> 
> Actually, I think the qspinlock can work roughly the same as the
> pvticketlock, using the same lock_spinning and unlock_lock hooks.

This is is approach I would like to see.  This would also work for Xen
PV guests.

The current implementation depends on hardware PLE which Xen PV guests
do not support and I'm not sure if other architectures have something
similar (e.g., does ARM's virtualization extensions have PLE?).

David
_______________________________________________
Virtualization mailing list
Virtualization@xxxxxxxxxxxxxxxxxxxxxxxxxx
https://lists.linuxfoundation.org/mailman/listinfo/virtualization




[Index of Archives]     [KVM Development]     [Libvirt Development]     [Libvirt Users]     [CentOS Virtualization]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux