From: uk7b@foxmail.com
To: dev@dpdk.org
Cc: Sun Yuechi <sunyuechi@iscas.ac.cn>
Subject: [PATCH 0/5] *** Add RISC-V V extension detection and LPM, FIB optimization ***
Date: Wed, 2 Jul 2025 00:13:37 +0800 [thread overview]
Message-ID: <tencent_4A90436AC5AA735B587C61253C34AA891608@qq.com> (raw)
From: Sun Yuechi <sunyuechi@iscas.ac.cn>
This patch series adds support for the RISC-V Vector (V) extension and
provides an optimized implementation of `rte_lpm_lookupx4` using RVV.
The initialization of lpm/vtbl_entry is not fully vectorized here because
doing so would require __riscv_vluxei32_v_u32m1, which is slower
than the scalar approach in this small-scale scenario.
- Test: app/test/lpm_perf_autotest
- Platform: Banana Pi BPI-F3
- SoC: Spacemit X60 (8 cores with Vector extension)
- CPU Frequency: up to 1.6 GHz
- Cache: 256 KiB L1d ×8, 256 KiB L1i ×8, 1 MiB L2 ×2
- Memory: 16 GiB
- Kernel: Linux 6.6.36
- Compiler: GCC 14.2.0 (with RVV intrinsic support)
LPM LookupX4:
scalar: 5.7 cycles
rvv: 4.6 cycles
FIB lookup_bulk:
scalar: 5.9 cycles
rvv: 5.4 cycles
Sun Yuechi (5):
config/riscv: detect V extension
eal/riscv/spinlock: add rte_cpuflag.h
lib/lpm: R-V V rte_lpm_lookupx4
lib/fib: R-V V rte_fib_lookup_bulk
riscv: override machine_args only when default
.mailmap | 1 +
MAINTAINERS | 2 +
config/riscv/meson.build | 39 +++++++++++++++---
lib/eal/riscv/include/rte_spinlock.h | 1 +
lib/eal/riscv/include/rte_vect.h | 4 ++
lib/fib/dir24_8.c | 20 ++++++++++
lib/fib/dir24_8_rvv.c | 60 ++++++++++++++++++++++++++++
lib/fib/dir24_8_rvv.h | 24 +++++++++++
lib/fib/meson.build | 2 +
lib/lpm/meson.build | 1 +
lib/lpm/rte_lpm.h | 2 +
lib/lpm/rte_lpm_rvv.h | 59 +++++++++++++++++++++++++++
12 files changed, 209 insertions(+), 6 deletions(-)
create mode 100644 lib/fib/dir24_8_rvv.c
create mode 100644 lib/fib/dir24_8_rvv.h
create mode 100644 lib/lpm/rte_lpm_rvv.h
--
2.50.0
reply other threads:[~2025-07-01 16:14 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=tencent_4A90436AC5AA735B587C61253C34AA891608@qq.com \
--to=uk7b@foxmail.com \
--cc=dev@dpdk.org \
--cc=sunyuechi@iscas.ac.cn \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).