From: Maxime Coquelin <maxime.coquelin@redhat.com>
To: Marvin Liu <yong.liu@intel.com>, chenbo.xia@intel.com
Cc: dev@dpdk.org, "Richardson, Bruce" <bruce.richardson@intel.com>
Subject: Re: [dpdk-dev] [PATCH] net/virtio: enable packet data prefetch on x86
Date: Thu, 12 Nov 2020 09:48:06 +0100 [thread overview]
Message-ID: <ae30534a-2a6f-d295-de42-8844c1cae091@redhat.com> (raw)
In-Reply-To: <20201111154007.13426-1-yong.liu@intel.com>
Hi Marvin,
On 11/11/20 4:40 PM, Marvin Liu wrote:
> Data prefetch instruction can preload data into cpu’s hierarchical
> cache before data access. Virtio datapath utilized this feature for
> data access acceleration. As config RTE_PMD_PACKET_PREFETCH was
> discarded, now packet data prefetch is enabled based on architecture.
>
> Signed-off-by: Marvin Liu <yong.liu@intel.com>
>
> diff --git a/drivers/net/virtio/virtqueue.h b/drivers/net/virtio/virtqueue.h
> index 42c4c9882..0196290a5 100644
> --- a/drivers/net/virtio/virtqueue.h
> +++ b/drivers/net/virtio/virtqueue.h
> @@ -106,7 +106,7 @@ virtqueue_store_flags_packed(struct vring_packed_desc *dp,
> dp->flags = flags;
> }
> }
> -#ifdef RTE_PMD_PACKET_PREFETCH
> +#if defined(RTE_ARCH_X86)
> #define rte_packet_prefetch(p) rte_prefetch1(p)
> #else
> #define rte_packet_prefetch(p) do {} while(0)
>
Thanks for catching this issue.
I agree it should be re-enabled by default, and not only on X86, not
only on Virtio PMD.
AFAICS, prefetch was enabled for all platforms before the switch to
Meson, so I see it as an involuntary change that needs to be reverted.
Then, I think having a possibility to disable it would be nice, so maybe
we should add an option in our build system to do that.
Thanks,
Maxime
next prev parent reply other threads:[~2020-11-12 8:48 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-11-11 15:40 Marvin Liu
2020-11-11 15:45 ` David Marchand
2020-11-11 15:53 ` Bruce Richardson
2020-11-11 15:56 ` David Marchand
2020-11-12 8:48 ` Maxime Coquelin [this message]
2020-11-12 8:57 ` David Marchand
2020-11-13 1:20 ` Liu, Yong
2020-11-13 7:27 ` David Marchand
2020-11-13 12:21 ` Liu, Yong
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=ae30534a-2a6f-d295-de42-8844c1cae091@redhat.com \
--to=maxime.coquelin@redhat.com \
--cc=bruce.richardson@intel.com \
--cc=chenbo.xia@intel.com \
--cc=dev@dpdk.org \
--cc=yong.liu@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).