STINNER Victor <vstin...@redhat.com> added the comment:
Oh, my script called _thread.stack_size() to read the stack size, but that doesn't work: calling _thread.stack_size() sets the stack size to 0 again. stack2.py is the fixed script. It seems like the test works with a stack of 8 MiB and the default recursion limit of 1000 Python frames: vstinner@freebsd$ ./python stack.py 1000 4096 setrecursionlimit(1000) stack_size: 4096.0 kiB = 4.0 MiB Segmentation fault (core dumped) vstinner@freebsd$ ./python stack.py 1000 8192 setrecursionlimit(1000) stack_size: 8192.0 kiB = 8.0 MiB end of main thread So the problem is that the FreeBSD default thread stack size is too small. ---------- Added file: https://bugs.python.org/file48554/stack2.py _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue37906> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com