From owner-freebsd-standards@FreeBSD.ORG Mon Aug 15 11:02:02 2005 Return-Path: X-Original-To: freebsd-standards@freebsd.org 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 DA51216A420 for ; Mon, 15 Aug 2005 11:02:00 +0000 (GMT) (envelope-from owner-bugmaster@freebsd.org) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id A085543D5A for ; Mon, 15 Aug 2005 11:02:00 +0000 (GMT) (envelope-from owner-bugmaster@freebsd.org) Received: from freefall.freebsd.org (peter@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.3/8.13.3) with ESMTP id j7FB20uR007658 for ; Mon, 15 Aug 2005 11:02:00 GMT (envelope-from owner-bugmaster@freebsd.org) Received: (from peter@localhost) by freefall.freebsd.org (8.13.3/8.13.1/Submit) id j7FB1xde007648 for freebsd-standards@freebsd.org; Mon, 15 Aug 2005 11:01:59 GMT (envelope-from owner-bugmaster@freebsd.org) Date: Mon, 15 Aug 2005 11:01:59 GMT Message-Id: <200508151101.j7FB1xde007648@freefall.freebsd.org> X-Authentication-Warning: freefall.freebsd.org: peter set sender to owner-bugmaster@freebsd.org using -f From: FreeBSD bugmaster To: freebsd-standards@FreeBSD.org Cc: Subject: Current problem reports assigned to you X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 15 Aug 2005 11:02:02 -0000 Current FreeBSD problem reports Critical problems Serious problems S Submitted Tracker Resp. Description ------------------------------------------------------------------------------- o [2001/03/05] bin/25542 standards /bin/sh: null char in quoted string o [2002/12/13] kern/46239 standards posix semaphore implementation errors o [2003/04/21] standards/51209standards [PATCH] add a64l()/l64a/l64a_r functions o [2003/07/12] standards/54410standards one-true-awk not POSIX compliant (no exte o [2004/11/03] standards/73500standards 'set +o' in /bin/sh does not include unse o [2005/03/03] standards/78357standards getaddrinfo() doesn't appear to support A o [2005/06/25] standards/82654standards C99 long double math functions are missin o [2005/08/04] standards/84539standards [ patch ] add support of -V and -v args f 8 problems total. Non-critical problems S Submitted Tracker Resp. Description ------------------------------------------------------------------------------- o [2000/09/24] bin/21519 standards sys/dir.h should be deprecated some more o [2001/01/16] bin/24390 standards Replacing old dir-symlinks when using /bi s [2001/01/24] standards/24590standards timezone function not compatible witn Sin s [2001/06/18] kern/28260 standards UIO_MAXIOV needs to be made public p [2001/11/20] standards/32126standards getopt(3) not Unix-98 conformant s [2002/03/19] standards/36076standards Implementation of POSIX fuser command o [2002/06/14] standards/39256standards [v]snprintf aren't POSIX-conformant for s o [2002/07/09] kern/40378 standards stdlib.h gives needless warnings with -an p [2002/08/12] standards/41576standards POSIX compliance of ln(1) o [2002/10/23] standards/44425standards getcwd() succeeds even if current dir has o [2002/12/09] standards/46119standards Priority problems for SCHED_OTHER using p o [2003/07/24] standards/54809standards pcvt deficits o [2003/07/25] standards/54833standards more pcvt deficits o [2003/07/25] standards/54839standards pcvt deficits o [2003/07/31] standards/55112standards glob.h, glob_t's gl_pathc should be "size o [2003/09/05] standards/56476standards cd9660 unicode support simple hack o [2003/10/29] standards/58676standards grantpt(3) alters storage used by ptsname s [2004/02/14] standards/62858standards malloc(0) not C99 compliant p [2004/02/21] standards/63173standards Patch to add getopt_long_only(3) to libc o [2004/03/29] kern/64875 standards [patch] add a system call: fdatasync() o [2004/05/07] standards/66357standards make POSIX conformance problem ('sh -e' & o [2004/05/11] standards/66531standards _gettemp uses a far smaller set of filena o [2004/08/22] standards/70813standards [PATCH] ls not Posix compliant o [2004/08/26] docs/70985 standards [patch] sh(1): incomplete documentation o o [2004/09/22] standards/72006standards floating point formating in non-C locales o [2005/03/20] standards/79055standards Add an IFS regression test for shells o [2005/03/20] standards/79056standards regex(3) regression tests o [2005/03/21] standards/79067standards /bin/sh should be more intelligent about o [2005/05/20] standards/81287standards [PATCH]: fingerd(8) might send a line not o [2005/07/21] standards/83845standards [ patch ] add log2() and log2f() support o [2005/07/22] standards/83919standards ls man page "sort by size" example out no 31 problems total. From owner-freebsd-standards@FreeBSD.ORG Mon Aug 15 13:41:19 2005 Return-Path: X-Original-To: freebsd-standards@hub.freebsd.org Delivered-To: freebsd-standards@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id EA5B716A41F; Mon, 15 Aug 2005 13:41:19 +0000 (GMT) (envelope-from stefanf@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9C61343D48; Mon, 15 Aug 2005 13:41:19 +0000 (GMT) (envelope-from stefanf@FreeBSD.org) Received: from freefall.freebsd.org (stefanf@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.3/8.13.3) with ESMTP id j7FDfJGa031353; Mon, 15 Aug 2005 13:41:19 GMT (envelope-from stefanf@freefall.freebsd.org) Received: (from stefanf@localhost) by freefall.freebsd.org (8.13.3/8.13.1/Submit) id j7FDfJ3V031349; Mon, 15 Aug 2005 13:41:19 GMT (envelope-from stefanf) Date: Mon, 15 Aug 2005 13:41:19 GMT From: Stefan Farfeleder Message-Id: <200508151341.j7FDfJ3V031349@freefall.freebsd.org> To: dim@xs4all.nl, stefanf@FreeBSD.org, freebsd-standards@FreeBSD.org Cc: Subject: Re: kern/40378: stdlib.h gives needless warnings with -ansi X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 15 Aug 2005 13:41:20 -0000 Synopsis: stdlib.h gives needless warnings with -ansi State-Changed-From-To: open->closed State-Changed-By: stefanf State-Changed-When: Mon Aug 15 13:40:34 GMT 2005 State-Changed-Why: Fixed in stdlib.h's revision 1.16.2.5. http://www.freebsd.org/cgi/query-pr.cgi?pr=40378 From owner-freebsd-standards@FreeBSD.ORG Fri Aug 19 09:37:02 2005 Return-Path: X-Original-To: standards@FreeBSD.org 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 2F44116A41F for ; Fri, 19 Aug 2005 09:37:02 +0000 (GMT) (envelope-from stefan@fafoe.narf.at) Received: from viefep19-int.chello.at (viefep11-int.chello.at [213.46.255.27]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4237943D49 for ; Fri, 19 Aug 2005 09:37:00 +0000 (GMT) (envelope-from stefan@fafoe.narf.at) Received: from wombat.fafoe.narf.at ([213.47.85.26]) by viefep19-int.chello.at (InterMail vM.6.01.04.04 201-2131-118-104-20050224) with ESMTP id <20050819093659.TQGV4473.viefep19-int.chello.at@wombat.fafoe.narf.at> for ; Fri, 19 Aug 2005 11:36:59 +0200 Received: by wombat.fafoe.narf.at (Postfix, from userid 1001) id 2C2AAF6; Fri, 19 Aug 2005 11:36:54 +0200 (CEST) Date: Fri, 19 Aug 2005 11:36:54 +0200 From: Stefan Farfeleder To: standards@FreeBSD.org Message-ID: <20050819093649.GU21905@wombat.fafoe.narf.at> Mail-Followup-To: standards@FreeBSD.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.9i Cc: Subject: includes X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Aug 2005 09:37:02 -0000 Hi, I think some of the headers included by violate the POSIX specification (I'm looking at SUSv3/POSIX 1003.1 2004) by making more symbols visible than allowed. Ok Ok Ok No? (POSIX allows which is a subset) No? No? Ok Is this correct? Should it be fixed? Stefan From owner-freebsd-standards@FreeBSD.ORG Fri Aug 19 13:23:30 2005 Return-Path: X-Original-To: freebsd-standards@hub.freebsd.org Delivered-To: freebsd-standards@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D09DF16A41F; Fri, 19 Aug 2005 13:23:30 +0000 (GMT) (envelope-from vs@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7F79443D6B; Fri, 19 Aug 2005 13:23:27 +0000 (GMT) (envelope-from vs@FreeBSD.org) Received: from freefall.freebsd.org (vs@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.3/8.13.3) with ESMTP id j7JDNR9j099910; Fri, 19 Aug 2005 13:23:27 GMT (envelope-from vs@freefall.freebsd.org) Received: (from vs@localhost) by freefall.freebsd.org (8.13.3/8.13.1/Submit) id j7JDNRik099906; Fri, 19 Aug 2005 13:23:27 GMT (envelope-from vs) Date: Fri, 19 Aug 2005 13:23:27 GMT From: Volker Stolz Message-Id: <200508191323.j7JDNRik099906@freefall.freebsd.org> To: vs@FreeBSD.org, freebsd-i386@FreeBSD.org, freebsd-standards@FreeBSD.org Cc: Subject: Re: i386/85080: output of long double subnormals (with printf) is wrong by a factor 2 X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Aug 2005 13:23:31 -0000 Synopsis: output of long double subnormals (with printf) is wrong by a factor 2 Responsible-Changed-From-To: freebsd-i386->freebsd-standards Responsible-Changed-By: vs Responsible-Changed-When: Fri Aug 19 13:22:48 GMT 2005 Responsible-Changed-Why: Over to -standards for perusal http://www.freebsd.org/cgi/query-pr.cgi?pr=85080 From owner-freebsd-standards@FreeBSD.ORG Fri Aug 19 14:05:02 2005 Return-Path: X-Original-To: standards@FreeBSD.org 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 433EC16A41F; Fri, 19 Aug 2005 14:05:02 +0000 (GMT) (envelope-from bde@zeta.org.au) Received: from mailout1.pacific.net.au (mailout1.pacific.net.au [61.8.0.84]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3E9AA43D55; Fri, 19 Aug 2005 14:05:00 +0000 (GMT) (envelope-from bde@zeta.org.au) Received: from mailproxy1.pacific.net.au (mailproxy1.pacific.net.au [61.8.0.86]) by mailout1.pacific.net.au (8.13.4/8.13.4/Debian-3) with ESMTP id j7JE4w2v013653; Sat, 20 Aug 2005 00:04:58 +1000 Received: from epsplex.bde.org (katana.zip.com.au [61.8.7.246]) by mailproxy1.pacific.net.au (8.13.4/8.13.4/Debian-3) with ESMTP id j7JE4u8W013507; Sat, 20 Aug 2005 00:04:57 +1000 Date: Sat, 20 Aug 2005 00:04:56 +1000 (EST) From: Bruce Evans X-X-Sender: bde@epsplex.bde.org To: Stefan Farfeleder In-Reply-To: <20050819093649.GU21905@wombat.fafoe.narf.at> Message-ID: <20050819231640.E2640@epsplex.bde.org> References: <20050819093649.GU21905@wombat.fafoe.narf.at> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: standards@FreeBSD.org Subject: Re: includes X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Aug 2005 14:05:02 -0000 On Fri, 19 Aug 2005, Stefan Farfeleder wrote: > I think some of the headers included by violate the POSIX > specification (I'm looking at SUSv3/POSIX 1003.1 2004) by making more > symbols visible than allowed. > > Ok > Ok > Ok > No? (POSIX allows which is a subset) > No? > No? > Ok > > Is this correct? Should it be fixed? All of these includes except and are wrong IMO: needed, but can be obtained as a side effect of including almost any other header in the list. only used to declare size_t. We handle this better in many other headers. The old draft of POSIX that I'm looking at doesn't say that declares size_t, so it might be conformant to use __size_t in the prototypes. Ok only used to declare sigset_t and struct timespec. We have a whole header, , to help declare sigset_t better (it only declares __sigset_t), and use it in many other headers. We have 2 headers, and , just to declare struct timespec, and use them in many other headers. Here we only need a forward declaration of struct timespec or maybe struct __timespec, modulo POSIX bugs. It is a bug in POSIX that is allowed. The old draft of POSIX doesn't say that declares sigset_t or struct timespec (just that it may declare the latter). This is unlike what it says for other headers. E.g., we use in to satisfy the POSIX mistake that a complete struct timespec must be declared there. Just namespace pollution. Just namespace pollution. only used to declare struct sched_param and to satisfy a POSIX mistake. A forward declaration would suffice. POSIX should say that size_t, sigset_t and struct timespec are completely declared, and then it would say that [low quality] implementations may declare everything else in the primary headers that declare these. Bruce From owner-freebsd-standards@FreeBSD.ORG Fri Aug 19 18:35:14 2005 Return-Path: X-Original-To: standards@FreeBSD.org 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 702D316A41F; Fri, 19 Aug 2005 18:35:14 +0000 (GMT) (envelope-from stefan@fafoe.narf.at) Received: from viefep18-int.chello.at (viefep18-int.chello.at [213.46.255.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 554D543D45; Fri, 19 Aug 2005 18:35:13 +0000 (GMT) (envelope-from stefan@fafoe.narf.at) Received: from wombat.fafoe.narf.at ([213.47.85.26]) by viefep18-int.chello.at (InterMail vM.6.01.04.04 201-2131-118-104-20050224) with ESMTP id <20050819183511.CWWY17761.viefep18-int.chello.at@wombat.fafoe.narf.at>; Fri, 19 Aug 2005 20:35:11 +0200 Received: by wombat.fafoe.narf.at (Postfix, from userid 1001) id 65811F6; Fri, 19 Aug 2005 20:35:10 +0200 (CEST) Date: Fri, 19 Aug 2005 20:35:10 +0200 From: Stefan Farfeleder To: Bruce Evans Message-ID: <20050819183507.GE77069@wombat.fafoe.narf.at> Mail-Followup-To: Bruce Evans , standards@FreeBSD.org, threads@FreeBSD.org References: <20050819093649.GU21905@wombat.fafoe.narf.at> <20050819231640.E2640@epsplex.bde.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20050819231640.E2640@epsplex.bde.org> User-Agent: Mutt/1.5.9i Cc: threads@FreeBSD.org, standards@FreeBSD.org Subject: Re: includes X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Aug 2005 18:35:14 -0000 [threads@ added] On Sat, Aug 20, 2005 at 12:04:56AM +1000, Bruce Evans wrote: > On Fri, 19 Aug 2005, Stefan Farfeleder wrote: > > >I think some of the headers included by violate the POSIX > >specification (I'm looking at SUSv3/POSIX 1003.1 2004) by making more > >symbols visible than allowed. > > > > Ok > > Ok > > Ok > > No? (POSIX allows which is a subset) ^^^^^^ Actually POSIX kind of requires the inclusion of (and ). At least all symbols must be visible. > > No? > > No? > > Ok > > > >Is this correct? Should it be fixed? > > All of these includes except and are > wrong IMO: > > needed, but can be obtained as a side effect > of including almost any other header in the list. > only used to declare size_t. We handle this better > in many other headers. The old draft of POSIX that > I'm looking at doesn't say that declares > size_t, so it might be conformant to use __size_t > in the prototypes. Removed, size_t is obtained via . > Ok > only used to declare sigset_t and struct timespec. > We have a whole header, , to help > declare sigset_t better (it only declares > __sigset_t), > and use it in many other headers. We have 2 headers, > and , just to > declare struct timespec, and use them in many other > headers. Here we only need a forward declaration of > struct timespec or maybe struct __timespec, modulo > POSIX bugs. It is a bug in POSIX that is > allowed. The old draft of POSIX doesn't say that > declares sigset_t or struct timespec > (just that it may declare the latter). This is > unlike what it says for other headers. E.g., we > use in to satisfy > the POSIX mistake that a complete struct timespec > must be declared there. I've include (for __uint32_t) and instead. timespec is declared through . > Just namespace pollution. We need MINSIGSTKSZ from though. The patch includes that header instead and protects its usage with __XSI_VISIBLE. I'm not happy with this, maybe MINSIGSTKSZ should be moved somewhere else? > Just namespace pollution. is included instead and __ULONG_MAX is used. > only used to declare struct sched_param and to > satisfy a POSIX mistake. A forward declaration > would suffice. Left because POSIX says so. The patch for is at http://people.freebsd.org/~stefanf/pthread.h.diff . There are a few files that need , , etc symbols and get them by inclusion, the patch at http://people.freebsd.org/~stefanf/pthread.h-2.diff fixes that. It should probably be committed anyway. Stefan From owner-freebsd-standards@FreeBSD.ORG Fri Aug 19 19:33:39 2005 Return-Path: X-Original-To: standards@FreeBSD.org 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 EB01616A46F; Fri, 19 Aug 2005 19:33:39 +0000 (GMT) (envelope-from stefan@fafoe.narf.at) Received: from viefep13-int.chello.at (viefep13-int.chello.at [213.46.255.15]) by mx1.FreeBSD.org (Postfix) with ESMTP id C872143D46; Fri, 19 Aug 2005 19:33:38 +0000 (GMT) (envelope-from stefan@fafoe.narf.at) Received: from wombat.fafoe.narf.at ([213.47.85.26]) by viefep13-int.chello.at (InterMail vM.6.01.04.04 201-2131-118-104-20050224) with ESMTP id <20050819193336.JDT26435.viefep13-int.chello.at@wombat.fafoe.narf.at>; Fri, 19 Aug 2005 21:33:36 +0200 Received: by wombat.fafoe.narf.at (Postfix, from userid 1001) id 716CC2FF; Fri, 19 Aug 2005 21:33:35 +0200 (CEST) Date: Fri, 19 Aug 2005 21:33:35 +0200 From: Stefan Farfeleder To: standards@FreeBSD.org, threads@FreeBSD.org Message-ID: <20050819193333.GF77069@wombat.fafoe.narf.at> Mail-Followup-To: standards@FreeBSD.org, threads@FreeBSD.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="VS++wcV0S1rZb1Fb" Content-Disposition: inline User-Agent: Mutt/1.5.9i Cc: Subject: /2 X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Aug 2005 19:33:40 -0000 --VS++wcV0S1rZb1Fb Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Hi, any objections to this patch? It moves the identifiers starting with MUTEX_ into the BSD namespace. Stefan --VS++wcV0S1rZb1Fb Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="pthread.h-3.diff" Index: src/include/pthread.h =================================================================== RCS file: /b/ncvs/src/include/pthread.h,v retrieving revision 1.37 diff -u -r1.37 pthread.h --- src/include/pthread.h 19 Aug 2005 08:37:16 -0000 1.37 +++ src/include/pthread.h 19 Aug 2005 19:23:37 -0000 @@ -130,12 +133,15 @@ PTHREAD_MUTEX_ERRORCHECK = 1, /* Default POSIX mutex */ PTHREAD_MUTEX_RECURSIVE = 2, /* Recursive mutex */ PTHREAD_MUTEX_NORMAL = 3, /* No error checking */ - MUTEX_TYPE_MAX + PTHREAD_MUTEX_TYPE_MAX }; #define PTHREAD_MUTEX_DEFAULT PTHREAD_MUTEX_ERRORCHECK +#if __BSD_VISIBLE #define MUTEX_TYPE_FAST PTHREAD_MUTEX_NORMAL #define MUTEX_TYPE_COUNTING_FAST PTHREAD_MUTEX_RECURSIVE +#define MUTEX_TYPE_MAX PTHREAD_MUTEX_TYPE_MAX +#endif /* * Thread function prototype definitions: --VS++wcV0S1rZb1Fb-- From owner-freebsd-standards@FreeBSD.ORG Fri Aug 19 19:42:36 2005 Return-Path: X-Original-To: standards@freebsd.org 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 32EA616A41F; Fri, 19 Aug 2005 19:42:36 +0000 (GMT) (envelope-from deischen@freebsd.org) Received: from mail.ntplx.net (mail.ntplx.net [204.213.176.10]) by mx1.FreeBSD.org (Postfix) with ESMTP id B45C243D48; Fri, 19 Aug 2005 19:42:35 +0000 (GMT) (envelope-from deischen@freebsd.org) Received: from sea.ntplx.net (sea.ntplx.net [204.213.176.11]) by mail.ntplx.net (8.13.4/8.13.4/NETPLEX) with ESMTP id j7JJgYti001772; Fri, 19 Aug 2005 15:42:34 -0400 (EDT) Date: Fri, 19 Aug 2005 15:42:34 -0400 (EDT) From: Daniel Eischen X-X-Sender: eischen@sea.ntplx.net To: Stefan Farfeleder In-Reply-To: <20050819193333.GF77069@wombat.fafoe.narf.at> Message-ID: MIME-Version: 1.0 Content-Type: MULTIPART/Mixed; BOUNDARY=VS++wcV0S1rZb1Fb Content-ID: Content-Disposition: INLINE X-Virus-Scanned: by AMaViS and Clam AntiVirus (mail.ntplx.net) Cc: threads@freebsd.org, standards@freebsd.org Subject: Re: /2 X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Daniel Eischen List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Aug 2005 19:42:36 -0000 This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable without MIME-aware tools. Send mail to mime@docserver.cac.washington.edu for more info. --VS++wcV0S1rZb1Fb Content-Type: TEXT/PLAIN; CHARSET=US-ASCII Content-ID: Content-Disposition: INLINE On Fri, 19 Aug 2005, Stefan Farfeleder wrote: > Hi, > > any objections to this patch? It moves the identifiers starting with > MUTEX_ into the BSD namespace. Looks fine to me. I don't even think we should have MUTEX_* around anyways. -- Dan --VS++wcV0S1rZb1Fb Content-Type: TEXT/PLAIN; CHARSET=us-ascii Content-ID: Content-Description: Content-Disposition: ATTACHMENT; FILENAME="pthread.h-3.diff" Index: src/include/pthread.h =================================================================== RCS file: /b/ncvs/src/include/pthread.h,v retrieving revision 1.37 diff -u -r1.37 pthread.h --- src/include/pthread.h 19 Aug 2005 08:37:16 -0000 1.37 +++ src/include/pthread.h 19 Aug 2005 19:23:37 -0000 @@ -130,12 +133,15 @@ PTHREAD_MUTEX_ERRORCHECK = 1, /* Default POSIX mutex */ PTHREAD_MUTEX_RECURSIVE = 2, /* Recursive mutex */ PTHREAD_MUTEX_NORMAL = 3, /* No error checking */ - MUTEX_TYPE_MAX + PTHREAD_MUTEX_TYPE_MAX }; #define PTHREAD_MUTEX_DEFAULT PTHREAD_MUTEX_ERRORCHECK +#if __BSD_VISIBLE #define MUTEX_TYPE_FAST PTHREAD_MUTEX_NORMAL #define MUTEX_TYPE_COUNTING_FAST PTHREAD_MUTEX_RECURSIVE +#define MUTEX_TYPE_MAX PTHREAD_MUTEX_TYPE_MAX +#endif /* * Thread function prototype definitions: --VS++wcV0S1rZb1Fb Content-Type: TEXT/PLAIN; CHARSET=us-ascii Content-ID: Content-Description: Content-Disposition: INLINE _______________________________________________ freebsd-threads@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-threads To unsubscribe, send any mail to "freebsd-threads-unsubscribe@freebsd.org" --VS++wcV0S1rZb1Fb-- From owner-freebsd-standards@FreeBSD.ORG Fri Aug 19 20:38:19 2005 Return-Path: X-Original-To: standards@freebsd.org 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 0C0BC16A41F; Fri, 19 Aug 2005 20:38:19 +0000 (GMT) (envelope-from stefan@fafoe.narf.at) Received: from viefep18-int.chello.at (viefep18-int.chello.at [213.46.255.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id C4EBC43D49; Fri, 19 Aug 2005 20:38:17 +0000 (GMT) (envelope-from stefan@fafoe.narf.at) Received: from wombat.fafoe.narf.at ([213.47.85.26]) by viefep18-int.chello.at (InterMail vM.6.01.04.04 201-2131-118-104-20050224) with ESMTP id <20050819203815.FSIM17761.viefep18-int.chello.at@wombat.fafoe.narf.at>; Fri, 19 Aug 2005 22:38:15 +0200 Received: by wombat.fafoe.narf.at (Postfix, from userid 1001) id 092432FF; Fri, 19 Aug 2005 22:38:14 +0200 (CEST) Date: Fri, 19 Aug 2005 22:38:14 +0200 From: Stefan Farfeleder To: Daniel Eischen Message-ID: <20050819203807.GG77069@wombat.fafoe.narf.at> Mail-Followup-To: Daniel Eischen , threads@freebsd.org, standards@freebsd.org References: <20050819193333.GF77069@wombat.fafoe.narf.at> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.9i Cc: threads@freebsd.org, standards@freebsd.org Subject: Re: /2 X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Aug 2005 20:38:19 -0000 On Fri, Aug 19, 2005 at 03:42:34PM -0400, Daniel Eischen wrote: > On Fri, 19 Aug 2005, Stefan Farfeleder wrote: > > > any objections to this patch? It moves the identifiers starting with > > MUTEX_ into the BSD namespace. > > Looks fine to me. I don't even think we should have MUTEX_* > around anyways. But we had those names for quite a while and maybe there are applications using them, that's why I provided the compatibility macros. Stefan From owner-freebsd-standards@FreeBSD.ORG Fri Aug 19 21:12:50 2005 Return-Path: X-Original-To: standards@freebsd.org 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 CAA1416A420; Fri, 19 Aug 2005 21:12:50 +0000 (GMT) (envelope-from deischen@freebsd.org) Received: from mail.ntplx.net (mail.ntplx.net [204.213.176.10]) by mx1.FreeBSD.org (Postfix) with ESMTP id B86CC43D46; Fri, 19 Aug 2005 21:12:49 +0000 (GMT) (envelope-from deischen@freebsd.org) Received: from sea.ntplx.net (sea.ntplx.net [204.213.176.11]) by mail.ntplx.net (8.13.4/8.13.4/NETPLEX) with ESMTP id j7JLCmuB025327; Fri, 19 Aug 2005 17:12:48 -0400 (EDT) Date: Fri, 19 Aug 2005 17:12:48 -0400 (EDT) From: Daniel Eischen X-X-Sender: eischen@sea.ntplx.net To: Stefan Farfeleder In-Reply-To: <20050819203807.GG77069@wombat.fafoe.narf.at> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Virus-Scanned: by AMaViS and Clam AntiVirus (mail.ntplx.net) Cc: threads@freebsd.org, standards@freebsd.org Subject: Re: /2 X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Daniel Eischen List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Aug 2005 21:12:51 -0000 On Fri, 19 Aug 2005, Stefan Farfeleder wrote: > On Fri, Aug 19, 2005 at 03:42:34PM -0400, Daniel Eischen wrote: > > On Fri, 19 Aug 2005, Stefan Farfeleder wrote: > > > > > any objections to this patch? It moves the identifiers starting with > > > MUTEX_ into the BSD namespace. > > > > Looks fine to me. I don't even think we should have MUTEX_* > > around anyways. > > But we had those names for quite a while and maybe there are > applications using them, that's why I provided the compatibility macros. Yes, but you wouldn't break ABI by removing them (I'd advocate doing this in -current). -- DE From owner-freebsd-standards@FreeBSD.ORG Fri Aug 19 21:32:51 2005 Return-Path: X-Original-To: standards@freebsd.org 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 338D516A41F; Fri, 19 Aug 2005 21:32:51 +0000 (GMT) (envelope-from stefan@fafoe.narf.at) Received: from viefep17-int.chello.at (viefep17-int.chello.at [213.46.255.23]) by mx1.FreeBSD.org (Postfix) with ESMTP id D98A543D46; Fri, 19 Aug 2005 21:32:49 +0000 (GMT) (envelope-from stefan@fafoe.narf.at) Received: from wombat.fafoe.narf.at ([213.47.85.26]) by viefep17-int.chello.at (InterMail vM.6.01.04.04 201-2131-118-104-20050224) with ESMTP id <20050819213248.ENNH1234.viefep17-int.chello.at@wombat.fafoe.narf.at>; Fri, 19 Aug 2005 23:32:48 +0200 Received: by wombat.fafoe.narf.at (Postfix, from userid 1001) id A06732FF; Fri, 19 Aug 2005 23:32:46 +0200 (CEST) Date: Fri, 19 Aug 2005 23:32:46 +0200 From: Stefan Farfeleder To: Daniel Eischen Message-ID: <20050819213244.GH77069@wombat.fafoe.narf.at> Mail-Followup-To: Daniel Eischen , threads@freebsd.org, standards@freebsd.org References: <20050819203807.GG77069@wombat.fafoe.narf.at> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.9i Cc: threads@freebsd.org, standards@freebsd.org Subject: Re: /2 X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Aug 2005 21:32:51 -0000 On Fri, Aug 19, 2005 at 05:12:48PM -0400, Daniel Eischen wrote: > On Fri, 19 Aug 2005, Stefan Farfeleder wrote: > > > On Fri, Aug 19, 2005 at 03:42:34PM -0400, Daniel Eischen wrote: > > > On Fri, 19 Aug 2005, Stefan Farfeleder wrote: > > > > > > > any objections to this patch? It moves the identifiers starting with > > > > MUTEX_ into the BSD namespace. > > > > > > Looks fine to me. I don't even think we should have MUTEX_* > > > around anyways. > > > > But we had those names for quite a while and maybe there are > > applications using them, that's why I provided the compatibility macros. > > Yes, but you wouldn't break ABI by removing them (I'd advocate > doing this in -current). Okay, gone it is ;) From owner-freebsd-standards@FreeBSD.ORG Fri Aug 19 23:42:55 2005 Return-Path: X-Original-To: standards@freebsd.org 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 F079816A420 for ; Fri, 19 Aug 2005 23:42:54 +0000 (GMT) (envelope-from mi+mx@aldan.algebra.com) Received: from mail24.sea5.speakeasy.net (mail24.sea5.speakeasy.net [69.17.117.26]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9BF1843D64 for ; Fri, 19 Aug 2005 23:42:47 +0000 (GMT) (envelope-from mi+mx@aldan.algebra.com) Received: (qmail 21611 invoked from network); 19 Aug 2005 23:42:47 -0000 Received: from aldan.algebra.com ([216.254.65.224]) (envelope-sender ) by mail24.sea5.speakeasy.net (qmail-ldap-1.03) with AES256-SHA encrypted SMTP for ; 19 Aug 2005 23:42:46 -0000 Received: from corbulon.video-collage.com (static-151-204-231-237.bos.east.verizon.net [151.204.231.237]) by aldan.algebra.com (8.13.1/8.13.1) with ESMTP id j7JNgi5r018750 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Fri, 19 Aug 2005 19:42:45 -0400 (EDT) (envelope-from mi+mx@aldan.algebra.com) Received: from mteterin.us.murex.com (195-11.customer.cloud9.net [168.100.195.11]) by corbulon.video-collage.com (8.13.4/8.13.1) with ESMTP id j7JNgYA4005679 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 19 Aug 2005 19:42:37 -0400 (EDT) (envelope-from mi+mx@aldan.algebra.com) Received: from mteterin.us.murex.com (mteterin@localhost [127.0.0.1]) by mteterin.us.murex.com (8.13.3/8.13.3) with ESMTP id j7JNgSiO013559; Fri, 19 Aug 2005 19:42:28 -0400 (EDT) (envelope-from mi+mx@aldan.algebra.com) Received: from localhost (localhost [[UNIX: localhost]]) by mteterin.us.murex.com (8.13.3/8.13.3/Submit) id j7JNgQl1013558; Fri, 19 Aug 2005 19:42:26 -0400 (EDT) (envelope-from mi+mx@aldan.algebra.com) X-Authentication-Warning: mteterin.us.murex.com: mteterin set sender to mi+mx@aldan.algebra.com using -f From: Mikhail Teterin Organization: Virtual Estates, Inc. To: questions@freebsd.org Date: Fri, 19 Aug 2005 19:42:26 -0400 User-Agent: KMail/1.8.2 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200508191942.26723.mi+mx@aldan.algebra.com> X-Virus-Scanned: ClamAV devel-20050525/1034/Thu Aug 18 16:07:58 2005 on corbulon.video-collage.com X-Virus-Status: Clean X-Scanned-By: MIMEDefang 2.43 Cc: standards@freebsd.org Subject: very big files on cd9660 file system X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Aug 2005 23:42:55 -0000 Hello! I have a cd9660 image with several files on it. One of the files is very large (above 4Gb). When I mount the image, the size of this file is shown as realsize % 4Gb -- 758876749 bytes instead of 5053844045. What should I blame: 1) The software, that created the image (modified mkisofs) 2) cd9660 part of the FreeBSD kernel 3) ISO-9660 standard Thank you! -mi From owner-freebsd-standards@FreeBSD.ORG Sat Aug 20 05:10:12 2005 Return-Path: X-Original-To: standards@FreeBSD.org 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 2151216A41F; Sat, 20 Aug 2005 05:10:12 +0000 (GMT) (envelope-from bde@zeta.org.au) Received: from mailout1.pacific.net.au (mailout1.pacific.net.au [61.8.0.84]) by mx1.FreeBSD.org (Postfix) with ESMTP id 857AC43D45; Sat, 20 Aug 2005 05:10:11 +0000 (GMT) (envelope-from bde@zeta.org.au) Received: from mailproxy2.pacific.net.au (mailproxy2.pacific.net.au [61.8.0.87]) by mailout1.pacific.net.au (8.13.4/8.13.4/Debian-3) with ESMTP id j7K59nMd024625; Sat, 20 Aug 2005 15:09:49 +1000 Received: from katana.zip.com.au (katana.zip.com.au [61.8.7.246]) by mailproxy2.pacific.net.au (8.13.4/8.13.4/Debian-3) with ESMTP id j7K59kUx016007; Sat, 20 Aug 2005 15:09:47 +1000 Date: Sat, 20 Aug 2005 15:09:46 +1000 (EST) From: Bruce Evans X-X-Sender: bde@delplex.bde.org To: Mikhail Teterin In-Reply-To: <200508191942.26723.mi+mx@aldan.algebra.com> Message-ID: <20050820142802.E60211@delplex.bde.org> References: <200508191942.26723.mi+mx@aldan.algebra.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: standards@FreeBSD.org, questions@FreeBSD.org Subject: Re: very big files on cd9660 file system X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 20 Aug 2005 05:10:12 -0000 On Fri, 19 Aug 2005, Mikhail Teterin wrote: > I have a cd9660 image with several files on it. One of the files is very large > (above 4Gb). When I mount the image, the size of this file is shown as > realsize % 4Gb -- 758876749 bytes instead of 5053844045. > > What should I blame: > > 1) The software, that created the image (modified mkisofs) > 2) cd9660 part of the FreeBSD kernel > 3) ISO-9660 standard Mostly (b). Sizes are 64 bits in the standard, but FreeBSD has always silently discarded the highest 32 bits and corrupted the next highest bit to a sign bit, so the file size limit is at most 2GB or 4GB (depending on whether the sign bit gets corrupted back to a value bit). >From cd9660_vfsops.c: % ip->i_size = isonum_733(isodir->size); This reads the size from the directory entry. >From iso.h: % u_char size [ISODCL (11, 18)]; /* 733 */ This says that the size is in bytes 11-18 (option base 1) in the directory entry. All "733" entries are 8 bytes. The others are for other sizes and the extent (the starting block number for a file). % static __inline int % isonum_733(p) % u_char *p; % { % return *p|(p[1] << 8)|(p[2] << 16)|(p[3] << 24); % } This says that the the highest 32 bits are discarded for all "733" entries and the sign bit in p[3] is corrupted, first by shifting it and then by assigning the result to an int. i_size has type long, unlike in most file systems in FreeBSD where it is uint64_t or uint32_t, so I think the sign bit stays corrupted but doesn't cause further problems by being converted to 33 top unsigned bits, giving a limit of 2GB. The file size limit is hit before the others. 31-bit block numbers with 2K-blocks work up to 4TB. There are likely to be overflow bugs at 1TB before the 4TB limit is hit. We still have the even closer limit of 4GB on media sizes. From cd9660_node.c: % ino_t % isodirino(isodir, imp) % struct iso_directory_record *isodir; % struct iso_mnt *imp; % { % ino_t ino; % % ino = (isonum_733(isodir->extent) + isonum_711(isodir->ext_attr_length)) % << imp->im_bshift; % return (ino); % } This fakes the inode number as the byte offset of the directory entry. ino_t is uint32_t, so this fails if the byte offset exceeds 4GB. The eventual 32nd bit overflows to become a sign bit in the shift but then gets overflows back to a correct bit in the assignent, so offsets between 2GB and 4GB work accidentally. Since the limit is on the offsets of directory entries, media larger than 4GB can be used for cd9660 under FreeBSD iff all directroy entries are below the limit, which happens automatically for the non-multi-session case only. See revs.1.77 and 1.99 for other bugs caused by isodirino(). Bruce From owner-freebsd-standards@FreeBSD.ORG Sat Aug 20 05:48:35 2005 Return-Path: X-Original-To: standards@FreeBSD.org 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 7A4C016A41F; Sat, 20 Aug 2005 05:48:35 +0000 (GMT) (envelope-from bde@zeta.org.au) Received: from mailout1.pacific.net.au (mailout1.pacific.net.au [61.8.0.84]) by mx1.FreeBSD.org (Postfix) with ESMTP id D35A843D45; Sat, 20 Aug 2005 05:48:34 +0000 (GMT) (envelope-from bde@zeta.org.au) Received: from mailproxy1.pacific.net.au (mailproxy1.pacific.net.au [61.8.0.86]) by mailout1.pacific.net.au (8.13.4/8.13.4/Debian-3) with ESMTP id j7K5mXJT030470; Sat, 20 Aug 2005 15:48:33 +1000 Received: from katana.zip.com.au (katana.zip.com.au [61.8.7.246]) by mailproxy1.pacific.net.au (8.13.4/8.13.4/Debian-3) with ESMTP id j7K5mV27011478; Sat, 20 Aug 2005 15:48:32 +1000 Date: Sat, 20 Aug 2005 15:48:31 +1000 (EST) From: Bruce Evans X-X-Sender: bde@delplex.bde.org To: Stefan Farfeleder In-Reply-To: <20050819183507.GE77069@wombat.fafoe.narf.at> Message-ID: <20050820151252.L60332@delplex.bde.org> References: <20050819093649.GU21905@wombat.fafoe.narf.at> <20050819231640.E2640@epsplex.bde.org> <20050819183507.GE77069@wombat.fafoe.narf.at> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: threads@FreeBSD.org, standards@FreeBSD.org Subject: Re: includes X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 20 Aug 2005 05:48:35 -0000 On Fri, 19 Aug 2005, Stefan Farfeleder wrote: > On Sat, Aug 20, 2005 at 12:04:56AM +1000, Bruce Evans wrote: >> On Fri, 19 Aug 2005, Stefan Farfeleder wrote: >> >>> I think some of the headers included by violate the POSIX >>> specification (I'm looking at SUSv3/POSIX 1003.1 2004) by making more >>> symbols visible than allowed. >>> >>> Ok >>> Ok >>> Ok >>> No? (POSIX allows which is a subset) > ^^^^^^ > Actually POSIX kind of requires the inclusion of (and > ). At least all symbols must be visible. Urk. This seems to be the place in POSIX where namespace pollution is explictly required. According to an old draft: %%% 10351 Inclusion of the header shall make symbols defined in the headers and 10352 visible. %%% Everywhere else, POSIX permits both broken and non-broken implementations by saying "may make visible". The history of this is interesting: %%% 10408 IEEE PASC Interpretation 1003.1 #86 is applied, allowing the symbols from and 10409 to be made visible when is included. Previously this was an XSI 10410 extension. %%% The weasels who wrote "may" were apparently not present when this was interpreted :-). %%% 10411 IEEE PASC Interpretation 1003.1c #42 is applied, removing the requirement for prototypes for 10412 the pthread_kill ( ) and pthread_sigmask( ) functions. These are required to be in the 10413 header. They are allowed here through the name space rules. %%% sigset_t apparently isn't required here either. >> needed, but can be obtained as a side effect >> of including almost any other header in the list. >> only used to declare size_t. We handle this better >> in many other headers. The old draft of POSIX that >> I'm looking at doesn't say that declares >> size_t, so it might be conformant to use __size_t >> in the prototypes. > > Removed, size_t is obtained via . OK. >> ... >> only used to declare sigset_t and struct timespec. >> We have a whole header, , to help >> declare sigset_t better (it only declares >> __sigset_t), > ... > I've include (for __uint32_t) and > instead. timespec is declared through . Too bad. >> Just namespace pollution. > > We need MINSIGSTKSZ from though. The patch includes > that header instead and protects its usage with __XSI_VISIBLE. I'm not > happy with this, maybe MINSIGSTKSZ should be moved somewhere else? MINSIGSTKSZ is used to define PTHREAD_STACK_MIN. I didn't notice this partly because the old version that I looked at correctly defiens PTHREAD_STACK_MIN as a constant. Everything is wrong here: - POSIX requires PTHREAD_STACK_MIN to be defined (if at all) in but not in . - PTHREAD_STACK_MIN must be defined as a number (if at all even if XSI is no visible. >> Just namespace pollution. > > is included instead and __ULONG_MAX is used. __ULONG_MAX is used to define PTHREAD_THREADS_MAX. POSIX actually requires the latter to be defined (if at all) in only too. I doubt that the limit is actually 2^64-1. Maybe it should be a runtime limit _SC_THREAD* are missing, so apparently no one ever asks for the runtime limits. >> only used to declare struct sched_param and to >> satisfy a POSIX mistake. A forward declaration >> would suffice. > > Left because POSIX says so. Not too bad. > The patch for is at > http://people.freebsd.org/~stefanf/pthread.h.diff . > > There are a few files that need , , etc symbols and > get them by inclusion, the patch at > http://people.freebsd.org/~stefanf/pthread.h-2.diff fixes that. It > should probably be committed anyway. An alarming number. We shouldn't need so many new includes of , Bruce From owner-freebsd-standards@FreeBSD.ORG Sat Aug 20 08:16:56 2005 Return-Path: X-Original-To: standards@FreeBSD.org 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 0A56C16A41F; Sat, 20 Aug 2005 08:16:56 +0000 (GMT) (envelope-from stefan@fafoe.narf.at) Received: from viefep17-int.chello.at (viefep17-int.chello.at [213.46.255.23]) by mx1.FreeBSD.org (Postfix) with ESMTP id DBEC843D45; Sat, 20 Aug 2005 08:16:54 +0000 (GMT) (envelope-from stefan@fafoe.narf.at) Received: from wombat.fafoe.narf.at ([213.47.85.26]) by viefep17-int.chello.at (InterMail vM.6.01.04.04 201-2131-118-104-20050224) with ESMTP id <20050820081652.NMUC1234.viefep17-int.chello.at@wombat.fafoe.narf.at>; Sat, 20 Aug 2005 10:16:52 +0200 Received: by wombat.fafoe.narf.at (Postfix, from userid 1001) id BAF5C2FF; Sat, 20 Aug 2005 10:16:52 +0200 (CEST) Date: Sat, 20 Aug 2005 10:16:52 +0200 From: Stefan Farfeleder To: Bruce Evans Message-ID: <20050820081649.GA85488@wombat.fafoe.narf.at> Mail-Followup-To: Bruce Evans , threads@FreeBSD.org, standards@FreeBSD.org References: <20050819093649.GU21905@wombat.fafoe.narf.at> <20050819231640.E2640@epsplex.bde.org> <20050819183507.GE77069@wombat.fafoe.narf.at> <20050820151252.L60332@delplex.bde.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20050820151252.L60332@delplex.bde.org> User-Agent: Mutt/1.5.9i Cc: threads@FreeBSD.org, standards@FreeBSD.org Subject: Re: includes X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 20 Aug 2005 08:16:56 -0000 On Sat, Aug 20, 2005 at 03:48:31PM +1000, Bruce Evans wrote: > On Fri, 19 Aug 2005, Stefan Farfeleder wrote: > > >On Sat, Aug 20, 2005 at 12:04:56AM +1000, Bruce Evans wrote: > >>On Fri, 19 Aug 2005, Stefan Farfeleder wrote: > >> > >>>I think some of the headers included by violate the POSIX > >>>specification (I'm looking at SUSv3/POSIX 1003.1 2004) by making more > >>>symbols visible than allowed. > >>> > >>> Ok > >>> Ok > >>> Ok > >>> No? (POSIX allows which is a subset) > > ^^^^^^ > >Actually POSIX kind of requires the inclusion of (and > >). At least all symbols must be visible. > > Urk. This seems to be the place in POSIX where namespace pollution is > explictly required. According to an old draft: > > %%% > 10351 Inclusion of the header shall make symbols > defined in the headers and > 10352 visible. > %%% That's what I have here too. [...] > >>... > >> only used to declare sigset_t and struct timespec. > >> We have a whole header, , to help > >> declare sigset_t better (it only declares > >> __sigset_t), > >... > >I've include (for __uint32_t) and > >instead. timespec is declared through . > > Too bad. Do you have a better suggestion? > >> Just namespace pollution. > > > >We need MINSIGSTKSZ from though. The patch includes > >that header instead and protects its usage with __XSI_VISIBLE. I'm not > >happy with this, maybe MINSIGSTKSZ should be moved somewhere else? > > MINSIGSTKSZ is used to define PTHREAD_STACK_MIN. I didn't notice this > partly because the old version that I looked at correctly defiens > PTHREAD_STACK_MIN as a constant. Everything is wrong here: > - POSIX requires PTHREAD_STACK_MIN to be defined (if at all) in > but not in . > - PTHREAD_STACK_MIN must be defined as a number (if at all even if > XSI is no visible. I agree that is missing the PTHREAD_{DESTRUCTOR_ITERATIONS,KEYS_MAX,STACK_MIN,THREADS_MAX} macros. It's not an error for to define them because POSIX reserves pthread_* and PTHREAD_* for this header. I'm not sure why MINSIGSTKSZ (which expands to const * 4 on all architectures) is not a constant. What do you think about putting __MINSIGSTKSZ in ? > >> Just namespace pollution. > > > > is included instead and __ULONG_MAX is used. > > __ULONG_MAX is used to define PTHREAD_THREADS_MAX. POSIX actually requires > the latter to be defined (if at all) in only too. I doubt > that the limit is actually 2^64-1. Maybe it should be a runtime limit > _SC_THREAD* are missing, so apparently no one ever asks for the runtime > limits. Which _SC_THREAD* is missing? Calling sysconf() with _SC_THREAD_THREADS_MAX is buggy because sysconf converts ULONG_MAX to a long. Stefan From owner-freebsd-standards@FreeBSD.ORG Sat Aug 20 10:57:44 2005 Return-Path: X-Original-To: standards@FreeBSD.org 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 181B216A41F; Sat, 20 Aug 2005 10:57:44 +0000 (GMT) (envelope-from bde@zeta.org.au) Received: from mailout1.pacific.net.au (mailout1.pacific.net.au [61.8.0.84]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7A7BF43D48; Sat, 20 Aug 2005 10:57:43 +0000 (GMT) (envelope-from bde@zeta.org.au) Received: from mailproxy1.pacific.net.au (mailproxy1.pacific.net.au [61.8.0.86]) by mailout1.pacific.net.au (8.13.4/8.13.4/Debian-3) with ESMTP id j7KAvfQU015609; Sat, 20 Aug 2005 20:57:41 +1000 Received: from epsplex.bde.org (katana.zip.com.au [61.8.7.246]) by mailproxy1.pacific.net.au (8.13.4/8.13.4/Debian-3) with ESMTP id j7KAvd2k002091; Sat, 20 Aug 2005 20:57:40 +1000 Date: Sat, 20 Aug 2005 20:57:39 +1000 (EST) From: Bruce Evans X-X-Sender: bde@epsplex.bde.org To: Stefan Farfeleder In-Reply-To: <20050820081649.GA85488@wombat.fafoe.narf.at> Message-ID: <20050820204228.T2739@epsplex.bde.org> References: <20050819093649.GU21905@wombat.fafoe.narf.at> <20050819231640.E2640@epsplex.bde.org> <20050819183507.GE77069@wombat.fafoe.narf.at> <20050820151252.L60332@delplex.bde.org> <20050820081649.GA85488@wombat.fafoe.narf.at> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: threads@FreeBSD.org, standards@FreeBSD.org Subject: Re: includes X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 20 Aug 2005 10:57:44 -0000 On Sat, 20 Aug 2005, Stefan Farfeleder wrote: > On Sat, Aug 20, 2005 at 03:48:31PM +1000, Bruce Evans wrote: >> On Fri, 19 Aug 2005, Stefan Farfeleder wrote: >> >>> On Sat, Aug 20, 2005 at 12:04:56AM +1000, Bruce Evans wrote: >>>> only used to declare sigset_t and struct timespec. >>>> We have a whole header, , to help >>>> declare sigset_t better (it only declares >>>> __sigset_t), >>> ... >>> I've include (for __uint32_t) and >>> instead. timespec is declared through . >> >> Too bad. > > Do you have a better suggestion? No. It's too late to change POSIX. >>>> Just namespace pollution. >>> >>> We need MINSIGSTKSZ from though. The patch includes >>> that header instead and protects its usage with __XSI_VISIBLE. I'm not >>> happy with this, maybe MINSIGSTKSZ should be moved somewhere else? >> >> MINSIGSTKSZ is used to define PTHREAD_STACK_MIN. I didn't notice this >> partly because the old version that I looked at correctly defiens >> PTHREAD_STACK_MIN as a constant. Everything is wrong here: >> - POSIX requires PTHREAD_STACK_MIN to be defined (if at all) in >> but not in . >> - PTHREAD_STACK_MIN must be defined as a number (if at all even if >> XSI is no visible. > > I agree that is missing the > PTHREAD_{DESTRUCTOR_ITERATIONS,KEYS_MAX,STACK_MIN,THREADS_MAX} macros. > It's not an error for to define them because POSIX > reserves pthread_* and PTHREAD_* for this header. I's not useful either, since non-broken applications still need to include (or use sysconf()). > I'm not sure why MINSIGSTKSZ (which expands to const * 4 on all > architectures) is not a constant. It's fairly machine-dependent. const * 8 would make more sense on the 64-bit arches but the const is not always the same even with that scaling. > > What do you think about putting __MINSIGSTKSZ in ? OK. >>>> Just namespace pollution. >>> >>> is included instead and __ULONG_MAX is used. >> >> __ULONG_MAX is used to define PTHREAD_THREADS_MAX. POSIX actually requires >> the latter to be defined (if at all) in only too. I doubt >> that the limit is actually 2^64-1. Maybe it should be a runtime limit >> _SC_THREAD* are missing, so apparently no one ever asks for the runtime >> limits. > > Which _SC_THREAD* is missing? Calling sysconf() with > _SC_THREAD_THREADS_MAX is buggy because sysconf converts ULONG_MAX to a > long. Er, none. I grepped the wrong headers (only , but _SC_THREAD* is in and sysconf(3) on _SC_THREAD* never reaches the kernel). Bruce From owner-freebsd-standards@FreeBSD.ORG Sat Aug 20 15:50:44 2005 Return-Path: X-Original-To: standards@freebsd.org 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 7935D16A41F for ; Sat, 20 Aug 2005 15:50:44 +0000 (GMT) (envelope-from keramida@freebsd.org) Received: from nic.ach.sch.gr (nic.sch.gr [194.63.238.4]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2E79543D48 for ; Sat, 20 Aug 2005 15:50:42 +0000 (GMT) (envelope-from keramida@freebsd.org) Received: (qmail 22831 invoked by uid 207); 20 Aug 2005 15:50:41 -0000 Received: from keramida@freebsd.org by nic by uid 201 with qmail-scanner-1.21 (sophie: 3.04/2.19/3.81. Clear:RC:1(81.186.70.44):. Processed in 4.068902 secs); 20 Aug 2005 15:50:41 -0000 Received: from dialup44.ach.sch.gr (HELO gothmog.gr) ([81.186.70.44]) (envelope-sender ) by nic.sch.gr (qmail-ldap-1.03) with DES-CBC3-SHA encrypted SMTP for ; 20 Aug 2005 15:50:37 -0000 Received: from gothmog.gr (gothmog [127.0.0.1]) by gothmog.gr (8.13.4/8.13.4) with ESMTP id j7KFoJoY001126; Sat, 20 Aug 2005 18:50:19 +0300 (EEST) (envelope-from keramida@freebsd.org) Received: (from giorgos@localhost) by gothmog.gr (8.13.4/8.13.4/Submit) id j7KFoJFk001125; Sat, 20 Aug 2005 18:50:19 +0300 (EEST) (envelope-from keramida@freebsd.org) Date: Sat, 20 Aug 2005 18:50:19 +0300 From: Giorgos Keramidas To: Bruce Evans , threads@freebsd.org, standards@freebsd.org Message-ID: <20050820155018.GD796@gothmog.gr> References: <20050819093649.GU21905@wombat.fafoe.narf.at> <20050819231640.E2640@epsplex.bde.org> <20050819183507.GE77069@wombat.fafoe.narf.at> <20050820151252.L60332@delplex.bde.org> <20050820081649.GA85488@wombat.fafoe.narf.at> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20050820081649.GA85488@wombat.fafoe.narf.at> Cc: Subject: Re: includes X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 20 Aug 2005 15:50:44 -0000 On 2005-08-20 10:16, Stefan Farfeleder wrote: > > >> only used to declare sigset_t and struct timespec. > > >> We have a whole header, , to help > > >> declare sigset_t better (it only declares > > >> __sigset_t), > > >... > > >I've include (for __uint32_t) and > > >instead. timespec is declared through . > > > > Too bad. > > Do you have a better suggestion? Stefan, we already have , unless I have misunderstood you and Bruce.