Re: [PATCH v4 10/13] x86/mm: Simplify clear_page_*
From: Peter Zijlstra
Date: Mon Jun 16 2025 - 10:39:29 EST
On Mon, Jun 16, 2025 at 07:35:48AM -0700, Dave Hansen wrote:
> On 6/15/25 22:22, Ankur Arora wrote:
> > clear_page_rep() and clear_page_erms() are wrappers around "REP; STOS"
> > variations. Inlining gets rid of the costly call/ret (for cases with
> > speculative execution related mitigations.)
>
> Could you elaborate a bit on which "speculative execution related
> mitigations" are so costly with these direct calls?
Pretty much everything with RETHUNK set I would imagine.