summaryrefslogtreecommitdiff
path: root/include/linux/timerqueue.h
diff options
context:
space:
mode:
authorFeng Jiang <jiangfeng@kylinos.cn>2026-04-03 19:28:47 -0600
committerPaul Walmsley <pjw@kernel.org>2026-04-04 18:42:44 -0600
commitbef64bcb940269a503d12eb1bc180d1aa9adf74d (patch)
tree3e71a4e6ab11d7eb513cc0ca8e91bb0c278f4c7f /include/linux/timerqueue.h
parentadf542133960d402f63c976b00e46be4d986d4c3 (diff)
riscv: lib: add strrchr() implementation
Add an assembly implementation of strrchr() for RISC-V. This implementation minimizes instruction count and avoids unnecessary memory access to the stack. The performance benefits are most visible on small workloads (1-16 bytes) where the architectural savings in function overhead outweigh the execution time of the scan loop. Benchmark results (QEMU TCG, rv64): Length | Original (MB/s) | Optimized (MB/s) | Improvement -------|-----------------|------------------|------------ 1 B | 20 | 21 | +5.0% 7 B | 111 | 120 | +8.1% 16 B | 189 | 199 | +5.3% 512 B | 361 | 382 | +5.8% 4096 B | 388 | 391 | +0.8% Signed-off-by: Feng Jiang <jiangfeng@kylinos.cn> Tested-by: Joel Stanley <joel@jms.id.au> Link: https://patch.msgid.link/20260130025018.172925-9-jiangfeng@kylinos.cn Signed-off-by: Paul Walmsley <pjw@kernel.org>
Diffstat (limited to 'include/linux/timerqueue.h')
0 files changed, 0 insertions, 0 deletions