An acquire fence is used to make sure loads after the fence can observe
all store operations before a specific store-release.
But push doesn't read any data, except for the head which is part of a
CAS operation (the items on the list are not read).
So there is no need for the acquire barrier.
Signed-off-by: Steven Lariau <steven.lariau@arm.com>
Reviewed-by: Dharmik Thakkar <dharmik.thakkar@arm.com>
Reviewed-by: Ruifeng Wang <ruifeng.wang@arm.com>
Acked-by: Gage Eads <gage.eads@intel.com>
do {
struct rte_stack_lf_head new_head;
- /* Use an acquire fence to establish a synchronized-with
- * relationship between the list->head load and store-release
- * operations (as part of the rte_atomic128_cmp_exchange()).
- */
- __atomic_thread_fence(__ATOMIC_ACQUIRE);
-
/* Swing the top pointer to the first element in the list and
* make the last element point to the old top.
*/