39368ebfc6
This patch is to support C11 memory model barrier in librte_ring. There are 2 barrier implementation options in librte_ring (suggested by Jerin). 1. use rte_smp_rmb 2. use load_acquire/store_release(refer to [1]). The reason why providing 2 options is the performance benchmark difference in different arm machines, refer to [2]. CONFIG_RTE_RING_USE_C11_MEM_MODEL is provided, and by default it is "n" on any architectures and only "y" on arm64 so far. [1] https://github.com/freebsd/freebsd/blob/master/sys/sys/buf_ring.h#L170 [2] http://dpdk.org/ml/archives/dev/2017-October/080861.html Suggested-by: Jerin Jacob <jerin.jacob@caviumnetworks.com> Signed-off-by: Jia He <jia.he@hxt-semitech.com> Acked-by: Jerin Jacob <jerin.jacob@caviumnetworks.com> Acked-by: Olivier Matz <olivier.matz@6wind.com> Acked-by: Jianbo Liu <jianbo.liu@arm.com> Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>