1
0
mirror of https://github.com/danog/parallel.git synced 2024-11-27 04:44:56 +01:00
Commit Graph

52 Commits

Author SHA1 Message Date
coderstephen
cb1c20ae95 Add Vagrant box definition 2015-08-02 20:48:29 -05:00
coderstephen
5ae8a3b0f7 Add vagrant to gitignore 2015-08-02 19:45:44 -05:00
coderstephen
ae23b0adba Fix method names 2015-08-02 17:56:25 -05:00
coderstephen
ff2f0682d6 Add semaphore from sync extension 2015-08-01 21:56:18 -05:00
coderstephen
19080f651b Add interface for synchronous semaphores 2015-08-01 21:51:45 -05:00
coderstephen
9b63e7fe7d A mutex based on the sync extension 2015-08-01 21:18:14 -05:00
coderstephen
cf788a9377 Add portable mutex using flock() 2015-08-01 21:07:33 -05:00
coderstephen
eded7b86a4 Use a common interface for mutexes 2015-08-01 20:15:03 -05:00
coderstephen
a0d0b3646e Add a thread-safe mutex 2015-08-01 20:02:57 -05:00
coderstephen
92432ff58b Experimental closure-based contexts 2015-07-26 17:53:00 -05:00
coderstephen
966b73a74c Add benchmark for Forking\SharedObject 2015-07-16 03:19:57 -05:00
coderstephen
e01404989b Add benchmarks for profiling implementations and backends 2015-07-16 03:02:58 -05:00
coderstephen
9337d3a8ea Fix bug where shared data would sometimes disappear 2015-07-15 18:36:42 -05:00
coderstephen
1f76fcadb2 Synchronization methods now part of SynchronizableInterface 2015-07-15 18:12:18 -05:00
coderstephen
1ed1a45a3d Fix pending locks not handled bug 2015-07-15 18:11:05 -05:00
coderstephen
698fb58058 Fix missing synchronized read access 2015-07-15 18:10:27 -05:00
coderstephen
72f767b707 Fix docblock goof 2015-07-15 17:31:04 -05:00
coderstephen
6442bb9191 Don't recursively create thread instances 2015-07-15 12:36:32 -05:00
coderstephen
e6be25c2ca Add some splurge to the README 2015-07-15 11:29:35 -05:00
coderstephen
46d18480a4 Add some comments and docblocks 2015-07-15 11:24:04 -05:00
coderstephen
2eff29d036 Allow any callable inside synchronized() calls 2015-07-14 23:47:21 -05:00
coderstephen
3c4448866f Run given ThreadContext::run() inside thread 2015-07-14 17:15:10 -05:00
coderstephen
18b7c68f65 Experimental pthread context 2015-07-13 17:30:59 -05:00
coderstephen
f1b681537f Async synchronized object 2015-07-13 17:30:14 -05:00
coderstephen
f3a6f03d4c Update example to use async locking 2015-07-13 12:30:00 -05:00
coderstephen
f9d57e7d8f ContextInterface now returns promises for locking 2015-07-13 12:28:14 -05:00
coderstephen
a288e99287 Split Synchronized into SharedObject and integrate async locking
Synchronized has now been split into SharedObject, and a subclass Synchronized. AsyncSemaphore now extends SharedObject and uses a sync semaphore manually as gatekeeper, and Synchronized now uses an async semaphore for locking.
2015-07-13 12:26:37 -05:00
coderstephen
6f185ad17d Handle signals inside AsyncSemaphore 2015-07-12 15:57:04 -05:00
coderstephen
24a1e2fc8f Move special values to constants 2015-07-11 12:07:31 -05:00
coderstephen
277e5ded02 Synchronize using shmop and docblock annotations 2015-07-11 05:01:36 -05:00
coderstephen
fefa5e706a Prototypal asynchronous semaphore 2015-07-10 23:13:24 -05:00
coderstephen
b0e19519d0 Fix semaphores sometimes not removed after termination 2015-07-10 18:24:58 -05:00
coderstephen
e9f09077c9 More appropriate method names 2015-07-10 17:48:50 -05:00
coderstephen
a4bb4b601b Update test example 2015-07-10 16:17:43 -05:00
coderstephen
8dd597238d Semaphore handles can be serialized across contexts 2015-07-10 16:17:18 -05:00
coderstephen
2c40e0ddcb Restructure exceptions 2015-07-10 16:16:24 -05:00
coderstephen
e257109ad1 Rename Context to ContextInterface 2015-07-10 16:07:52 -05:00
coderstephen
99873cc74c Only call reInit() in forked process 2015-07-10 15:53:57 -05:00
coderstephen
e8754fb2ba Merge with remote 2015-07-10 15:32:15 -05:00
Aaron Piotrowski
4146c3fc09 Initial commit 2015-07-10 15:15:42 -05:00
coderstephen
12a7f75a16 Fix wrong class name 2015-07-10 13:34:40 -05:00
coderstephen
6fc6b6f893 Always unlock even after exceptions and better exceptions thrown 2015-07-10 11:59:38 -05:00
coderstephen
1698aeefcf Rename Synchronizable to Synchronized and move locking to Synchronized
The ability to call synchronized functions now belongs to any Synchronized object.
2015-07-10 11:23:20 -05:00
coderstephen
50c3620a6f Fix wrong name used for SysV extensions 2015-07-10 02:24:37 -05:00
coderstephen
27549c5c9c Update fork context to support synchronization and asynchronous join 2015-07-10 02:23:08 -05:00
coderstephen
3a30fa1d4c Context interface now synchronizes synchronously and joins asynchronously 2015-07-10 02:22:04 -05:00
coderstephen
40f0ca220e Add semaphore exception type 2015-07-10 02:20:52 -05:00
coderstephen
e435ace0af Add atomic, UNIX-compatible semaphore class 2015-07-10 02:20:34 -05:00
coderstephen
64b429ce25 Another working setup using local UNIX socket pairs for speed 2015-07-09 13:13:20 -05:00
coderstephen
6cf368d3dd Add some really simple working code using forks and sockets 2015-07-09 01:35:34 -05:00