[PATCH] Use 64-bit atomic on sem_t only with 8-byte alignment [BZ #33632]
Maciej W. Rozycki
macro@orcam.me.uk
Mon Nov 17 16:12:38 GMT 2025
On Sun, 16 Nov 2025, Andreas Schwab wrote:
> > uses 64-bit atomic operations on sem_t if 64-bit atomics are supported.
> > But sem_t may be aligned to 32-bit on 32-bit architectures. Add a macro,
> > SEM_T_ALIGN, for sem_t alignment and use 64-bit atomic operations on sem_t
> > only if 64-bit atomics are supported and SEM_T_ALIGN is at least 8-byte
> > aligned. This fixes BZ #33632.
>
> It's not universally true that you need 8-byte alignment for 64-bit
> atomic operation.
Also not all ILP32 ABIs are for 32-bit architectures, e.g. n32 MIPS is a
64-bit ABI on a 64-bit architecture, just crippled to 32-bit addressing.
How about s/32-bit architectures/ILP32 ABIs/ then?
Maciej
More information about the Libc-alpha
mailing list