All of lore.kernel.org
 help / color / mirror / Atom feed
From: Avi Kivity <avi@redhat.com>
To: Xiao Guangrong <xiaoguangrong@linux.vnet.ibm.com>
Cc: Takuya Yoshikawa <yoshikawa_takuya_b1@lab.ntt.co.jp>,
	mtosatti@redhat.com, kvm@vger.kernel.org
Subject: Re: [RFC PATCH] KVM: x86: Skip request checking branches in vcpu_enter_guest() more effectively
Date: Mon, 24 Sep 2012 12:09:00 +0200	[thread overview]
Message-ID: <5060313C.1060506@redhat.com> (raw)
In-Reply-To: <506004E0.4070103@linux.vnet.ibm.com>

On 09/24/2012 08:59 AM, Xiao Guangrong wrote:
> On 09/24/2012 02:24 PM, Takuya Yoshikawa wrote:
>> This is an RFC since I have not done any comparison with the approach
>> using for_each_set_bit() which can be seen in Avi's work.
>> 
> 
> Why not compare it? I think for_each_set_bit is better and it can
> improve for all cases (in your patch, you did not consider all case,
> for example, if the guest under mm overcommit, it should generate
> lots of TLB flush/RELOAD request).
> 
> Actually, i think Avi's way can be improved in the further, we can
> just use one atomic operation to avoid cache-miss. May be like this:
> 
> while (vcpu->request) {
> 	xchg(vcpu->request, request);
> 
> 	for_each_set_bit(request) {
> 		clear_bit(X);
> 
> 		......
> 	}
> 	
> }

In fact I had something like that in one of the earlier versions, but it
was problematic.  I'll try to see what the issue was.


-- 
error compiling committee.c: too many arguments to function

  reply	other threads:[~2012-09-24 10:54 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-09-24  6:24 [RFC PATCH] KVM: x86: Skip request checking branches in vcpu_enter_guest() more effectively Takuya Yoshikawa
2012-09-24  6:59 ` Xiao Guangrong
2012-09-24 10:09   ` Avi Kivity [this message]
2012-09-24 14:32     ` Takuya Yoshikawa
2012-09-24 14:53       ` Avi Kivity
2012-09-24 13:55   ` Takuya Yoshikawa
2012-09-24  7:16 ` Gleb Natapov
2012-09-24 10:10   ` Avi Kivity
2012-09-24 13:58   ` Takuya Yoshikawa
2012-10-04 16:11   ` Takuya Yoshikawa
2012-09-24 10:18 ` Avi Kivity
2012-09-24 14:14   ` Takuya Yoshikawa
2012-09-24 14:50     ` Avi Kivity
2012-09-26  2:06       ` Takuya Yoshikawa
2012-09-27  9:28         ` Avi Kivity

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=5060313C.1060506@redhat.com \
    --to=avi@redhat.com \
    --cc=kvm@vger.kernel.org \
    --cc=mtosatti@redhat.com \
    --cc=xiaoguangrong@linux.vnet.ibm.com \
    --cc=yoshikawa_takuya_b1@lab.ntt.co.jp \
    /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.