[PATCH v12 0/7] RISC-V: ifunced memcpy using new kernel hwprobe interface
Adhemerval Zanella Netto
adhemerval.zanella@linaro.org
Wed Feb 14 15:16:30 GMT 2024
On 14/02/24 11:31, Evan Green wrote:
>
> This series illustrates the use of a recently accepted Linux syscall that
> enumerates architectural information about the RISC-V cores the system
> is running on. In this series we expose a small wrapper function around
> the syscall. An ifunc selector for memcpy queries it to see if unaligned
> access is "fast" on this hardware. If it is, it selects a newly provided
> implementation of memcpy that doesn't work hard at aligning the src and
> destination buffers.
>
> For applications and libraries outside of glibc that want to use
> __riscv_hwprobe() in ifunc selectors, this series also sends a pointer
> to the riscv_hwprobe() function in as the second argument to ifunc
> selectors. A new inline convenience function can help application and
> library callers to check for validity and quickly probe a single key.
I still think we should address Jessica Clarke remarks for the ifunc ABI [1].
I recall that Florian has tried to address the ifunc ordering and that
Jessica proposed solutions was not fully sufficient to address all the
ifunc corner cases.
[1] https://sourceware.org/pipermail/libc-alpha/2024-January/154082.html
More information about the Libc-alpha
mailing list