Tools and libraries to understand app performance

Stay organized with collections Save and categorize content based on your preferences.

There are multiple tools that can be useful for inspecting and monitoring opportunities for performance improvements in your app.

Understanding performance locally: Benchmarking libraries

  • The Macrobenchmark library helps you measure larger end-user interactions, such as startup, interacting with the UI, and animations.
  • The Microbenchmark library helps analyze performance of more granular, application-specific situations.

Understanding performance in production

  • Android vitals can help improve your app's performance by alerting you when various performance metrics exceed predetermined thresholds.
  • The Firebase performance SDK can also collect various metrics about your app's performance. For example, you can use the SDK to measure the time between when the user opens the app and when the app becomes responsive, helping identify potential startup bottlenecks.

Profiling locally: Android Studio

  • Use Android Studio to record and view system traces or stack sampling traces.
  • To begin recording traces using Android Studio, see Record traces. For additional information, check out this video series.
  • Simpleperf is a native stack sampling tool for Android. It can be used to profile both Android applications and native processes running on Android. It can profile both Java and C++ code on Android.

Advanced profiling tools: Perfetto tracing