cpython/Include
Benjamin Peterson 0df35a93a2 Merged revisions 74841 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r74841 | thomas.wouters | 2009-09-16 14:55:54 -0500 (Wed, 16 Sep 2009) | 23 lines


  Fix issue #1590864, multiple threads and fork() can cause deadlocks, by
  acquiring the import lock around fork() calls. This prevents other threads
  from having that lock while the fork happens, and is the recommended way of
  dealing with such issues. There are two other locks we care about, the GIL
  and the Thread Local Storage lock. The GIL is obviously held when calling
  Python functions like os.fork(), and the TLS lock is explicitly reallocated
  instead, while also deleting now-orphaned TLS data.

  This only fixes calls to os.fork(), not extension modules or embedding
  programs calling C's fork() directly. Solving that requires a new set of API
  functions, and possibly a rewrite of the Python/thread_*.c mess. Add a
  warning explaining the problem to the documentation in the mean time.

  This also changes behaviour a little on AIX. Before, AIX (but only AIX) was
  getting the import lock reallocated, seemingly to avoid this very same
  problem. This is not the right approach, because the import lock is a
  re-entrant one, and reallocating would do the wrong thing when forking while
  holding the import lock.

  Will backport to 2.6, minus the tiny AIX behaviour change.
........
2009-10-04 20:32:25 +00:00
..
Python-ast.h Merged revisions 62047 via svnmerge from 2008-03-31 05:14:30 +00:00
Python.h remove PyCObject 2009-07-01 01:28:55 +00:00
abstract.h remove comment about PyNumber_Int 2009-07-01 01:45:12 +00:00
asdl.h
ast.h
bitset.h
bltinmodule.h these builtins have to be initialized 2009-05-09 18:10:51 +00:00
boolobject.h #1629: Renamed Py_Size, Py_Type and Py_Refcnt to Py_SIZE, Py_TYPE and Py_REFCNT. 2007-12-19 02:45:37 +00:00
bytearrayobject.h Merged revisions 63829-63831,63858,63865,63879,63882,63948,63970-63972,63976,63989,64014-64015,64021-64022,64063-64065,64067 via svnmerge from 2008-06-10 16:37:50 +00:00
bytes_methods.h Merged revisions 72040 via svnmerge from 2009-04-27 20:39:49 +00:00
bytesobject.h The other half of Issue #1580: use short float repr where possible. 2009-04-16 20:16:10 +00:00
cellobject.h #1629: Renamed Py_Size, Py_Type and Py_Refcnt to Py_SIZE, Py_TYPE and Py_REFCNT. 2007-12-19 02:45:37 +00:00
ceval.h Issue #5392: when a very low recursion limit was set, the interpreter would 2009-03-13 19:25:20 +00:00
classobject.h Merged revisions 60481,60485,60489-60492,60494-60496,60498-60499,60501-60503,60505-60506,60508-60509,60523-60524,60532,60543,60545,60547-60548,60552,60554,60556-60559,60561-60562,60569,60571-60572,60574,60576-60583,60585-60586,60589,60591,60594-60595,60597-60598,60600-60601,60606-60612,60615,60617,60619-60621,60623-60625,60627-60629,60631,60633,60635,60647,60650,60652,60654,60656,60658-60659,60664-60666,60668-60670,60672,60676,60678,60680-60683,60685-60686,60688,60690,60692-60694,60697-60700,60705-60706,60708,60711,60714,60720,60724-60730,60732,60736,60742,60744,60746,60748,60750-60751,60753,60756-60757,60759-60761,60763-60764,60766,60769-60770,60774-60784,60787-60845 via svnmerge from 2008-02-16 07:38:31 +00:00
code.h Merged revisions 72487-72488,72879 via svnmerge from 2009-07-21 04:30:03 +00:00
codecs.h Move the codec decode type checks to bytes/bytearray.decode(). 2008-06-06 12:18:17 +00:00
compile.h The BDFL has retired! Long live the FLUFL (Friendly Language Uncle For Life)! 2009-04-01 05:08:41 +00:00
complexobject.h Issue #1588: Add complex.__format__. 2009-04-30 01:00:33 +00:00
datetime.h add a replacement API for PyCObject, PyCapsule #5630 2009-05-05 22:31:58 +00:00
descrobject.h Issue #6151: Make PyDescr_COMMON conform to standard C. 2009-07-22 03:56:36 +00:00
dictobject.h Merged revisions 70546 via svnmerge from 2009-03-23 18:52:06 +00:00
dtoa.h Issue #1580: use short float repr where possible. 2009-04-16 19:52:09 +00:00
enumobject.h
errcode.h Implement PEP 3131. Add isidentifier to str. 2007-08-15 07:32:56 +00:00
eval.h
fileobject.h Merged revisions 69364-69365,69409-69410,69413,69417,69435,69442,69447,69495,69519-69521 via svnmerge from 2009-02-13 02:50:59 +00:00
floatobject.h Issue #5920: Changed format.__float__ and complex.__float__ to use a precision of 12 when using the empty presentation type. This more closely matches str()'s behavior and reduces surprises when adding alignment flags to an empty format string. Patch by Mark Dickinson. 2009-05-05 14:04:18 +00:00
frameobject.h Merged revisions 72487-72488,72879 via svnmerge from 2009-07-21 04:30:03 +00:00
funcobject.h #1629: Renamed Py_Size, Py_Type and Py_Refcnt to Py_SIZE, Py_TYPE and Py_REFCNT. 2007-12-19 02:45:37 +00:00
genobject.h Merged revisions 60284-60349 via svnmerge from 2008-01-27 15:18:18 +00:00
graminit.h fix an ambiguity in the grammar from the implementation of extended unpacking 2009-09-27 02:43:28 +00:00
grammar.h
import.h Merged revisions 74841 via svnmerge from 2009-10-04 20:32:25 +00:00
intrcheck.h
iterobject.h Move itertools izip() code to builtins as zip(). Complete the renaming. 2008-03-13 02:09:15 +00:00
listobject.h #1629: Renamed Py_Size, Py_Type and Py_Refcnt to Py_SIZE, Py_TYPE and Py_REFCNT. 2007-12-19 02:45:37 +00:00
longintrepr.h Issue #6713: Improve performance of str(n) and repr(n) for integers n 2009-09-16 21:23:34 +00:00
longobject.h Issue #4258: Make it possible to use 30-bit digits for PyLongs: 2009-03-18 20:06:12 +00:00
marshal.h
memoryobject.h Issue #4822: fix messy indentation in memoryobject.c/.h, before we may backport it to trunk. 2009-01-03 19:20:36 +00:00
metagrammar.h
methodobject.h #3247: get rid of Py_FindMethod 2008-07-02 22:38:47 +00:00
modsupport.h #5735: Modules compiled with incompatible settings (--with-pydebug when python is not) 2009-06-01 21:16:17 +00:00
moduleobject.h Implement PEP 3121: new module initialization and finalization API. 2008-06-11 05:26:20 +00:00
node.h
object.h Merged revisions 72461 via svnmerge from 2009-05-08 03:25:19 +00:00
objimpl.h http://bugs.python.org/issue6836 2009-09-28 13:45:02 +00:00
opcode.h Merged revisions 72912,72920,72940 via svnmerge from 2009-06-28 03:18:59 +00:00
osdefs.h Change command line processing API to use wchar_t. 2008-04-05 20:41:37 +00:00
parsetok.h The BDFL has retired! Long live the FLUFL (Friendly Language Uncle For Life)! 2009-04-01 05:08:41 +00:00
patchlevel.h fix mistake in version bump 2009-06-27 22:00:01 +00:00
pgen.h
pgenheaders.h
py_curses.h Merged revisions 74693 via svnmerge from 2009-09-06 21:24:55 +00:00
pyarena.h
pycapsule.h Remove trailing whitespace. 2009-05-17 22:19:14 +00:00
pyctype.h Include files missed in r72044. 2009-04-27 20:54:42 +00:00
pydebug.h Issue #4705: Fix the -u ("unbuffered binary stdout and stderr") command-line 2009-01-09 18:53:14 +00:00
pyerrors.h Merged revisions 73376,73393,73398,73400,73404-73405,73409,73419-73421,73432,73457,73460,73485-73486,73488-73489,73501-73502,73513-73514 via svnmerge from 2009-06-28 19:19:51 +00:00
pyexpat.h add a replacement API for PyCObject, PyCapsule #5630 2009-05-05 22:31:58 +00:00
pyfpe.h
pygetopt.h Change command line processing API to use wchar_t. 2008-04-05 20:41:37 +00:00
pymacconfig.h Don't try to use x87 assembly on OS X universal builds. 2009-04-25 18:22:27 +00:00
pymath.h Merged revisions 73660 via svnmerge from 2009-06-28 22:40:48 +00:00
pymem.h http://bugs.python.org/issue6836 2009-09-28 13:45:02 +00:00
pyport.h Merged revisions 73701 via svnmerge from 2009-06-30 15:45:17 +00:00
pystate.h Issue 3723: Fixed initialization of subinterpreters 2008-10-30 21:48:26 +00:00
pystrcmp.h Merged revisions 59541-59561 via svnmerge from 2007-12-19 02:07:34 +00:00
pystrtod.h Refactor to remove duplicated nan/inf parsing code in 2009-05-20 22:05:25 +00:00
pythonrun.h a little more fiddling to make flags like 2.x 2009-07-02 21:54:36 +00:00
pythread.h Merged revisions 64212 via svnmerge from 2008-06-13 00:26:50 +00:00
rangeobject.h #1629: Renamed Py_Size, Py_Type and Py_Refcnt to Py_SIZE, Py_TYPE and Py_REFCNT. 2007-12-19 02:45:37 +00:00
setobject.h Merged revisions 60481,60485,60489-60492,60494-60496,60498-60499,60501-60503,60505-60506,60508-60509,60523-60524,60532,60543,60545,60547-60548,60552-60567 via svnmerge from 2008-02-04 18:48:49 +00:00
sliceobject.h Merged revisions 71734,71738-71739 via svnmerge from 2009-04-20 02:09:13 +00:00
structmember.h Merged revisions 60176-60209 via svnmerge from 2008-01-23 08:24:23 +00:00
structseq.h Remove PyArg_Parse usage from time module. (An extra set of eyeballs on 2007-08-24 21:11:00 +00:00
symtable.h Merged revisions 73376,73393,73398,73400,73404-73405,73409,73419-73421,73432,73457,73460,73485-73486,73488-73489,73501-73502,73513-73514 via svnmerge from 2009-06-28 19:19:51 +00:00
sysmodule.h Merged revisions 62260-62261,62266,62271,62277-62279,62289-62290,62293-62298,62302-62306,62308,62311,62313-62315,62319-62321 via svnmerge from 2008-04-13 13:53:33 +00:00
timefuncs.h
token.h
traceback.h Merged revisions 64722,64729,64753,64845-64846,64849,64871,64880-64882,64885,64888,64897,64900-64901,64915,64926-64929,64938-64941,64944,64961,64966,64973 via svnmerge from 2008-07-16 12:55:28 +00:00
tupleobject.h Merged revisions 70546 via svnmerge from 2009-03-23 18:52:06 +00:00
ucnhash.h add a replacement API for PyCObject, PyCapsule #5630 2009-05-05 22:31:58 +00:00
unicodeobject.h Issue #5915: Implement PEP 383, Non-decodable Bytes in 2009-05-05 04:43:17 +00:00
warnings.h Implement PEP 3121: new module initialization and finalization API. 2008-06-11 05:26:20 +00:00
weakrefobject.h #1629: Renamed Py_Size, Py_Type and Py_Refcnt to Py_SIZE, Py_TYPE and Py_REFCNT. 2007-12-19 02:45:37 +00:00