]> git.ipfire.org Git - thirdparty/glibc.git/commit
Revert __HAVE_64B_ATOMICS configure check
authorAdhemerval Zanella <adhemerval.zanella@linaro.org>
Thu, 13 Nov 2025 17:26:08 +0000 (14:26 -0300)
committerAdhemerval Zanella <adhemerval.zanella@linaro.org>
Fri, 14 Nov 2025 17:05:20 +0000 (14:05 -0300)
commit7fec8a5de6826ef9ae440238d698f0fe5a5fb372
tree8e4cd2b3bbc291ffc6714692669ca9b9d69abbad
parent5bdf3c909274a4796b848d7595a025dca1951570
Revert __HAVE_64B_ATOMICS configure check

The 53807741fb44edb8e7c094cb5e7d4ff4e92a6ec1 added a configure check
for 64-bit atomic operations that were not previously enabled on some
32-bit ABIs.

However, the NPTL semaphore code casts a sem_t to a new_sem and issues
a 64-bit atomic operation for __HAVE_64B_ATOMICS.  Since sem_t has
32-bit alignment on 32-bit architectures, this prevents the use of
64-bit atomics even if the ABI supports them.

Assume 64-bit atomic support from __WORDSIZE, which maps to how glibc
defines it before the broken change.  Also rename __HAVE_64B_ATOMICS
to USE_64B_ATOMICS to define better the flag meaning.

Checked on x86_64-linux-gnu and i686-linux-gnu.

Reviewed-by: Wilco Dijkstra <Wilco.Dijkstra@arm.com>
28 files changed:
config.h.in
configure
configure.ac
htl/pt-internal.h
include/atomic.h
include/atomic_wide_counter.h
misc/atomic_wide_counter.c
nptl/pthread_cond_common.c
nptl/sem_getvalue.c
nptl/sem_init.c
nptl/sem_post.c
nptl/sem_waitcommon.c
nptl/semaphoreP.h
nptl/tst-sem11.c
nptl/tst-sem13.c
stdlib/setenv.h
sysdeps/alpha/atomic-machine.h
sysdeps/generic/atomic-machine.h
sysdeps/htl/sem-destroy.c
sysdeps/htl/sem-getvalue.c
sysdeps/htl/sem-post.c
sysdeps/htl/sem-timedwait.c
sysdeps/htl/sem-waitfast.c
sysdeps/nptl/internaltypes.h
sysdeps/nptl/rseq-access.h
sysdeps/riscv/atomic-machine.h
sysdeps/sparc/atomic-machine.h
sysdeps/x86/atomic-machine.h