Subject: disabling PTHREAD_CONCURRENCY for 3.0
To: None <>
From: Chuck Silvers <>
List: tech-kern
Date: 12/10/2005 16:41:29
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

since the code triggered by setting PTHREAD_CONCURRENCY causes
library aborts and kernel panics, I'd like to disable it for 3.0
since it doesn't appear that it can be fixed in time.

any objections to the attached patch?  I'll just ask for it to be
applied to the 3.x branch and not commit it to -current, since
at least one person (christos) appears to be working on this.

we should remove the description of this stuff from the manpage as well,
but I don't speak roff so well.  could someone suggest a way to
comment it out there?


Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="diff.noconcur"

Index: src/lib/libpthread/pthread.c
RCS file: /cvsroot/src/lib/libpthread/pthread.c,v
retrieving revision 1.46
diff -u -p -r1.46 pthread.c
--- src/lib/libpthread/pthread.c	19 Oct 2005 02:44:45 -0000	1.46
+++ src/lib/libpthread/pthread.c	10 Dec 2005 14:39:44 -0000
@@ -150,10 +150,13 @@ pthread_init(void)
 	/* Initialize locks first; they're needed elsewhere. */
+#if 0
+	/* XXX this work was never finished, disable it for now. */
 	/* Find out requested/possible concurrency */
 	p = getenv("PTHREAD_CONCURRENCY");
 	pthread__maxconcurrency = p ? atoi(p) : 1;
 	if (pthread__maxconcurrency < 1)
 		pthread__maxconcurrency = 1;
 	if (pthread__maxconcurrency > ncpu)