Re: [PATCH v9 11/11] futex: Use a hashmask instead of hashsize.
From: Thomas Gleixner
Date: Wed Feb 26 2025 - 03:17:26 EST
On Tue, Feb 25 2025 at 18:09, Sebastian Andrzej Siewior wrote:
> The global hash uses futex_hashsize to save the amount of the hash
> buckets that have been allocated during system boot. On each
> futex_hash() invocation this number is substracted by one to get the
> mask. This can be optimized by saving directly the mask avoiding the
> substraction on each futex_hash() invocation.
As this is true independent of the private hash muck, this should go to
the top of the series, so it can be applied right away. Aside of that it
spares the churn in the new code ....
Thanks,
tglx