From owner-freebsd-standards Mon Sep 16 23:13:58 2002 Delivered-To: freebsd-standards@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 157DC37B400 for ; Mon, 16 Sep 2002 23:13:57 -0700 (PDT) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.FreeBSD.org (Postfix) with ESMTP id CD82B43E75 for ; Mon, 16 Sep 2002 23:13:56 -0700 (PDT) (envelope-from bright@elvis.mu.org) Received: by elvis.mu.org (Postfix, from userid 1192) id 9BF9FAE23A; Mon, 16 Sep 2002 23:13:56 -0700 (PDT) Date: Mon, 16 Sep 2002 23:13:56 -0700 From: Alfred Perlstein To: Daniel Eischen Cc: standards@freebsd.org Subject: Re: sem_* API Message-ID: <20020917061356.GH86737@elvis.mu.org> References: <20020917010939.GE86737@elvis.mu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4i Sender: owner-freebsd-standards@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG * Daniel Eischen [020916 18:32] wrote: > [ switching to -standards if that's OK ] That's fine, but please keep me on the cc list as I'm not subscribed to many lists right now. > On Mon, 16 Sep 2002, Alfred Perlstein wrote: > > > Does it make sense for these to actually be in libc? This is > > because they can be used to inter-process syncronization, not > > just between threads... > > Well, Solaris has them in librt (real-time) and not in libthread > or libpthread. POSIX/Austin/SUSv3 define these to be part of the > real-time extensions also. > > Since our other real-time stuff (sched_*) is in libc, I'd say they > really belong in libc. There is an option for semaphores too > (_POSIX_SEMAPHORES); you probably want to define that if it isn't > already ( I think). > > Can they be implemented as standalone syscalls in libc, and then > wrapped by libc_r? They needn't be wrapped at all in libpthread > unless we want to make them faster for the non-shared case. Ok, so I'm going to put them into src/lib/libc/sys/sem.c. :) Question, besideds removing the inclusion of pthread_private.h and axing the __weak_reference's, is any other special handling required? Updated delta here: I've moved uipc_sem.c from kern to posix4/posix4_sem.c and made it optional as well as put the code into libc. http://people.freebsd.org/~alfred/deltas/sem.diff.gz -- -Alfred Perlstein [alfred@freebsd.org] 'Instead of asking why a piece of software is using "1970s technology," start asking why software is ignoring 30 years of accumulated wisdom.' To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-standards" in the body of the message