Where to Go From Here?
You can download the completed version of the project using Download Materials at the top or bottom of this tutorial. In the second part of this tutorial, you’ll continue to improve upon this project.
In this Grand Central Dispatch tutorial, you learned how to make your code thread-safe and maintain the responsiveness of the main thread while performing CPU-intensive tasks.
If you can raise the minimum required version of your app to iOS 15, you should also check how async
and await
works with the WWDC 2021: Intro to async/await video. For a deeper dive, check out our Modern Concurrency in Swift book.
If you plan on optimizing your own apps, you should profile your work with Xcode’s built-in Time Profiler. Using this instrument is outside the scope of this tutorial, so check out How to Use Instruments for an excellent overview.
Our iOS Concurrency with GCD and Operations video course also covers a lot of the same topics covered in this tutorial.
In Part 2 of this tutorial, you’ll dive even deeper into GCD’s API to do even more cool stuff.
If you have any questions or comments, feel free to join the discussion below!