From: Parikshith Chowdaiah <pchowdai@gmail.com>
To: dev@dpdk.org
Subject: [dpdk-dev] rte_prefetch0() performance info
Date: Thu, 5 Mar 2015 14:16:23 +0530 [thread overview]
Message-ID: <CABxpG4ZA5FmaNOUZODGCnDcgFoT1eSfo5=4gO-rp_wSv8SJeCw@mail.gmail.com> (raw)
Hi all,
I have a question related to usage of rte_prefetch0() function,In one of
the sample files, we have implementation like:
/* Prefetch first packets */
for (j = 0; j < PREFETCH_OFFSET && j < nb_rx; j++) {
rte_prefetch0(rte_pktmbuf_mtod(
pkts_burst[j], void *));
}
/* Prefetch and forward already prefetched packets */
for (j = 0; j < (nb_rx - PREFETCH_OFFSET); j++) {
rte_prefetch0(rte_pktmbuf_mtod(pkts_burst[
j + PREFETCH_OFFSET], void *));
l3fwd_simple_forward(pkts_burst[j], portid,
qconf);
}
/* Forward remaining prefetched packets */
for (; j < nb_rx; j++) {
l3fwd_simple_forward(pkts_burst[j], portid,
qconf);
}
where the prefetch0() is carried out in multiple split iterations, would
like to have an insight on whether it makes performance improvement to
likes of:
for (j = 0; j < nb_rx; j++) {
rte_prefetch0(rte_pktmbuf_mtod(
pkts_burst[j], void *));
}
and how frequent rte_prefetch() needs to called for the same packet. and
any mechanisms to call in bulk for 64 packets at once ?
thanks
Parikshith
next reply other threads:[~2015-03-05 8:46 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-05 8:46 Parikshith Chowdaiah [this message]
2015-03-05 8:51 ` Anuj Kalia
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='CABxpG4ZA5FmaNOUZODGCnDcgFoT1eSfo5=4gO-rp_wSv8SJeCw@mail.gmail.com' \
--to=pchowdai@gmail.com \
--cc=dev@dpdk.org \
/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).