]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
htl: move pthread_cond_signal into libc.
authorgfleury <gfleury@disroot.org>
Thu, 19 Dec 2024 20:37:24 +0000 (22:37 +0200)
committerSamuel Thibault <samuel.thibault@ens-lyon.org>
Sun, 22 Dec 2024 22:34:28 +0000 (23:34 +0100)
Signed-off-by: gfleury <gfleury@disroot.org>
Message-ID: <20241219203727.669825-6-gfleury@disroot.org>

htl/Makefile
htl/Versions
htl/forward.c
htl/pt-initialize.c
sysdeps/htl/pt-cond-signal.c
sysdeps/htl/pthread-functions.h
sysdeps/htl/pthreadP.h
sysdeps/mach/hurd/i386/libc.abilist
sysdeps/mach/hurd/i386/libpthread.abilist
sysdeps/mach/hurd/x86_64/libpthread.abilist

index 629a8a5359da3a8f0c6135ee9b31006025e359de..542f5eadf017cc4c5f2535fa3ef71f053c021cf3 100644 (file)
@@ -91,7 +91,6 @@ libpthread-routines := \
   pt-rwlock-timedrdlock \
   pt-rwlock-timedwrlock \
   pt-rwlock-unlock \
-  pt-cond-signal \
   pt-cond-wait \
   pt-cond-timedwait \
   pt-hurd-cond-wait \
@@ -196,6 +195,7 @@ routines := \
   pt-cond-brdcast \
   pt-cond-destroy \
   pt-cond-init \
+  pt-cond-signal \
   pt-condattr-destroy \
   pt-condattr-getclock \
   pt-condattr-getpshared \
index 6348800117ec3c2a52e0b91388a323b029293a21..465db4960a5505ad9b29603b4771a6429136efc5 100644 (file)
@@ -29,6 +29,7 @@ libc {
     pthread_cond_broadcast;
     pthread_cond_destroy;
     pthread_cond_init;
+    pthread_cond_signal;
     pthread_condattr_getclock;
     pthread_condattr_init;
     pthread_condattr_destroy;
@@ -100,6 +101,7 @@ libc {
     __pthread_cond_broadcast;
     __pthread_cond_destroy;
     __pthread_cond_init;
+    __pthread_cond_signal;
     __pthread_condattr_init;
     __pthread_default_condattr;
     __pthread_sigstate;
@@ -140,7 +142,7 @@ libpthread {
 
     pthread_cancel;
 
-    pthread_cond_signal; pthread_cond_timedwait; pthread_cond_wait;
+    pthread_cond_timedwait; pthread_cond_wait;
 
     pthread_create; pthread_detach; pthread_exit;
 
index 6c83a2e76c0cbca807927865414bc0def289ae97..78758cef620830c71ff75d6e67ae75838e35dd02 100644 (file)
@@ -53,7 +53,6 @@ name decl                                                                   \
 #define FORWARD(name, decl, params, defretval) \
   FORWARD2 (name, int, decl, params, return defretval)
 
-FORWARD (pthread_cond_signal, (pthread_cond_t *cond), (cond), 0)
 FORWARD (pthread_cond_wait, (pthread_cond_t *cond, pthread_mutex_t *mutex),
         (cond, mutex), 0)
 FORWARD (pthread_cond_timedwait,
index c0929a14988de24106b6a2a5fc854596b1303ae7..cf312f1cd632d9a45e70d38afc4d0362ac093ca2 100644 (file)
@@ -27,7 +27,6 @@
 
 #if IS_IN (libpthread)
 static const struct pthread_functions pthread_functions = {
-  .ptr_pthread_cond_signal = __pthread_cond_signal,
   .ptr_pthread_cond_wait = __pthread_cond_wait,
   .ptr_pthread_cond_timedwait = __pthread_cond_timedwait,
   .ptr___pthread_exit = __pthread_exit,
index 4eade0374931da5a7ba6746c5850da03090623b1..6016abd161bebd904355946fa646ea2cb4836a36 100644 (file)
@@ -17,7 +17,7 @@
    <https://www.gnu.org/licenses/>.  */
 
 #include <pthread.h>
-
+#include <shlib-compat.h>
 #include <pt-internal.h>
 
 /* Unblock at least one of the threads that are blocked on condition
@@ -38,5 +38,9 @@ __pthread_cond_signal (pthread_cond_t *cond)
 
   return 0;
 }
+libc_hidden_def (__pthread_cond_signal)
+versioned_symbol (libc, __pthread_cond_signal, pthread_cond_signal, GLIBC_2_21);
 
-weak_alias (__pthread_cond_signal, pthread_cond_signal);
+#if OTHER_SHLIB_COMPAT (libpthread, GLIBC_2_12, GLIBC_2_21)
+compat_symbol (libc, __pthread_cond_signal, pthread_cond_signal, GLIBC_2_12);
+#endif
index c09a39823e58e4ab876abfdec95a440adaef3a7a..fafefa5a4c942edf8b064216b276010a3b5067eb 100644 (file)
@@ -21,7 +21,6 @@
 
 #include <pthread.h>
 
-int __pthread_cond_signal (pthread_cond_t *);
 int __pthread_cond_wait (pthread_cond_t *, pthread_mutex_t *);
 int __pthread_cond_timedwait (pthread_cond_t *, pthread_mutex_t *,
                             const struct timespec *);
@@ -52,7 +51,6 @@ int _cthreads_ftrylockfile (FILE *);
    so if possible avoid breaking it and append new hooks to the end.  */
 struct pthread_functions
 {
-  int (*ptr_pthread_cond_signal) (pthread_cond_t *);
   int (*ptr_pthread_cond_wait) (pthread_cond_t *, pthread_mutex_t *);
   int (*ptr_pthread_cond_timedwait) (pthread_cond_t *, pthread_mutex_t *,
                                     const struct timespec *);
index 4138abdd3731d640f9db2d53dea374f7cdfa69a9..3c9f38c73438dced24d48449a17c5f774e8caf1c 100644 (file)
@@ -45,6 +45,7 @@ extern int __pthread_cond_init (pthread_cond_t *cond,
                                const pthread_condattr_t *cond_attr);
 libc_hidden_proto (__pthread_cond_init)
 extern int __pthread_cond_signal (pthread_cond_t *cond);
+libc_hidden_proto (__pthread_cond_signal);
 extern int __pthread_cond_broadcast (pthread_cond_t *cond);
 libc_hidden_proto (__pthread_cond_broadcast);
 extern int __pthread_cond_wait (pthread_cond_t *cond, pthread_mutex_t *mutex);
index 35ae6bb27f24cf58d640e3044cad0d205daa8f30..e2f18b81721c1f0e5da2533c9c552e647fe22b0e 100644 (file)
@@ -52,6 +52,7 @@ GLIBC_2.12 pthread_attr_setstacksize F
 GLIBC_2.12 pthread_cond_broadcast F
 GLIBC_2.12 pthread_cond_destroy F
 GLIBC_2.12 pthread_cond_init F
+GLIBC_2.12 pthread_cond_signal F
 GLIBC_2.12 pthread_condattr_destroy F
 GLIBC_2.12 pthread_condattr_getclock F
 GLIBC_2.12 pthread_condattr_getpshared F
index fd35a94f02016db3d3ba599cff481e0d41aac2ca..7c61af5fa11570f98056e4b2ef14cb329daae17d 100644 (file)
@@ -30,7 +30,6 @@ GLIBC_2.12 pthread_barrierattr_getpshared F
 GLIBC_2.12 pthread_barrierattr_init F
 GLIBC_2.12 pthread_barrierattr_setpshared F
 GLIBC_2.12 pthread_cancel F
-GLIBC_2.12 pthread_cond_signal F
 GLIBC_2.12 pthread_cond_timedwait F
 GLIBC_2.12 pthread_cond_wait F
 GLIBC_2.12 pthread_create F
index 1bc76cf8e8e1f6e643368a1cbbac97e5090988b5..5b2da07745dd93c2fae6855f8041e64d990bc4df 100644 (file)
@@ -49,7 +49,6 @@ GLIBC_2.38 pthread_barrierattr_setpshared F
 GLIBC_2.38 pthread_cancel F
 GLIBC_2.38 pthread_clockjoin_np F
 GLIBC_2.38 pthread_cond_clockwait F
-GLIBC_2.38 pthread_cond_signal F
 GLIBC_2.38 pthread_cond_timedwait F
 GLIBC_2.38 pthread_cond_wait F
 GLIBC_2.38 pthread_create F