eal: add cache line demotion API
authorOmkar Maslekar <omkar.maslekar@intel.com>
Thu, 15 Oct 2020 23:20:03 +0000 (16:20 -0700)
committerDavid Marchand <david.marchand@redhat.com>
Fri, 16 Oct 2020 12:11:45 +0000 (14:11 +0200)
commit4ffc2276e20b80d019d2190f35f4b6093bed6554
treeb7559c6fd40c3058d2d61c8cfe6bc5f13ff81e63
parent2941600108cdf47a618368e63339d845f0df6cd8
eal: add cache line demotion API

rte_cldemote is similar to a prefetch hint - in reverse.
On x86, cldemote(addr) enables software to hint to hardware that line is
likely to be shared. This is quite useful in core-to-core communications
where cache-line is likely to be shared.
ARM and PPC implementation is provided with NOP and can be added if any
equivalent instructions could be used for implementation on those
architectures.

Signed-off-by: Omkar Maslekar <omkar.maslekar@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: David Christensen <drc@linux.vnet.ibm.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
Reviewed-by: Ruifeng Wang <ruifeng.wang@arm.com>
app/test/test_prefetch.c
doc/guides/rel_notes/release_20_11.rst
lib/librte_eal/arm/include/rte_prefetch_32.h
lib/librte_eal/arm/include/rte_prefetch_64.h
lib/librte_eal/include/generic/rte_prefetch.h
lib/librte_eal/ppc/include/rte_prefetch.h
lib/librte_eal/x86/include/rte_prefetch.h