Based on this question, it seems that third-party apps are by default non-debuggable. It is mentioned, however, that the device needs to have a non-release version of android. I have purchased a Qualcomm development board that has a userdebug build on it. The only package that is debuggable is the telemetry service package from Qualcomm.
Are there any alternatives for other packages? How could I start a capture and get statistics for other programs like Geekbench and Spotify?
Thanks.
For a development board with root access you can make a system-wide profile.
https://developer.arm.com/documentation/101813/0800/System-profiling-on-an-Android-device/Profile-your-system?lang=en
For a Qualcomm device you will only get CPU profiling support.
HTH, Pete
First off, thanks for the reply Peter.
I've set up my system and the board based on the link you posted. I have some questions based on that.
1) Is the --allow-command basically mutually exclusive with most other command line options (e.g., --app, --android-pkg)?
2) Can all the options in Streamline's UI (Command, Working directory, User name) be given through the command line as well? Are there any options that are accessible only via one of the two methods?
3) I am interested in profiling Geekbench and Spotify for example. Is there any specific way to automate that process? Starting the pkg does not start the benchmark itself (for geekbench) or does nothing for spotify, making the profiling useless / null.
Thanks,
Victor
The --allow-command option is only really relevant for Linux, unless you want to start a raw native binary rather than an Android application. Ditto for the options in part 2 of your answer - they are not supported by Android applications.
Once you have started and connected to gator in system-wide mode (not connected to any specific application), you can automate the application using standard Android shell commands using any external shell scripting environment ("adb shell am start ...", etc). How to automate specific activities is going to be entirely application specific, so can't help you there.
If I understand correctly the order of operations:
1) Load gatord to the device and start it in system wide mode.
2) Start the application via adb
3) Start capture on Streamline
Some questions:
1) Would starting the application via the Android's GUI make any difference compared to adb shell?
2) Is there any way to make Streamline automatically start the capture when the application starts running or does this step always has to be done manually?
3) Are these complications basically the by-product of the application not being debuggable? Because it seems like that with a debuggable application all these steps are taken care of automatically by Streamline.
If you pick the right activity it shouldn't, as far as I know.
It's a system-wide capture, so in this mode it has no concept of a single "application". You'll need to start manually (but you can start the capture before the application starts).
The current method the Streamline GUI uses only works for debuggable applications. It's on our roadmap to add GUI support for non-debuggable applications on Eng and UserDebug builds of Android, but it's not supported yet.
Cheers, Pete