From: Avi Kivity <avi@redhat.com>
To: Takuya Yoshikawa <yoshikawa.takuya@oss.ntt.co.jp>
Cc: mtosatti@redhat.com, kvm@vger.kernel.org
Subject: Re: [PATCH v2] KVM: x86: avoid unnecessary bitmap allocation when memslot is clean
Date: Tue, 04 May 2010 12:36:54 +0300 [thread overview]
Message-ID: <4BDFEAB6.3090602@redhat.com> (raw)
In-Reply-To: <20100428185036.5beb8a9e.yoshikawa.takuya@oss.ntt.co.jp>
On 04/28/2010 12:50 PM, Takuya Yoshikawa wrote:
> Hi Marcelo, Avi,
>
> I updated the patch as follows.
>
> Changelog:
> 1. Inserted one "r = -ENOMEM;" line following Avi's advice.
> 2. Little change of explanation about performance improvements.
>
> I'm now testing and cleaning up my next patch series based on this,
> so please apply this if this makes sense and has no problems.
>
> Thanks,
> Takuya
>
> ===
>
> Although we always allocate a new dirty bitmap in x86's get_dirty_log(),
> it is only used as a zero-source of copy_to_user() and freed right after
> that when memslot is clean. This patch uses clear_user() instead of doing
> this unnecessary zero-source allocation.
>
> Performance improvement: as we can expect easily, the time needed to
> allocate a bitmap is completely reduced. In my test, the improved ioctl
> was about 4 to 10 times faster than the original one for clean slots.
> Furthermore, reducing memory allocations and copies will produce good
> effects to caches too.
>
>
Applied, thanks.
--
error compiling committee.c: too many arguments to function
prev parent reply other threads:[~2010-05-04 9:36 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-04-26 9:56 [PATCH 0/1] KVM: x86: avoid unnecessary bitmap allocation when memslot is clean Takuya Yoshikawa
2010-04-26 9:58 ` [PATCH 1/1] " Takuya Yoshikawa
2010-04-27 12:36 ` Marcelo Tosatti
2010-04-27 13:18 ` Avi Kivity
2010-04-27 13:46 ` Takuya Yoshikawa
2010-04-28 4:17 ` Takuya Yoshikawa
2010-04-28 10:27 ` Avi Kivity
2010-04-28 10:26 ` Avi Kivity
2010-04-28 9:50 ` [PATCH v2] " Takuya Yoshikawa
2010-05-04 9:36 ` Avi Kivity [this message]
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=4BDFEAB6.3090602@redhat.com \
--to=avi@redhat.com \
--cc=kvm@vger.kernel.org \
--cc=mtosatti@redhat.com \
--cc=yoshikawa.takuya@oss.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.