From 852877245b9e2e06c322cde7889059d0106aa6b3 Mon Sep 17 00:00:00 2001 From: Jungpyo Hong Date: Fri, 2 Jul 2021 03:41:22 -0500 Subject: [PATCH] Update README.md --- README.md | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 0cfc8d8..c9871b8 100644 --- a/README.md +++ b/README.md @@ -83,6 +83,7 @@ Feel free to fork this repository and pull requests!! - [USage](#Accessibility-Usage) - [GCD](#GCD) - [DispatchQueue](#DispatchQueue) + - [Thread Safety](#thread-safety) - [DispatchGroup](#DispatchGroup) - [DispatchWorkItem](#DispatchWorkItem) - [Operation](#operation) @@ -1272,12 +1273,21 @@ GCD(Grand Central Dispatch) is a low-level API for managing concurrent operation ## DispatchQueue An object that manages the execution of tasks serially or concurrently on your app's main thread or on a background thread. -#### main +### main We can say main is a serial queue -#### global() +### global() We can say global is a concurrent queue +## Thread Safety + +[Concurrency & Thread Safety in Swift](https://medium.com/cubo-ai/concurrency-thread-safety-in-swift-5281535f7d3a) + +1. Dispatch Barrier +2. Dispatch Semaphore +3. NSLock + + ## DispatchGroup