More on MySQL -- Fatal trap 12

Daniel Eischen eischen at vigrid.com
Tue Feb 17 16:49:54 PST 2004


On Tue, 17 Feb 2004, Daniel Eischen wrote:
> On Tue, 17 Feb 2004, Kris Gale wrote:
> > Does this look like a fixable problem with KSE
> > to anyone on this list?
> 
> I would like to see how MySQL works when using process
> scope threads.  Do you know enough to hack it to do that?

Alternatively, this patch to libpthread should force all
threads to be process scope.

-- 
Dan Eischen

Index: thread/thr_create.c
===================================================================
RCS file: /opt/FreeBSD/cvs/src/lib/libpthread/thread/thr_create.c,v
retrieving revision 1.53
diff -u -r1.53 thr_create.c
--- thread/thr_create.c	8 Jan 2004 15:37:09 -0000	1.53
+++ thread/thr_create.c	18 Feb 2004 00:45:48 -0000
@@ -128,6 +128,7 @@
 			new_thread->attr = _pthread_attr_default;
 		else {
 			new_thread->attr = *(*attr);
+			new_thread->attr &= ~PTHREAD_SCOPE_SYSTEM;
 			if ((*attr)->sched_inherit == PTHREAD_INHERIT_SCHED) {
 				/* inherit scheduling contention scop */
 				if (curthread->attr.flags &= PTHREAD_SCOPE_SYSTEM)




More information about the freebsd-threads mailing list