summaryrefslogtreecommitdiffstatshomepage
path: root/py/mpthread.h
Commit message (Collapse)AuthorAge
* py/mpthread: Include mpstate.h when defining GIL macros.Damien George2016-06-28
|
* py/modthread: Allow to properly set the stack limit of a thread.Damien George2016-06-28
| | | | | We rely on the port setting and adjusting the stack size so there is enough room to recover from hitting the stack limit.
* py/mpthread.h: Move GIL macros outside MICROPY_PY_THREAD block.Damien George2016-06-28
| | | | The GIL macros are needed even if threading is not enabled.
* py: Implement a simple global interpreter lock.Damien George2016-06-28
| | | | | This makes the VM/runtime thread safe, at the cost of not being able to run code in parallel.
* py/modthread: Call mp_thread_start/mp_thread_finish around threads.Damien George2016-06-28
| | | | So the underlying thread implementation can do any necessary bookkeeping.
* py/gc: Make memory manager and garbage collector thread safe.Damien George2016-06-28
| | | | | | By using a single, global mutex, all memory-related functions (alloc, free, realloc, collect, etc) are made thread safe. This means that only one thread can be in such a function at any one time.
* py/modthread: Implement lock object, for creating a mutex.Damien George2016-06-28
|
* py/modthread: Add stack_size() function.Damien George2016-06-28
|
* py: Add basic _thread module, with ability to start a new thread.Damien George2016-06-28