mirror of
https://github.com/python/cpython.git
synced 2025-07-17 08:15:19 +00:00
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.
This commit is contained in:
parent
e2b61e0190
commit
30e97dbe96
1 changed files with 1 additions and 1 deletions
|
@ -133,7 +133,7 @@ PyThread_start_new_thread(void (*func)(void *), void *arg)
|
||||||
#ifdef THREAD_STACK_SIZE
|
#ifdef THREAD_STACK_SIZE
|
||||||
pthread_attr_setstacksize(&attrs, THREAD_STACK_SIZE);
|
pthread_attr_setstacksize(&attrs, THREAD_STACK_SIZE);
|
||||||
#endif
|
#endif
|
||||||
#ifdef PTHREAD_SYSTEM_SCHED_SUPPORTED
|
#if defined(PTHREAD_SYSTEM_SCHED_SUPPORTED) && !defined(__FreeBSD__)
|
||||||
pthread_attr_setscope(&attrs, PTHREAD_SCOPE_SYSTEM);
|
pthread_attr_setscope(&attrs, PTHREAD_SCOPE_SYSTEM);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue