DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] rte_prefetch0() is effective?
@ 2015-12-24  6:35 Moon-Sang Lee
  2016-01-13 11:34 ` Bruce Richardson
  0 siblings, 1 reply; 4+ messages in thread
From: Moon-Sang Lee @ 2015-12-24  6:35 UTC (permalink / raw)
  To: dev

I see codes as below in example directory, and I wonder it is effective.
Coherent IO is adopted to modern architectures,
so I think that DMA initiation by rte_eth_rx_burst() might already fulfills
cache lines of RX buffers.
Do I really need to call rte_prefetchX()?

            nb_rx = rte_eth_rx_burst(portid, queueid, pkts_burst,
MAX_PKT_BURST);
            ...
            /* 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);
            }


-- 
Moon-Sang Lee, SW Engineer
Email: sang0627@gmail.com
Wisdom begins in wonder. *Socrates*

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2016-01-13 17:29 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-12-24  6:35 [dpdk-dev] rte_prefetch0() is effective? Moon-Sang Lee
2016-01-13 11:34 ` Bruce Richardson
2016-01-13 15:17   ` Polehn, Mike A
2016-01-13 17:29   ` Matthew Hall

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).