Re: [PATCH RFC v2 00/20] mm: optimize unnecessary loads due to ptep_get() and friends out

Will Deacon <[email protected]>
Newsgroups org.kernel.vger.linux-openrisc,dev.linux.lists.loongarch,org.infradead.lists.kvm-riscv,org.infradead.lists.linux-riscv,org.kernel.vger.kvm,org.kernel.vger.linux-arch,org.kernel.vger.linux-kernel,org.kernel.vger.linux-mips,org.kvack.linux-mm
Message-ID <[email protected]>
On Wed, 22 Jul 2026 16:30:08 +0100, Yeoreum Yun wrote:
> Using ptep_get() and its counterparts in common code is suboptimal on
> kernel configurations with generic compile-time folded page tables.
> By default, ptep_get() and its friends expands to READ_ONCE(),
> forcing the compiler to emit a load even when the value is not used afterwards.
> 
> This issue was recently reported by Christophe Leroy [1] for ppc32
> preventing futher code conversion to ptep_get()/pmdp_get()/... helper
> and the same behavior can also be observed on arm64 when built with
> 2- or 3-level page tables
> 
> [...]

Applied the arm64 patch on the end to arm64 (for-next/mm), thanks!

[20/20] arm64: pgtable: convert pte_present() from macro to static inline
        https://git.kernel.org/arm64/c/3b56ebafecc4

Cheers,
-- 
Will

https://fixes.arm64.dev
https://next.arm64.dev
https://will.arm64.dev
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.