Skip to content

Commit 30e97db

Browse files
committed
SF Patch #902444: Use process scope thread on FreeBSD. System scope
is too expensive on FreeBSD's KSE threading infrastructure and even test_threadedimport fails on default setting.
1 parent e2b61e0 commit 30e97db

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎Python/thread_pthread.h‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ PyThread_start_new_thread(void (*func)(void *), void *arg)
133133
#ifdef THREAD_STACK_SIZE
134134
pthread_attr_setstacksize(&attrs, THREAD_STACK_SIZE);
135135
#endif
136-
#ifdef PTHREAD_SYSTEM_SCHED_SUPPORTED
136+
#if defined(PTHREAD_SYSTEM_SCHED_SUPPORTED) && !defined(__FreeBSD__)
137137
pthread_attr_setscope(&attrs, PTHREAD_SCOPE_SYSTEM);
138138
#endif
139139

0 commit comments

Comments
 (0)