On 08/10/2026 23:03, Alexandre Felipe wrote:
> Currently Buffer header state is a 64-bit, but it is conceptually a bit
> field structure.
> The CAS loops care about only some of those bits, however by operating
> on a 64-bit structure unrelated field changes will cause a retry.
>
> The atomic operations don't support a comparison mask, but in this case
> we can at least CAS 32-bit, low and high half separately, reducing the
> likelihood
> of retrial.
Got benchmarks? I seriously doubt that you'd see any performance benefit
from this. I wouldn't be surprised if this was even slower.
- Heikki