This page contains benchmark results for LayoutKit, Auto Layout, and manual layout code.
LayoutKit is as fast as manual layout code and significantly faster than Auto Layout.
Benchmarks were run on an iPhone 6 running iOS 9.3.2 with Swift optimization turned on.
estimatedItemSizeis hard to use so these tests use
- UICollectionViewFlowLayout requests the height of all cells during layout (even those that are off screen). This is why layout performance keeps getting worse as number of cells are added to the UICollectionView.
- Unlike UICollectionView, UITableView defers asking for the height of cells until it is needed. This is why performance is constant for seven or more cells.