|
1 | 1 | #PosixDispatch |
2 | | -A fast, small, efficient analog of GCD in Swift |
| 2 | +A cross-platform library written in Swift 5 for multithreading based on[POSIX threads](https://uk.wikipedia.org/wiki/Pthread). It has a similar API to Apple’s[GCD](https://developer.apple.com/documentation/dispatch) and in most cases works much faster. |
| 3 | + |
| 4 | +It consists of the following: |
| 5 | + |
| 6 | +***PLock** - wrapper for POSIX mutex, analog to[NSLock](https://developer.apple.com/documentation/foundation/nslock) |
| 7 | +***PCondition** - wrapper for POSIX condition, analog to[NSCondition](https://developer.apple.com/documentation/foundation/nscondition) |
| 8 | +***PThread** - wrapper for POSIX thread, analog to[Thread](https://developer.apple.com/documentation/foundation/thread) |
| 9 | +***PThreadPool** -[thread pool](https://en.wikipedia.org/wiki/Thread_pool) implementation |
| 10 | +***PDispatchQueue** - FIFO queue for serially or concurrently executing tasks, analog to[DispatchQueue](https://developer.apple.com/documentation/dispatch/dispatchqueue) |
| 11 | +***PDispatchGroup** - group of tasks for aggregation and synchronization, analog to[DispatchGroup](https://developer.apple.com/documentation/dispatch/dispatchgroup) |
| 12 | +***PDispatchSemaphore** -[semaphore](https://en.wikipedia.org/wiki/Semaphore_(programming)) implementation, analog to[DispatchSemaphore](https://developer.apple.com/documentation/dispatch/dispatchsemaphore) |