Perf on Android

We are working on project that requires us to collect performance events on Android. This involves a few steps:

  • Recompile the kernel with the right flags. You should do this incrementally, some options may make you kernel crash at boot time. You should consider including the following flags
  • Compile the perf tool. It is nicely part of the Android source and you can just compile it easily with the rest of the distribution.
  • To get started with perf, you can take a look at the following one-liner examples:

Interesting power management information is spread in multiple place. Below, I will summarize some of it (as I learn it):

  • CPU:
    • The time spent in different states can be directly obtained from cpufreq-stats. Similar statistics can be obtained from when the system is idle, from cupidle.
Tagged with:
Posted in Android

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: