glibc/sysdeps/x86
Stefan Liebler b9579342c6 Remove support for lock elision.
The support for lock elision was already deprecated with glibc 2.42:
commit 77438db8cf
"Mark support for lock elision as deprecated."
See also discussions:
https://sourceware.org/pipermail/libc-alpha/2025-July/168492.html

This patch removes the architecture specific support for lock elision
for x86, powerpc and s390 by removing the elision-conf.h, elision-conf.c,
elision-lock.c, elision-timed.c, elision-unlock.c, elide.h, htm.h/hle.h files.
Those generic files are also removed.

The architecture specific structures are adjusted and the elision fields are
marked as unused.  See struct_mutex.h files.
Furthermore in struct_rwlock.h, the leftover __rwelision was also removed.
Those were originally removed with commit 0377a7fde6
"nptl: Remove rwlock elision definitions"
and by chance reintroduced with commit 7df8af43ad
"nptl: Add struct_rwlock.h"

The common code (e.g. the pthread_mutex-files) are changed back to the time
before lock elision was introduced with the x86-support:
- commit 1cdbe57948
"Add the low level infrastructure for pthreads lock elision with TSX"
- commit b023e4ca99
"Add new internal mutex type flags for elision."
- commit 68cc29355f
"Add minimal test suite changes for elision enabled kernels"
- commit e8c659d74e
"Add elision to pthread_mutex_{try,timed,un}lock"
- commit 49186d21ef
"Disable elision for any pthread_mutexattr_settype call"
- commit 1717da59ae
"Add a configure option to enable lock elision and disable by default"

Elision is removed also from the tunables, the initialization part, the
pretty-printers and the manual.

Some extra handling in the testsuite is removed as well as the full tst-mutex10
testcase, which tested a race while enabling lock elision.

I've also searched the code for "elision", "elide", "transaction" and e.g.
cleaned some comments.

I've run the testsuite on x86_64 and s390x and run the build-many-glibcs.py
script.
Thanks to Sachin Monga, this patch is also tested on powerpc.

A NEWS entry also mentions the removal.
Reviewed-by: Wilco Dijkstra  <Wilco.Dijkstra@arm.com>
2025-11-18 14:21:13 +01:00
..
bits
fpu
htl
include
nptl Remove support for lock elision. 2025-11-18 14:21:13 +01:00
sys/platform
Makeconfig
Makefile
Versions
__longjmp_cancel.S
abi-note.c
atomic-machine.h
cacheinfo.c
cacheinfo.h
configure
configure.ac
cpu-features-offsets.sym
cpu-features.c
cpu-tunables.c
dl-cacheinfo.h
dl-diagnostics-cpu.c
dl-get-cpu-features.c
dl-hwcap.h
dl-hwcap2.h
dl-isa-level.h
dl-lookupcfg.h
dl-minsigstacksize.h
dl-new-hash.h
dl-procinfo.c
dl-prop.h
dl-tunables.list
elf-initfini.h
features-offsets.sym
float128-abi.h
fpu_control.h
get-cpuid-feature-leaf.c
get-isa-level.h
hp-timing.h
init-arch.h
isa-ifunc-macros.h
isa-level.c
isa-level.h
jmp_buf-ssp.sym
ldbl2mpn.c
ldsodefs.h
libc-start.c
link_map.h
linkmap.h
longjmp.c
readelflib.c
sysdep.h
tininess.h
tst-cpu-features-cpuinfo-static.c
tst-cpu-features-cpuinfo.c
tst-cpu-features-supports-static.c
tst-cpu-features-supports.c
tst-get-cpu-features-static.c
tst-get-cpu-features.c
tst-gnu2-tls2-x86-noxsave.c
tst-gnu2-tls2-x86-noxsavec.c
tst-gnu2-tls2-x86-noxsavexsavec.c
tst-gnu2-tls2.c
tst-gnu2-tls2.h
tst-hwcap-tunables.c
tst-ifunc-isa-1-static.c
tst-ifunc-isa-1.c
tst-ifunc-isa-2-static.c
tst-ifunc-isa-2.c
tst-ifunc-isa.h
tst-isa-level-1.c
tst-isa-level-mod-1-baseline.c
tst-isa-level-mod-1-v2.c
tst-isa-level-mod-1-v3.c
tst-isa-level-mod-1-v4.c
tst-isa-level-mod-1.c
tst-ldbl-nonnormal-printf.c
tst-memchr-rtm.c
tst-memcmp-rtm.c
tst-memmove-rtm.c
tst-memrchr-rtm.c
tst-memset-rtm.c
tst-setjmp-cet.c
tst-stack-align.h
tst-strcasecmp-rtm.c
tst-strchr-rtm.c
tst-strcmp-rtm.c
tst-strcpy-rtm.c
tst-string-rtm.h
tst-strlen-rtm.c
tst-strncasecmp-rtm.c
tst-strncmp-rtm.c
tst-strrchr-rtm.c
tst-sysconf-cache-linesize-static.c
tst-sysconf-cache-linesize.c
tst-tls23.c
tst-tls23.h
tst-wcscmp-rtm.c
tst-wcsncmp-rtm.c
utmp-size.h