04/06/2026 18:32, Stephen Hemminger:
> This patch replaces use of the deprecated rte_atomic32 code with
> GCC builtin atomic operations.
It compiles fine with GCC, but there is an issue with clang:
ninja: Entering directory `build-gcc-static'
ninja: no work to do.
ninja: Entering directory `build-gcc-shared'
ninja: no work to do.
ninja: Entering directory `build-clang-static'
ninja: no work to do.
ninja: Entering directory `build-clang-shared'
[1/3069] Compiling C object lib/librte_ring.a.p/ring_soring.c.o
rte_ring_gcc_pvt.h:43:2: error: address argument to atomic operation must be a
pointer to integer or pointer ('volatile _Atomic(uint32_t) *' invalid)
43 | __atomic_store_n(&ht->tail, new_val, __ATOMIC_RELEASE);
| ^ ~~~~~~~~~
> Although it would be preferable to use C11 version on all architectures,
> there is a performance loss if we do it that way:
>
> Measured on i9-13900H, two physical cores MP/MC bulk n=128, 10 runs:
> with C11 builtin: 5.86 cycles/elem
> with __sync builtin: 5.36 cycles/elem (-9.4%)
You don't compare with the current rte_atomic functions?