From patchwork Sun Aug 17 23:26:18 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Samuel Thibault X-Patchwork-Id: 118497 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 4DB823858422 for ; Sun, 17 Aug 2025 23:27:15 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 4DB823858422 X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from sonata.ens-lyon.org (sonata.ens-lyon.org [140.77.166.138]) by sourceware.org (Postfix) with ESMTPS id DF0A53858D33 for ; Sun, 17 Aug 2025 23:26:27 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org DF0A53858D33 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=ens-lyon.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=bounce.ens-lyon.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org DF0A53858D33 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=140.77.166.138 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1755473188; cv=none; b=WKbnstk9MQ/jSuQjDI0foktkdtbxLeot7vVZSJD0uervZBGNzBw48IGM0Kl8SOtH4mzWupXOVEkPKB3bvcjr5HMi+1XVtuz7/G5pChJnwMVz1AeP0pe7eX/prUCwtZSSkmgw130gFtkwWuyqPQdNufxymSsJ+0I/hgq7hxP79f0= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1755473188; c=relaxed/simple; bh=BYs2aoUflfqsxjJcaga0CHnKQMWmuDz0akDnehB4aPo=; h=From:To:Subject:Date:Message-ID:MIME-Version; b=nrTylVhZ2gReFnZDgW2N74b+z88jTjtUjTco22QEcp8emIbSKQ98No70S9PdTNBqKrNP1zauO690Oivnw+BuAmA2wBHdlWZ3BLAfjseRrTLz7MivvwDQ1cBP9VFMUnov13TUzkFENbo1FMbqGr0+eu+dnHO3y+wtCpnw78qtp38= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org DF0A53858D33 Received: from localhost (localhost [127.0.0.1]) by sonata.ens-lyon.org (Postfix) with ESMTP id D23A4A49BD; Mon, 18 Aug 2025 01:26:26 +0200 (CEST) Received: from sonata.ens-lyon.org ([127.0.0.1]) by localhost (sonata.ens-lyon.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id mYbxSdnuMp9i; Mon, 18 Aug 2025 01:26:26 +0200 (CEST) Received: from begin (97.22.205.77.rev.sfr.net [77.205.22.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by sonata.ens-lyon.org (Postfix) with ESMTPSA id 7DF51A0528; Mon, 18 Aug 2025 01:26:26 +0200 (CEST) Received: from samy by begin with local (Exim 4.98.2) (envelope-from ) id 1unmld-00000002wC5-2QxI; Mon, 18 Aug 2025 01:26:25 +0200 From: Samuel Thibault To: libc-alpha@sourceware.org Cc: gfleury , commit-hurd@gnu.org Subject: [hurd,commited 1/7] htl: move sem_destroy into libc. Date: Mon, 18 Aug 2025 01:26:18 +0200 Message-ID: <20250817232624.700329-2-samuel.thibault@ens-lyon.org> X-Mailer: git-send-email 2.47.2 In-Reply-To: <20250817232624.700329-1-samuel.thibault@ens-lyon.org> References: <20250817232624.700329-1-samuel.thibault@ens-lyon.org> MIME-Version: 1.0 X-Spam-Status: No, score=-12.4 required=5.0 tests=BAYES_00, GIT_PATCH_0, JMQ_SPF_NEUTRAL, KAM_DMARC_STATUS, RCVD_IN_VALIDITY_RPBL_BLOCKED, RCVD_IN_VALIDITY_SAFE_BLOCKED, SPF_HELO_PASS, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libc-alpha-bounces~patchwork=sourceware.org@sourceware.org From: gfleury Message-ID: <20250817104023.91919-2-gfleury@disroot.org> --- htl/Makefile | 2 +- htl/Versions | 4 +++- sysdeps/htl/sem-destroy.c | 6 +++++- sysdeps/mach/hurd/i386/libc.abilist | 2 ++ sysdeps/mach/hurd/i386/libpthread.abilist | 1 - sysdeps/mach/hurd/x86_64/libc.abilist | 2 ++ sysdeps/mach/hurd/x86_64/libpthread.abilist | 1 - 7 files changed, 13 insertions(+), 5 deletions(-) diff --git a/htl/Makefile b/htl/Makefile index ec48f8b91a..e4a3adc99c 100644 --- a/htl/Makefile +++ b/htl/Makefile @@ -35,7 +35,6 @@ libpthread-routines := \ pt-getname-np \ pt-setname-np \ sem_close \ - sem-destroy \ sem-getvalue \ sem-init \ sem_open \ @@ -211,6 +210,7 @@ routines := \ pt-timedblock-intr \ pt-wakeup \ pt-yield \ + sem-destroy \ # routines shared-only-routines = forward diff --git a/htl/Versions b/htl/Versions index 5570a2b631..48e7fcead4 100644 --- a/htl/Versions +++ b/htl/Versions @@ -101,6 +101,7 @@ libc { pthread_sigmask; pthread_testcancel; pthread_yield; + sem_destroy; } GLIBC_2.21 { @@ -219,6 +220,7 @@ libc { pthread_timedjoin_np; pthread_tryjoin_np; pthread_yield; + sem_destroy; } GLIBC_PRIVATE { @@ -311,7 +313,7 @@ libpthread { pthread_create; - sem_close; sem_destroy; sem_getvalue; sem_init; sem_open; sem_post; + sem_close; sem_getvalue; sem_init; sem_open; sem_post; sem_timedwait; sem_trywait; sem_unlink; sem_wait; pthread_spin_destroy; pthread_spin_init; pthread_spin_lock; diff --git a/sysdeps/htl/sem-destroy.c b/sysdeps/htl/sem-destroy.c index 89b162d64c..daecf1a7e4 100644 --- a/sysdeps/htl/sem-destroy.c +++ b/sysdeps/htl/sem-destroy.c @@ -21,6 +21,7 @@ #include #include +#include int __sem_destroy (sem_t *sem) @@ -40,4 +41,7 @@ __sem_destroy (sem_t *sem) return 0; } -strong_alias (__sem_destroy, sem_destroy); +versioned_symbol (libc, __sem_destroy, sem_destroy, GLIBC_2_43); +# if OTHER_SHLIB_COMPAT (libpthread, GLIBC_2_12, GLIBC_2_43) +compat_symbol (libpthread, __sem_destroy, sem_destroy, GLIBC_2_12); +#endif diff --git a/sysdeps/mach/hurd/i386/libc.abilist b/sysdeps/mach/hurd/i386/libc.abilist index 1e5454818a..80bf6408ef 100644 --- a/sysdeps/mach/hurd/i386/libc.abilist +++ b/sysdeps/mach/hurd/i386/libc.abilist @@ -128,6 +128,7 @@ GLIBC_2.12 pthread_setspecific F GLIBC_2.12 pthread_sigmask F GLIBC_2.12 pthread_testcancel F GLIBC_2.12 pthread_yield F +GLIBC_2.12 sem_destroy F GLIBC_2.13 __fentry__ F GLIBC_2.14 syncfs F GLIBC_2.15 __fdelt_chk F @@ -2666,6 +2667,7 @@ GLIBC_2.43 pthread_testcancel F GLIBC_2.43 pthread_timedjoin_np F GLIBC_2.43 pthread_tryjoin_np F GLIBC_2.43 pthread_yield F +GLIBC_2.43 sem_destroy F GLIBC_2.5 __readlinkat_chk F GLIBC_2.5 inet6_opt_append F GLIBC_2.5 inet6_opt_find F diff --git a/sysdeps/mach/hurd/i386/libpthread.abilist b/sysdeps/mach/hurd/i386/libpthread.abilist index 8a056c89ff..99fdf00e14 100644 --- a/sysdeps/mach/hurd/i386/libpthread.abilist +++ b/sysdeps/mach/hurd/i386/libpthread.abilist @@ -25,7 +25,6 @@ GLIBC_2.12 pthread_spin_lock F GLIBC_2.12 pthread_spin_trylock F GLIBC_2.12 pthread_spin_unlock F GLIBC_2.12 sem_close F -GLIBC_2.12 sem_destroy F GLIBC_2.12 sem_getvalue F GLIBC_2.12 sem_init F GLIBC_2.12 sem_open F diff --git a/sysdeps/mach/hurd/x86_64/libc.abilist b/sysdeps/mach/hurd/x86_64/libc.abilist index 1bf1bcabe4..b3d402f059 100644 --- a/sysdeps/mach/hurd/x86_64/libc.abilist +++ b/sysdeps/mach/hurd/x86_64/libc.abilist @@ -1759,6 +1759,7 @@ GLIBC_2.38 seed48 F GLIBC_2.38 seed48_r F GLIBC_2.38 seekdir F GLIBC_2.38 select F +GLIBC_2.38 sem_destroy F GLIBC_2.38 semctl F GLIBC_2.38 semget F GLIBC_2.38 semop F @@ -2347,6 +2348,7 @@ GLIBC_2.43 pthread_testcancel F GLIBC_2.43 pthread_timedjoin_np F GLIBC_2.43 pthread_tryjoin_np F GLIBC_2.43 pthread_yield F +GLIBC_2.43 sem_destroy F HURD_CTHREADS_0.3 __cthread_getspecific F HURD_CTHREADS_0.3 __cthread_keycreate F HURD_CTHREADS_0.3 __cthread_setspecific F diff --git a/sysdeps/mach/hurd/x86_64/libpthread.abilist b/sysdeps/mach/hurd/x86_64/libpthread.abilist index 5caa7bcfb9..a03bebdf9e 100644 --- a/sysdeps/mach/hurd/x86_64/libpthread.abilist +++ b/sysdeps/mach/hurd/x86_64/libpthread.abilist @@ -45,7 +45,6 @@ GLIBC_2.38 pthread_spin_trylock F GLIBC_2.38 pthread_spin_unlock F GLIBC_2.38 sem_clockwait F GLIBC_2.38 sem_close F -GLIBC_2.38 sem_destroy F GLIBC_2.38 sem_getvalue F GLIBC_2.38 sem_init F GLIBC_2.38 sem_open F