From: Jason Wang <jasowang@redhat.com>
To: "Michael S. Tsirkin" <mst@redhat.com>
Cc: kvm@vger.kernel.org, netdev@vger.kernel.org,
linux-kernel@vger.kernel.org,
virtualization@lists.linux-foundation.org,
maxime.coquelin@redhat.com, wexu@redhat.com, vkaplans@redhat.com
Subject: Re: [PATCH V2] vhost: introduce O(1) vq metadata cache
Date: Tue, 28 Feb 2017 11:23:34 +0800 [thread overview]
Message-ID: <3cb12bbd-922d-e7be-18bb-a48e559346c7@redhat.com> (raw)
In-Reply-To: <20170227203529-mutt-send-email-mst@kernel.org>
On 2017年02月28日 02:35, Michael S. Tsirkin wrote:
> On Wed, Feb 15, 2017 at 01:37:17PM +0800, Jason Wang wrote:
>>
>> On 2016年12月14日 17:53, Jason Wang wrote:
>>> When device IOTLB is enabled, all address translations were stored in
>>> interval tree. O(lgN) searching time could be slow for virtqueue
>>> metadata (avail, used and descriptors) since they were accessed much
>>> often than other addresses. So this patch introduces an O(1) array
>>> which points to the interval tree nodes that store the translations of
>>> vq metadata. Those array were update during vq IOTLB prefetching and
>>> were reset during each invalidation and tlb update. Each time we want
>>> to access vq metadata, this small array were queried before interval
>>> tree. This would be sufficient for static mappings but not dynamic
>>> mappings, we could do optimizations on top.
>>>
>>> Test were done with l2fwd in guest (2M hugepage):
>>>
>>> noiommu | before | after
>>> tx 1.32Mpps | 1.06Mpps(82%) | 1.30Mpps(98%)
>>> rx 2.33Mpps | 1.46Mpps(63%) | 2.29Mpps(98%)
>>>
>>> We can almost reach the same performance as noiommu mode.
>>>
>>> Signed-off-by: Jason Wang<jasowang@redhat.com>
>>> ---
>>> Changes from V1:
>>> - silent 32bit build warning
>> ping
> Could you rebase pls?
> I pushed my tree into linux next.
>
Ok, will do.
Thanks
_______________________________________________
Virtualization mailing list
Virtualization@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/virtualization
prev parent reply other threads:[~2017-02-28 3:23 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-12-14 9:53 [PATCH V2] vhost: introduce O(1) vq metadata cache Jason Wang
2017-02-15 5:37 ` Jason Wang
2017-02-27 18:35 ` Michael S. Tsirkin
2017-02-28 3:23 ` Jason Wang [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=3cb12bbd-922d-e7be-18bb-a48e559346c7@redhat.com \
--to=jasowang@redhat.com \
--cc=kvm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=maxime.coquelin@redhat.com \
--cc=mst@redhat.com \
--cc=netdev@vger.kernel.org \
--cc=virtualization@lists.linux-foundation.org \
--cc=vkaplans@redhat.com \
--cc=wexu@redhat.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 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).