Swift Concurrency Learning ResourcesOne of the biggest pain points experienced Swift developers have is dealing with Swift concurrency, especially the changes in Swift 6. Many developers are sticking with Swift 5 to avoid the pain of migrating their code to Swift 6. If you are having trouble learning about Swift concurrency, I put together a list of resources that should help. F**king Approachable Swift ConcurrencyF**king Approachable Swift Concurrency is a good starting point to learn about approachable Swift concurrency. Don't worry about the site name if profanity bothers you. The name is the only profanity on the site. Matt Massicotte ArticlesI don't know anyone who has written more about Swift concurrency than Matt. You can read all of his Swift concurrency articles on his blog. You may find his A Swift Concurrency Glossary article helpful if you're new to Swift concurrency. Books and Courses
Places to Ask QuestionsThe best place to ask a question on Swift concurrency is the Swift forum. Many people ask concurrency questions there so your question may already have an answer. Many people who know a lot about Swift concurrency hang out on Mastodon so you can ask a question there. Use the Newsletter ArchiveYou can read previous issues of the newsletter using the following button:
|
Subscribe and get exclusive articles on Swift development, a free guide on moving from tutorials to making your first app, notices of sales on books, and anything I decide to add in the future.
Find the Code Causing Long SwiftUI Updates with Instruments Instruments comes with a SwiftUI instrument to find performance problems in your SwiftUI apps. This article shows how to use Instruments to find the code that causes long SwiftUI view updates. If you have never used Instruments, read the following article to learn how to profile your app with the SwiftUI instrument: Find the SwiftUI Views that Update the Most Using Instruments Finding Long Updates When you finish profiling your app,...
When you profile your app with the Allocations instrument, you may want to find the largest memory allocations your app makes. Take the following steps to find the largest memory allocations: Press Cmd-3 to open the allocations list. Click the Size column heading to sort the allocations by size. Choose All Heap Allocations from the Allocation Type menu in the bottom bar to hide virtual memory allocations. Your code doesn’t directly make virtual memory allocations. The Allocation Type menu is...
A common problem people run into when they start profiling their apps with Instruments is finding the code that is causing problems. Many instruments initially show general statistics instead of statistics about the code you wrote. For example the Allocations instrument initially shows the number of memory allocations and amount of allocated memory for hundreds of memory categories. If your app allocates a lot of memory, you want to find the code that allocates high amounts of memory. How do...