This is an automated email from the ASF dual-hosted git repository.

xiaoxiang781216 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git

commit cbff2682f9ccddd339caeacb01f086d8f6c806e7
Author: Justin Hammond <[email protected]>
AuthorDate: Sun Aug 16 18:03:11 2026 +0800

    boards/risc-v/eic7700x: Use the optimized RISC-V string routines.
    
    Both boards used the C string and memory routines while the
    architecture's hand written ones sat unused beside them.  A 64 bit core
    with a filesystem, a network stack and a display above it spends a great
    deal of its time in these functions, and the assembly moves a register at
    a time rather than a byte.
    
    RISCV_STRING_FUNCTION selects the whole set, so one symbol covers memcpy,
    memset, memmove and the string routines together.  The generic memset
    tuning options go with it, since the C memset they tune is no longer
    built.
    
    These routines need the alignment fixes in apache/nuttx#19856 and
    apache/nuttx#19857 to be correct on misaligned pointers.
    
    Assisted-by: Claude:claude-opus-5
    Signed-off-by: Justin Hammond <[email protected]>
---
 boards/risc-v/eic7700x/eic7700-evb/configs/nsh/defconfig | 3 +--
 boards/risc-v/eic7700x/starpro64/configs/nsh/defconfig   | 3 +--
 2 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/boards/risc-v/eic7700x/eic7700-evb/configs/nsh/defconfig 
b/boards/risc-v/eic7700x/eic7700-evb/configs/nsh/defconfig
index dd8d2aaf194..15f32359329 100644
--- a/boards/risc-v/eic7700x/eic7700-evb/configs/nsh/defconfig
+++ b/boards/risc-v/eic7700x/eic7700-evb/configs/nsh/defconfig
@@ -78,8 +78,6 @@ CONFIG_INTELHEX_BINARY=y
 CONFIG_IRQ_WORK_STACKSIZE=2048
 CONFIG_LIBC_ENVPATH=y
 CONFIG_LIBC_EXECFUNCS=y
-CONFIG_LIBC_MEMSET_64BIT=y
-CONFIG_LIBC_MEMSET_OPTSPEED=y
 CONFIG_LIBC_PERROR_STDOUT=y
 CONFIG_LIBC_STRERROR=y
 CONFIG_MM_PGALLOC=y
@@ -96,6 +94,7 @@ CONFIG_RAM_SIZE=1006632960
 CONFIG_RAM_START=0x80200000
 CONFIG_RAW_BINARY=y
 CONFIG_READLINE_CMD_HISTORY=y
+CONFIG_RISCV_STRING_FUNCTION=y
 CONFIG_RR_INTERVAL=200
 CONFIG_SCHED_BACKTRACE=y
 CONFIG_SCHED_CPULOAD_SYSCLK=y
diff --git a/boards/risc-v/eic7700x/starpro64/configs/nsh/defconfig 
b/boards/risc-v/eic7700x/starpro64/configs/nsh/defconfig
index b7e11be2a6a..45abad45598 100644
--- a/boards/risc-v/eic7700x/starpro64/configs/nsh/defconfig
+++ b/boards/risc-v/eic7700x/starpro64/configs/nsh/defconfig
@@ -73,8 +73,6 @@ CONFIG_INTELHEX_BINARY=y
 CONFIG_IRQ_WORK_STACKSIZE=2048
 CONFIG_LIBC_ENVPATH=y
 CONFIG_LIBC_EXECFUNCS=y
-CONFIG_LIBC_MEMSET_64BIT=y
-CONFIG_LIBC_MEMSET_OPTSPEED=y
 CONFIG_LIBC_PERROR_STDOUT=y
 CONFIG_LIBC_STRERROR=y
 CONFIG_MM_PGALLOC=y
@@ -91,6 +89,7 @@ CONFIG_RAM_SIZE=1006632960
 CONFIG_RAM_START=0x80200000
 CONFIG_RAW_BINARY=y
 CONFIG_READLINE_CMD_HISTORY=y
+CONFIG_RISCV_STRING_FUNCTION=y
 CONFIG_RR_INTERVAL=200
 CONFIG_SCHED_BACKTRACE=y
 CONFIG_SCHED_CPULOAD_SYSCLK=y

Reply via email to