| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
pthread_getattr_np() was skipped on every non-glibc, non-Android Linux because musl misreports the main thread's stack. It is accurate for the threads musl creates itself, so query those and keep the estimate only for the main thread. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
| Back | FazBrowse Home | New Git URL |
hardware_stack_limits() skipped pthread_getattr_np() on any Linux that is neither glibc nor Android, because musl misreports the main thread's stack. musl is accurate for the threads it creates itself, so the blanket exclusion left the interpreter assuming Py_C_STACK_SIZE everywhere, and a thread with a smaller stack overflowed before the recursion guard fired.
Query the stack on every thread except the process main thread, which keeps the old estimate.
On Alpine 3.24 this takes c_recursion_remaining from a constant 1450 to 250 / 12650 for 256 KiB / 8 MiB threads — the same numbers glibc reports — and the full suite goes from 1 failure (a SIGSEGV in test_lazy_import) to Result: SUCCESS. No change on glibc.
🤖 Generated with Claude Code