Upgrade to Pro — share decks privately, control downloads, hide ads and more …

App Startup Time: Optimization & Monitoring

d_date
June 18, 2017

App Startup Time: Optimization & Monitoring

2017/06/19 potatotips #41
2017/07/15 SWWDC x AKIBA.swift

d_date

June 18, 2017
Tweet

More Decks by d_date

Other Decks in Programming

Transcript

  1. Daiki Matsudate,@d_date • iOS Freelancer • Supporting Realm as News

    Translator • Organizer of CLEM • WWDC17 Attendee
  2. WWDC17 • Back to San Jose • Over 3,000 attendee

    • Over 200 sessions / labs / events
  3. Sessions • Frameworks • Design • Developer Tools • Distribution

    • Featured • Graphics and Games • Media • System Frameworks
  4. Developer Tools Localizing Swift Debugging Xcode9 Github Undefined Behavior Playgrounds

    Testing LLVM Interface Builder App Startup Time Testability
  5. Developer Tools Localizing Swift Debugging Xcode9 Github Undefined Behavior Playgrounds

    Testing LLVM Interface Builder App Startup Time Testability
  6. Recognition • ը૾ͷࢹೝ … 13ms • ϑΥʔΧεઌͷܾఆ…100 - 140ms •

    ૢ࡞͕ྲྀΕʹ৐͍ͬͯΔ…200 - 1000ms • ڵຯͷର৅͕ଞʹҠΔ… 1000 - 10000ms • ؔ৺͕ࣦΘΕΔ … 10000ms - 2014 MIT Research
  7. Recognition • ը૾ͷࢹೝ … 13ms • ϑΥʔΧεઌͷܾఆ…100 - 140ms •

    ૢ࡞͕ྲྀΕʹ৐͍ͬͯΔ…200 - 1000ms • ڵຯͷର৅͕ଞʹҠΔ… 1000 - 10000ms • ؔ৺͕ࣦΘΕΔ … 10000ms - 2014 MIT
  8. App Startup Time • Do less! • Embed fewer dylibs

    • Declare classes/methods • Use fewer initializers • Use more Swift • No initializers • Swift size improvements
  9. Monitoring • In Development • Use DYLD_PRINT_STATISTICS • Initializer Calls

    • After Release • Firebase Performance Monitoring How to
  10. Initializer Calls • Available on iOS 11 and macOS High

    Sierra • Provides precise timing for each static initializer • Available through Instruments
  11. Summary • fewer dylibs, classes/methods, initializer • Use more Swift

    • App startup time monitoring • Use DYLD_PRINT_STATISTICS • Initializer Calls - Instruments (iOS 11~) • Firebase Performance Monitoring
  12. Resources App Startup Time:Past, Present, and Future WWDC 2017 Optimizing

    App Startup Time WWDC 2016 Firebase Performance Monitoring