From: Thomas Monjalon <thomas.monjalon@6wind.com>
To: Jianfeng Tan <jianfeng.tan@intel.com>
Cc: dev@dpdk.org, Yuanhan Liu <yuanhan.liu@linux.intel.com>,
zhihong.wang@intel.com, qian.q.xu@intel.com
Subject: Re: [dpdk-dev] [PATCH v3] examples/vhost: fix perf regression
Date: Fri, 22 Jul 2016 11:59:18 +0200 [thread overview]
Message-ID: <2545812.Vh7NDq74Ot@xps13> (raw)
In-Reply-To: <20160721013426.GA28708@yliu-dev.sh.intel.com>
2016-07-21 09:34, Yuanhan Liu:
> On Thu, Jul 21, 2016 at 12:42:45AM +0000, Jianfeng Tan wrote:
> > We find significant perfermance drop introduced by below commit,
> > when vhost example is started with --mergeable 0 and inside vm,
> > kernel virtio-net driver is used to do ip based forwarding.
> >
> > The commit, 859b480d5afd ("vhost: add guest offload setting"), adds
> > support for VIRTIO_NET_F_GUEST_TSO4 and VIRTIO_NET_F_GUEST_TSO6,
> > in vhost lib. But inside vhost example, the way to disable tso only
> > excludes the direction from virtio to vhost, but not the opposite
> > direction. When mergeable is disabled, it triggers big_packets path
> > of virtio-net driver to prepare to receive possible big packets with
> > size of 64K. Because mergeable is off, for each entry of avail ring,
> > virtio driver uses 19 desc chained together, with one desc pointing
> > to header, other 18 desc pointing to 4K-sized pages. But QEMU only
> > creates 256 desc entries for each vq, which results in that only 13
> > packets can be received. VM kernel can quickly handle those packets
> > and go to sleep (HLT).
> >
> > As QEMU has no option to set the desc entries of a vq, so here,
> > we disable VIRTIO_NET_F_GUEST_TSO4 and VIRTIO_NET_F_GUEST_TSO6
> > with VIRTIO_NET_F_HOST_TSO4 and VIRTIO_NET_F_HOST_TSO6 when we
> > disable tso of vhost example, to avoid VM kernel virtio driver
> > go into big_packets path.
> >
> > Fixes: 9fd72e3cbd29 ("examples/vhost: add virtio offload")
> >
> > Reported-by: Qian Xu <qian.q.xu@intel.com>
> > Signed-off-by: Jianfeng Tan <jianfeng.tan@intel.com>
> > ---
> > v3: reword commit log.
>
> Yes, much better. One minor nit: you forgot to carry the Tested-by from
> Qian.
>
> Acked-by: Yuanhan Liu <yuanhan.liu@linux.intel.com>
Applied, thanks
prev parent reply other threads:[~2016-07-22 9:59 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-19 13:53 [dpdk-dev] [PATCH] " Jianfeng Tan
2016-07-20 1:44 ` Yuanhan Liu
2016-07-20 2:44 ` Tan, Jianfeng
2016-07-20 3:16 ` Xu, Qian Q
2016-07-20 4:00 ` Yuanhan Liu
2016-07-20 3:52 ` Xu, Qian Q
2016-07-20 4:38 ` Yuanhan Liu
2016-07-20 5:50 ` Tan, Jianfeng
2016-07-20 6:13 ` Yuanhan Liu
2016-07-20 6:30 ` Tan, Jianfeng
2016-07-21 0:23 ` [dpdk-dev] [PATCH v2] " Jianfeng Tan
2016-07-21 0:42 ` Tan, Jianfeng
2016-07-21 0:42 ` [dpdk-dev] [PATCH v3] " Jianfeng Tan
2016-07-21 1:34 ` Yuanhan Liu
2016-07-21 1:38 ` Xu, Qian Q
2016-07-22 9:59 ` Thomas Monjalon [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=2545812.Vh7NDq74Ot@xps13 \
--to=thomas.monjalon@6wind.com \
--cc=dev@dpdk.org \
--cc=jianfeng.tan@intel.com \
--cc=qian.q.xu@intel.com \
--cc=yuanhan.liu@linux.intel.com \
--cc=zhihong.wang@intel.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).