Swift High Performance: Dictionary Keys

I improved Factory’s dictionary lookup performance by over 500%! Can you do the same in your app?

Michael Long
The Swift Cooperative
11 min readAug 27, 2023

--

Photo by Chunli Ju on Unsplash

This article is an in-depth exploration of how to create dictionary keys that are fast and performant under all circumstances, and why String-based keys often fail in that regard.

--

--

Michael Long
The Swift Cooperative

I write about Apple, Swift, and SwiftUI in particular, and technology in general. I'm also a Lead iOS Engineer at InRhythm, a modern digital consulting firm.