1. Stephen Tu
  2. mino-pypy

Source

mino-pypy / pypy / translator / c / src / thread_pthread.h

Author Commit Message Date Builds
Armin Rigo
Kill remaining code attempting to support prebuilt locks, which doesn't really work (e.g. on OS/X the mutexes and condition variables need to be reinitialized after fork()).
Amaury Forgeot d'Arc
It's certainly a good idea to put thread functions apart, and only compile TLS storage with other genc sources.
Amaury Forgeot d'Arc
Split thread.h into header and implementation files.
Amaury Forgeot d'Arc
Be positive: #define PYPY_MAIN_IMPLEMENTATION_FILE when we need the implementation of the C helper functions.
Armin Rigo
Cygwin patch by Uwe F. Mayer, slightly edited to minimize the length of the diff.
Armin Rigo
Tweaks.
Branches
gil-improvement
Armin Rigo
Fixes.
Branches
gil-improvement
Armin Rigo
Port the code. Trying with a random but larger value for sys.checkinterval; will experiment more.
Branches
gil-improvement
Armin Rigo
(iko, arigo) A bit unsure, but it seems that thread.locks, implemented on OSX as pairs of a mutex and a condition variable, don't really reproductibly survive a fork(). So we do some ugly hack just to reset all of them after a fork(). Obscure, particularly because CPython doesn't seem to need it, and we have no clue why.
Armin Rigo
Silence a warning in case we compile in non-standalone mode.
Armin Rigo
Reintroduce fused_acquire_release_lock(), which had a good reason to exist (see comments).
Armin Rigo
Finish the merge of the pypy-more-rtti-inprogress branch. Delete the branches.
Armin Rigo
* Export thread-local storage from the thread_*.h files. WinNT version carefully re-read but not tested! Sorry if I broke it. * Use it to fix stack_too_big(). Here too I hope not to have made too many bugs but it's not much tested yet.
Samuele Pedroni
missing struct declarations before use in the func prototypes
Christian Tismer
modified all include files to support inclusion into a non-main module.
Armin Rigo
(rxe, arigo) Support in genc for prebuilt external objects -- in this case, prebuilt locks. Split OpaqueNode into xxx_OpaqueNode classes for the various usages of opaque prebuilt constants. Lots of changes; this required producing and calling start-up code to the generated C source. Each thread_*.h needs to provide in the RPyOpaque_INITEXPR_ThreadLock macro an expression suitable for a lock initializer (thou…
Armin Rigo
(rxe, arigo) Finished basic thread support in the C back-end. * lots of hacks to support in the annotator/rtyper the notion of a call-back function, i.e. a function passed as argument to a built-in and that is implicitely called by the built-in. See emulate_pbc_call(). * the thread_*.h have PyThreadStartThread() and PyThreadGetIdent(), called by ll_thread.h. (Still copied from CPython, still untested…
Armin Rigo
(rxe, arigo) genc: acquire() and release() methods of locks. (thread_nt is still untested)
Armin Rigo
Starting the C back-end support for the 'thread' module. Supported so far: creating and destroying lock objects. * extends database.py/node.py with an ExtTypeOpaqueDefNode corresponding to the inlined Opaque field. * struct RPyOpaque_ThreadLock must be declared early, because it is the type of the above field. Added a g_prerequisite.h that is included before the struct definitions generated by genc. * thread support is split in several header files: - thread.h selects between APIs depen…