Messages in this thread | | | Date | Mon, 7 Jul 2008 15:46:51 -0400 | From | Rik van Riel <> | Subject | Re: Spinlocks: Factor our GENERIC_LOCKBREAK in order to avoid spin with irqs disable |
| |
On Wed, 25 Jun 2008 19:51:12 -0700 Jeremy Fitzhardinge <jeremy@goop.org> wrote:
> Thomas Friebel presented results at the Xen Summit this week showing > that ticket locks are an absolute disaster for scalability in a virtual > environment, for a similar reason. It's a bit irritating if the lock > holder vcpu gets preempted by the hypervisor, but its much worse when > they release the lock: unless the vcpu scheduler gives a cpu to the vcpu > with the next ticket, it can waste up to N timeslices spinning. > > I'm experimenting with adding pvops hook to allow you to put in new > spinlock implementations on the fly.
Alternatively, the guest could tell the host which vcpus are next in line for a ticket spinlock, or a vcpu that gets scheduled but is not supposed to grab the lock yet can give some CPU time to the vcpu that should get the lock next.
I believe the IBM PPC64 people have done some work to implement just that.
-- All Rights Reversed
| |