All of lore.kernel.org
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: Raghavendra KT <raghavendra.kt.linux@gmail.com>,
	Christian Borntraeger <borntraeger@de.ibm.com>
Cc: Gleb Natapov <gleb@kernel.org>, KVM <kvm@vger.kernel.org>,
	linux-s390 <linux-s390@vger.kernel.org>,
	Cornelia Huck <cornelia.huck@de.ibm.com>,
	Michael Mueller <mimu@linux.vnet.ibm.com>
Subject: Re: [PATCH 2/3] KVM: add kvm_arch_vcpu_runnable() test to kvm_vcpu_on_spin() loop
Date: Thu, 27 Feb 2014 19:20:33 +0100	[thread overview]
Message-ID: <530F81F1.5050109@redhat.com> (raw)
In-Reply-To: <CAC4Lta32puDyAYXppVJT-nk2=xL1jZh82sWNnZNTrTfJtf0gMw@mail.gmail.com>

Il 27/02/2014 19:11, Raghavendra KT ha scritto:
> On Wed, Feb 26, 2014 at 8:44 PM, Christian Borntraeger
> <borntraeger@de.ibm.com> wrote:
>> From: Michael Mueller <mimu@linux.vnet.ibm.com>
>>
>> Use the arch specific function kvm_arch_vcpu_runnable() to add a further
>> criterium to identify a suitable vcpu to yield to during undirected yield
>> processing.
>>
>> Signed-off-by: Michael Mueller <mimu@linux.vnet.ibm.com>
>> Reviewed-by: Christian Borntraeger <borntraeger@de.ibm.com>
>> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
>> ---
>>  virt/kvm/kvm_main.c | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c
>> index f5668a4..5fd4cf8 100644
>> --- a/virt/kvm/kvm_main.c
>> +++ b/virt/kvm/kvm_main.c
>> @@ -1801,7 +1801,7 @@ void kvm_vcpu_on_spin(struct kvm_vcpu *me)
>>                                 continue;
>>                         if (vcpu == me)
>>                                 continue;
>> -                       if (waitqueue_active(&vcpu->wq))
>> +                       if (waitqueue_active(&vcpu->wq) && !kvm_arch_vcpu_runnable(vcpu))
>>                                 continue;
>>                         if (!kvm_vcpu_eligible_for_directed_yield(vcpu))
>>                                 continue;
>> --
>> 1.8.4.2
>>
>
> I ran kernbench/sysbench/ebizzy on x86 guest to confirm that this did
> not have any adverse effect in ple handler path.

Thanks!

Paolo

  reply	other threads:[~2014-02-27 18:20 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-02-26 15:14 [PATCH 0/3] Improved yield performance Christian Borntraeger
2014-02-26 15:14 ` [PATCH 1/3] KVM: s390: implementation of kvm_arch_vcpu_runnable() Christian Borntraeger
2014-02-26 15:14 ` [PATCH 2/3] KVM: add kvm_arch_vcpu_runnable() test to kvm_vcpu_on_spin() loop Christian Borntraeger
2014-02-27 18:11   ` Raghavendra KT
2014-02-27 18:20     ` Paolo Bonzini [this message]
2014-02-26 15:14 ` [PATCH 3/3] KVM/s390: Set preempted flag during vcpu wakeup and interrupt delivery Christian Borntraeger
2014-02-26 15:16 ` [PATCH 0/3] Improved yield performance Paolo Bonzini

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=530F81F1.5050109@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=borntraeger@de.ibm.com \
    --cc=cornelia.huck@de.ibm.com \
    --cc=gleb@kernel.org \
    --cc=kvm@vger.kernel.org \
    --cc=linux-s390@vger.kernel.org \
    --cc=mimu@linux.vnet.ibm.com \
    --cc=raghavendra.kt.linux@gmail.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.