> I wonder if some of the magic types in rte_memcpy() [1] could be used to fix
> the aliasing/eliding problem in the checksum function:
>
> struct __rte_packed_begin rte_unaligned_uint16_alias {
> unaligned_uint16_t val;
> } __rte_packed_end __rte_may_alias;
>
>
> [1]:
> https://elixir.bootlin.com/dpdk/v25.11/source/lib/eal/x86/include/rte_memcpy.h#L66Nice tip! clang/gcc optimize this (https://godbolt.org/z/WxjEbj6s4) and my reproducer doesn't trigger the gcc bug. v13 coming soon.

