[PATCH 00/14] use C11 alignas and normalize type alignment
Tyler Retzlaff
roretzla at linux.microsoft.com
Wed Feb 14 02:26:12 CET 2024
This series normalizes type and object alignment by doing the following.
Fill in expansion of existing __rte_aligned, __rte_cache_aligned and
__rte_cache_min_aligned macros for MSVC.
Where __rte_aligned, __rte_cache_aligned and __rte_cache_min_aligned
are used to align *types* move them to a location on the type definition
that both GCC and MSVC accept for both C and C++ compilation.
Where __rte_aligned, __rte_cache_aligned or __rte_cache_min_aligned
are used to align *objects* replace their usage with standard C11 alignas.
I've elected to put the series forward without introducing a new macro
similar to __rte_alignas. Assuming the convention of a lower case macro
starting with __rte is intended to be internal only and providing it
would only permit unintended use by applications.
Tyler Retzlaff (14):
eal: use C11 alignas
stack: use C11 alignas
sched: use C11 alignas
ring: remove unnecessary explicit alignment
pipeline: use C11 alignas
net: use C11 alignas
mbuf: remove unnecessary explicit alignment
hash: use C11 alignas
eventdev: use C11 alignas
ethdev: use C11 alignas
dmadev: use C11 alignas
distributor: use C11 alignas
acl: use C11 alignas
eal: redefine macro to be integer literal for MSVC
lib/acl/acl_run.h | 4 ++--
lib/distributor/rte_distributor.c | 2 +-
lib/dmadev/rte_dmadev_core.h | 4 ++--
lib/eal/arm/include/rte_vect.h | 4 ++--
lib/eal/include/generic/rte_atomic.h | 4 ++--
lib/eal/include/rte_common.h | 2 +-
lib/eal/loongarch/include/rte_vect.h | 8 ++++----
lib/eal/ppc/include/rte_vect.h | 4 ++--
lib/eal/riscv/include/rte_vect.h | 4 ++--
lib/eal/x86/include/rte_vect.h | 9 ++++++---
lib/ethdev/rte_ethdev.h | 4 ++--
lib/eventdev/rte_eventdev.h | 8 ++++----
lib/hash/rte_thash.h | 8 ++++----
lib/mbuf/rte_mbuf_core.h | 2 +-
lib/net/net_crc_avx512.c | 12 ++++++------
lib/net/net_crc_neon.c | 10 +++++-----
lib/net/net_crc_sse.c | 16 ++++++++--------
lib/net/rte_arp.h | 8 ++++----
lib/net/rte_ether.h | 8 ++++----
lib/pipeline/rte_table_action.c | 24 ++++++++++++------------
lib/ring/rte_ring_core.h | 4 ++--
lib/sched/rte_sched.c | 2 +-
lib/sched/rte_sched_common.h | 2 --
lib/stack/rte_stack.h | 2 +-
24 files changed, 78 insertions(+), 77 deletions(-)
--
1.8.3.1
More information about the dev
mailing list