Home

Awesome

Swift-Analysis-Workflow

Make it easier to see what's making your build slow.

You can add flags to the Swift compiler to add new build output to track down slow functions, however browsing this output in Xcode sucks, this workflow will produce a file sorted by time to compile on your Desktop.

Prerequisites

You need to have the Swift profiling code turned on for your targets in order to produce the desired output. If you need help doing that, please check out Bryan Irace's fantastic post to learn how to turn it on!

How To Use

  1. Double click on the Analyze Swift Performance.workflow file.
  2. Choose "Install"
  3. Find an .xcactivitylog file, mine are in ~/Developer/Xcode/DerivedData/<project>
  4. Right click on the file and in the Services menu, click "Analyze Swift Performance"

A file will eventually show up on you Desktop ending in -analysis.txt

Caveats

Thanks

Big thanks to @irace as he and I were talking about this very problem recently and he helped with some of the shell scripts!

If you have any questions about contributing or whatever, please feel free to drop me a line on Twitter I'm just @brianmichel.