This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author vstinner
Recipients jnoller, pitrou, vstinner
Date 2009-12-20.01:09:02
SpamBayes Score 1.9471647e-12
Marked as misclassified No
Message-id <200912200209.08411.victor.stinner@haypocalc.com>
In-reply-to <1261239968.3.0.677667478927.issue7544@psf.upfronthosting.co.za>
Content
Use a core dump: good idea!

haypo> Using my fuzzer (Fusil) on Python trunk, I got sometimes 
haypo> errors on multiprocessing.Pool():
haypo> 
haypo>    Fatal Python error: PyEval_AcquireThread: NULL new thread state

I read the source code of the thread module. This error means that 
PyThreadState_New() returns NULL which occurs if malloc() failed. I hit this 
error using my fuzzer because the fuzzer limits the total memory to something 
around 100 MB using setrlimit().

Said differently: in low memory condition, creating a new thread may exit the 
whole Python process if a memory allocation fail.

--

Sometimes, I get another error, similar to the "NULL new thread state" error:

   Fatal Python error: Couldn't create autoTLSkey mapping

I guess that the reason is the same: memory allocation failed. It should be 
the malloc() in find_key() (Python/thread.c).
History
Date User Action Args
2009-12-20 01:09:05vstinnersetrecipients: + vstinner, pitrou, jnoller
2009-12-20 01:09:03vstinnerlinkissue7544 messages
2009-12-20 01:09:02vstinnercreate