This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Profiling Android native code

Hello,

I have tried to profile Android native code from an APK generated by Android Studio, but I cannot work it out.

When I used the capture functionality in Streamline, I cannot see any process but the libgatord.so.

Any idea how to profile my own Android native code in Streamline?


Any feedback would be thankful!

KuoHsin

Parents
  • Hello, 

    Assuming your device is non-root and you want to profile all the processes in the system I recommend to use the gatord from $DS5_HOME/sw/streamline/bin (either arm or arm64 version depending on your device) and put it on the device into /data/local/tmp 

    I work on Ubuntu host so I use:

    $ sudo ./adb push $DS5_HOME/sw/streamline/bin/arm/gatord  /data/local/tmp

    Then shell into the device and start gatord

    $ sudo ./adb shell

    [ now on device ] 

    albus:/ $ cd /data/local/tmp
    albus:/data/local/tmp $ ./gator &

    When I do this I can connect Streamline and see all of the processes. If I just install the streamline-daemon-app.apk on the device I just see the gatord process. 

    I don't know if this is device specific or not, but give it a try. 

    Thanks,

    Jason

Reply
  • Hello, 

    Assuming your device is non-root and you want to profile all the processes in the system I recommend to use the gatord from $DS5_HOME/sw/streamline/bin (either arm or arm64 version depending on your device) and put it on the device into /data/local/tmp 

    I work on Ubuntu host so I use:

    $ sudo ./adb push $DS5_HOME/sw/streamline/bin/arm/gatord  /data/local/tmp

    Then shell into the device and start gatord

    $ sudo ./adb shell

    [ now on device ] 

    albus:/ $ cd /data/local/tmp
    albus:/data/local/tmp $ ./gator &

    When I do this I can connect Streamline and see all of the processes. If I just install the streamline-daemon-app.apk on the device I just see the gatord process. 

    I don't know if this is device specific or not, but give it a try. 

    Thanks,

    Jason

Children