How do you profile an app in Instruments: Time Profiler, Allocations, Leaks, Hangs?
Essence
Instruments answers "what is actually happening", not "what I think is happening". The main rule is measure first, then optimize: intuition about "slow spots" is wrong more often than you'd think. Profile a Release build on a real device (Product → Profile): Debug has no compiler optimizations, and the simulator runs on the Mac's CPU, showing neither real speed nor real memory limits.
The rest of this answer, with code and interview follow-ups, is in the DevPrep app.
Read the full answer in DevPrep