Swift Optimization

I learned a hard lesson today: to make Swift really fast you have to know what you’re doing. You can’t just slap some code together and expect it to be zippy without understanding some of how Swift was designed and how it works. There is a very good presentation by some of the team members that built Swift here. My initial takeaway was that it was important to finalize any classes you didn’t plan on subclassing, incrementally check the timing analyzer, and finally, employ whole module optimization.

Continue reading