summaryrefslogtreecommitdiff
path: root/sysdeps/mach
diff options
context:
space:
mode:
authorgfleury <gfleury@disroot.org>2025-11-20 10:56:47 +0200
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2025-11-21 00:29:44 +0100
commitb36a126f7d5ac7061e24ad97191bb9428b6b251f (patch)
tree1b477567b3cca21ed84558bd866e022ee07e8ca9 /sysdeps/mach
parentcd748a63ab1a7ae846175c532a3daab341c62690 (diff)
htl: move pthread_spin_{destroy, lock, init, trylock, unlock) and remove _pthread_spin_lock, into libc.
Message-ID: <20251120085647.326643-1-gfleury@disroot.org>
Diffstat (limited to 'sysdeps/mach')
-rw-r--r--sysdeps/mach/htl/pt-spin.c31
-rw-r--r--sysdeps/mach/hurd/i386/libc.abilist10
-rw-r--r--sysdeps/mach/hurd/i386/libpthread.abilist11
-rw-r--r--sysdeps/mach/hurd/x86_64/libc.abilist10
-rw-r--r--sysdeps/mach/hurd/x86_64/libpthread.abilist11
5 files changed, 20 insertions, 53 deletions
diff --git a/sysdeps/mach/htl/pt-spin.c b/sysdeps/mach/htl/pt-spin.c
deleted file mode 100644
index ff7db552ef..0000000000
--- a/sysdeps/mach/htl/pt-spin.c
+++ /dev/null
@@ -1,31 +0,0 @@
-/* Spin locks. Mach version.
- Copyright (C) 2002-2025 Free Software Foundation, Inc.
- This file is part of the GNU C Library.
-
- The GNU C Library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Lesser General Public
- License as published by the Free Software Foundation; either
- version 2.1 of the License, or (at your option) any later version.
-
- The GNU C Library is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with the GNU C Library; if not, see
- <https://www.gnu.org/licenses/>. */
-
-#include <machine-lock.h>
-
-/* In glibc. */
-extern void __spin_lock_solid (__spin_lock_t *lock);
-
-/* Lock the spin lock object LOCK. If the lock is held by another
- thread spin until it becomes available. */
-int
-_pthread_spin_lock (__spin_lock_t *lock)
-{
- __spin_lock_solid (lock);
- return 0;
-}
diff --git a/sysdeps/mach/hurd/i386/libc.abilist b/sysdeps/mach/hurd/i386/libc.abilist
index 0556602ab7..032ef39d22 100644
--- a/sysdeps/mach/hurd/i386/libc.abilist
+++ b/sysdeps/mach/hurd/i386/libc.abilist
@@ -130,6 +130,11 @@ GLIBC_2.12 pthread_setschedparam F
GLIBC_2.12 pthread_setschedprio F
GLIBC_2.12 pthread_setspecific F
GLIBC_2.12 pthread_sigmask F
+GLIBC_2.12 pthread_spin_destroy F
+GLIBC_2.12 pthread_spin_init F
+GLIBC_2.12 pthread_spin_lock F
+GLIBC_2.12 pthread_spin_trylock F
+GLIBC_2.12 pthread_spin_unlock F
GLIBC_2.12 pthread_testcancel F
GLIBC_2.12 pthread_yield F
GLIBC_2.12 sem_close F
@@ -2691,6 +2696,11 @@ GLIBC_2.43 pthread_mutex_transfer_np F
GLIBC_2.43 pthread_setconcurrency F
GLIBC_2.43 pthread_setname_np F
GLIBC_2.43 pthread_setschedprio F
+GLIBC_2.43 pthread_spin_destroy F
+GLIBC_2.43 pthread_spin_init F
+GLIBC_2.43 pthread_spin_lock F
+GLIBC_2.43 pthread_spin_trylock F
+GLIBC_2.43 pthread_spin_unlock F
GLIBC_2.43 pthread_testcancel F
GLIBC_2.43 pthread_timedjoin_np F
GLIBC_2.43 pthread_tryjoin_np F
diff --git a/sysdeps/mach/hurd/i386/libpthread.abilist b/sysdeps/mach/hurd/i386/libpthread.abilist
index 24e6bd2c4a..75636d8478 100644
--- a/sysdeps/mach/hurd/i386/libpthread.abilist
+++ b/sysdeps/mach/hurd/i386/libpthread.abilist
@@ -1,15 +1,4 @@
-GLIBC_2.12 __pthread_spin_destroy F
-GLIBC_2.12 __pthread_spin_init F
-GLIBC_2.12 __pthread_spin_lock F
-GLIBC_2.12 __pthread_spin_trylock F
-GLIBC_2.12 __pthread_spin_unlock F
-GLIBC_2.12 _pthread_spin_lock F
GLIBC_2.12 pthread_atfork F
-GLIBC_2.12 pthread_spin_destroy F
-GLIBC_2.12 pthread_spin_init F
-GLIBC_2.12 pthread_spin_lock F
-GLIBC_2.12 pthread_spin_trylock F
-GLIBC_2.12 pthread_spin_unlock F
GLIBC_2.32 call_once F
GLIBC_2.32 cnd_broadcast F
GLIBC_2.32 cnd_destroy F
diff --git a/sysdeps/mach/hurd/x86_64/libc.abilist b/sysdeps/mach/hurd/x86_64/libc.abilist
index 62e82a0887..7f0e601b8e 100644
--- a/sysdeps/mach/hurd/x86_64/libc.abilist
+++ b/sysdeps/mach/hurd/x86_64/libc.abilist
@@ -1621,6 +1621,11 @@ GLIBC_2.38 pthread_setschedparam F
GLIBC_2.38 pthread_setschedprio F
GLIBC_2.38 pthread_setspecific F
GLIBC_2.38 pthread_sigmask F
+GLIBC_2.38 pthread_spin_destroy F
+GLIBC_2.38 pthread_spin_init F
+GLIBC_2.38 pthread_spin_lock F
+GLIBC_2.38 pthread_spin_trylock F
+GLIBC_2.38 pthread_spin_unlock F
GLIBC_2.38 pthread_testcancel F
GLIBC_2.38 pthread_timedjoin_np F
GLIBC_2.38 pthread_tryjoin_np F
@@ -2369,6 +2374,11 @@ GLIBC_2.43 pthread_mutex_transfer_np F
GLIBC_2.43 pthread_setconcurrency F
GLIBC_2.43 pthread_setname_np F
GLIBC_2.43 pthread_setschedprio F
+GLIBC_2.43 pthread_spin_destroy F
+GLIBC_2.43 pthread_spin_init F
+GLIBC_2.43 pthread_spin_lock F
+GLIBC_2.43 pthread_spin_trylock F
+GLIBC_2.43 pthread_spin_unlock F
GLIBC_2.43 pthread_testcancel F
GLIBC_2.43 pthread_timedjoin_np F
GLIBC_2.43 pthread_tryjoin_np F
diff --git a/sysdeps/mach/hurd/x86_64/libpthread.abilist b/sysdeps/mach/hurd/x86_64/libpthread.abilist
index 57d796482b..b4f2a96250 100644
--- a/sysdeps/mach/hurd/x86_64/libpthread.abilist
+++ b/sysdeps/mach/hurd/x86_64/libpthread.abilist
@@ -1,9 +1,3 @@
-GLIBC_2.38 __pthread_spin_destroy F
-GLIBC_2.38 __pthread_spin_init F
-GLIBC_2.38 __pthread_spin_lock F
-GLIBC_2.38 __pthread_spin_trylock F
-GLIBC_2.38 __pthread_spin_unlock F
-GLIBC_2.38 _pthread_spin_lock F
GLIBC_2.38 call_once F
GLIBC_2.38 cnd_broadcast F
GLIBC_2.38 cnd_destroy F
@@ -17,11 +11,6 @@ GLIBC_2.38 mtx_lock F
GLIBC_2.38 mtx_timedlock F
GLIBC_2.38 mtx_trylock F
GLIBC_2.38 mtx_unlock F
-GLIBC_2.38 pthread_spin_destroy F
-GLIBC_2.38 pthread_spin_init F
-GLIBC_2.38 pthread_spin_lock F
-GLIBC_2.38 pthread_spin_trylock F
-GLIBC_2.38 pthread_spin_unlock F
GLIBC_2.38 thrd_create F
GLIBC_2.38 thrd_detach F
GLIBC_2.38 thrd_exit F