Re: [PATCH] x86/mm/pat: fix effective RW computation in lookup_address_in_pgd_attr()
From: Dave Hansen
Date: Thu Jul 16 2026 - 10:15:37 EST
On 7/16/26 06:44, Mike Rapoport wrote:
>> What does "slower" mean here?
>
> I've seen ~2% difference per set_memory call in instrumented cpa-test.
>
>> Does it matter in _practice_? Does it measurably slow down something an
>> end user might see?
> Yes, if a user is loading/unloading a BPF program in a tight loop 🙂
IMNHO, it may be worth optimizing if you can measure the difference in
BPF program load times (even in a tight loop).
But if set_memory() is the only thing you can measure a delta in, I'm
less convinced.
It's really sounding to me like we should do the simplest thing for a
bug fix and then arm wrestle later about how to micro-optimize the sucker.