Fix xmm_t to rte_xmm_t scalar conversion
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest3 patches 16 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/3 | eal/riscv: fix xmm_t casting for C++lib/ | +2 | 1 reply | |
| 2/3 | lpm: fix xmm_t casting for C++ in scalar versionlib/ | +6 | 1 reply | |
| 3/3 | ci: use crossbuild-essential-riscv64 for compiling.github/ | +1 | 2 replies |
Reviews trailers per patch
All 3 patches have a Reviewed-by or Acked-by.
| Patch | David Marchand | Aaron Conole |
|---|---|---|
| 1/3 | R-b | |
| 2/3 | R-b | |
| 3/3 | R-b | A-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH 0/3] Fix xmm_t to rte_xmm_t scalar conversion
As David noticed in [1] there is an issue with C++ compilation of the rte_vect.h header in RISC-V. Upon closer inspection, the problem appears on all architectures due to the type conversion rules in C++.
More precisely a union type rte_xmm_t requires a conversion constructor from xmm_t type.
The most obvious fix is to use a structure initializer for such copies (since rte_xmm_t union contains xmm_t anyway). The generated assembly at -O2 is exactly the same, so there's no real impact.
The bigger question is whether accessing bits of the architecture specific xmm_t type in an array fashion is always correct? All current architectures define rte_xmm_t in the same manner implying that.
Additionally change RISC-V CI settings to use crossbuild-essential-riscv64 package which provides tools that enable C++ checks.
[1] http://mails.dpdk.org/archives/dev/2022-June/243683.html
Stanislaw Kardach (3):
eal/riscv: fix xmm_t casting for C++
lpm: fix xmm_t casting for C++ in scalar version
ci: use crossbuild-essential-riscv64 for compiling
.github/workflows/build.yml | 3 +-- lib/eal/riscv/include/rte_vect.h | 4 ++-- lib/lpm/rte_lpm_scalar.h | 11 ++++++----- 3 files changed, 9 insertions(+), 9 deletions(-)
Signature · 1 line
2.30.2