[PATCH v3 1/2] riscv: introduce RISCV_EFFICIENT_UNALIGNED_ACCESS
Eric Biggers
ebiggers at kernel.org
Sat Dec 23 14:05:27 PST 2023
On Sat, Dec 23, 2023 at 11:52:25PM +0800, Jisheng Zhang wrote:
> +config RISCV_EFFICIENT_UNALIGNED_ACCESS
> + bool "Use unaligned access for some functions"
How about:
bool "Assume the CPU supports fast unaligned memory accesses"
> + depends on NONPORTABLE
> + select HAVE_EFFICIENT_UNALIGNED_ACCESS
> + default n
There's no need to explicitly list "default n", since n is already the default.
> + help
> + Say Y here if you want the kernel only run on hardware platforms which
> + support efficient unaligned access, then unaligned access will be used
> + in some functions for optimized performance.
How about:
Say Y here if you want the kernel to assume that the CPU supports
efficient unaligned memory accesses. When enabled, this option
improves the performance of the kernel on such CPUs. However, the
kernel will run much more slowly, or will not be able to run at all,
on CPUs that do not support efficient unaligned memory accesses.
- Eric
More information about the linux-riscv
mailing list