mirror of
https://github.com/python/cpython.git
synced 2026-06-28 03:41:13 +00:00
gh-151546: Fix stack limits on musl (#151548)
If the thread stack size is set by linker flags, pass the stack size
to Python/ceval.c via the new _Py_LINKER_THREAD_STACK_SIZE variable
to set Py_C_STACK_SIZE macro.
(cherry picked from commit 9a61d1c0c8)
This commit is contained in:
parent
ff6e973c3b
commit
a5c5edddbc
5 changed files with 16 additions and 1 deletions
|
|
@ -63,7 +63,9 @@ _Py_EnterRecursiveCallUnchecked(PyThreadState *tstate)
|
|||
}
|
||||
}
|
||||
|
||||
#if defined(__s390x__)
|
||||
#if defined(_Py_LINKER_THREAD_STACK_SIZE)
|
||||
# define Py_C_STACK_SIZE _Py_LINKER_THREAD_STACK_SIZE
|
||||
#elif defined(__s390x__)
|
||||
# define Py_C_STACK_SIZE 320000
|
||||
#elif defined(_WIN32)
|
||||
// Don't define Py_C_STACK_SIZE, ask the O/S
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue