From: Raghavendra K T <raghavendra.kt@linux.vnet.ibm.com>
To: Peter Zijlstra <peterz@infradead.org>
Cc: jeremy@goop.org, kvm@vger.kernel.org,
virtualization@lists.linux-foundation.org,
paul.gortmaker@windriver.com, hpa@zytor.com, ak@linux.intel.com,
gleb@redhat.com, x86@kernel.org, mingo@redhat.com,
xen-devel@lists.xenproject.org, paulmck@linux.vnet.ibm.com,
riel@redhat.com, konrad.wilk@oracle.com, oleg@redhat.com,
davej@redhat.com, tglx@linutronix.de, fernando_b1@lab.ntt.co.jp,
chegu_vinod@hp.com, waiman.long@hp.com,
linux-kernel@vger.kernel.org, pbonzini@redhat.com,
torvalds@linux-foundation.org
Subject: Re: [RFC] Implement Batched (group) ticket lock
Date: Thu, 29 May 2014 15:21:26 +0530 [thread overview]
Message-ID: <5387031E.702@linux.vnet.ibm.com> (raw)
In-Reply-To: <20140529064606.GH19143@laptop.programming.kicks-ass.net>
On 05/29/2014 12:16 PM, Peter Zijlstra wrote:
> On Wed, May 28, 2014 at 05:46:39PM +0530, Raghavendra K T wrote:
>> In virtualized environment there are mainly three problems
>> related to spinlocks that affect performance.
>> 1. LHP (lock holder preemption)
>> 2. Lock Waiter Preemption (LWP)
>> 3. Starvation/fairness
>>
>> Though ticketlocks solve the fairness problem, it worsens LWP, LHP problems.
>> pv-ticketlocks tried to address this. But we can further improve at the
>> cost of relaxed fairness.
>
> So I really hate the idea of having different locks for paravirt and
> normal kernels.
Yes. I understand that queued lock for normal kernel and unfair version
of queued spinlock for virtual guest would do better.
Since strict serialization of lockwaiters (in both ticketlock/queued
spinlock) does not work well for virtualized guest, my idea was to
give an alternate idea which has bounded starvation and performs as good
as unfair version to virtualized guest.
>
> And we're looking to move to that queued lock for normal kernels.
Agree. and I have tested that too.
next prev parent reply other threads:[~2014-05-29 9:51 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-05-28 12:16 [RFC] Implement Batched (group) ticket lock Raghavendra K T
2014-05-28 21:55 ` Rik van Riel
2014-05-28 22:19 ` Linus Torvalds
2014-05-28 22:29 ` Thomas Gleixner
2014-05-29 1:18 ` Rik van Riel
2014-05-29 9:44 ` Raghavendra K T
2014-05-29 6:46 ` Peter Zijlstra
2014-05-29 9:51 ` Raghavendra K T [this message]
2014-05-29 22:45 ` Waiman Long
2014-05-30 8:53 ` Raghavendra K T
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5387031E.702@linux.vnet.ibm.com \
--to=raghavendra.kt@linux.vnet.ibm.com \
--cc=ak@linux.intel.com \
--cc=chegu_vinod@hp.com \
--cc=davej@redhat.com \
--cc=fernando_b1@lab.ntt.co.jp \
--cc=gleb@redhat.com \
--cc=hpa@zytor.com \
--cc=jeremy@goop.org \
--cc=konrad.wilk@oracle.com \
--cc=kvm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=oleg@redhat.com \
--cc=paul.gortmaker@windriver.com \
--cc=paulmck@linux.vnet.ibm.com \
--cc=pbonzini@redhat.com \
--cc=peterz@infradead.org \
--cc=riel@redhat.com \
--cc=tglx@linutronix.de \
--cc=torvalds@linux-foundation.org \
--cc=virtualization@lists.linux-foundation.org \
--cc=waiman.long@hp.com \
--cc=x86@kernel.org \
--cc=xen-devel@lists.xenproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).