This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

SK-AM62P-LP: High CPU Usage with Android Apps

Part Number: SK-AM62P-LP
Other Parts Discussed in Thread: AM62P

Hi,

We are currently conducting performance tests on the board running AOSP 14. (https://software-dl.ti.com/processor-sdk-android/esd/AM62PX/09_01_00/docs/devices/AM62PX/android/index.html#) We are using the TouchLatency app from AOSP at /framework/base/tests/TouchLatency. When monitoring the CPU usage with top, we observe that the app itself consumes about 30~40% of a CPU at all times. We performed the same test on a previous platform with jacinto6 and noticed a consumption of about 8%.

We also conducted another test using a map application, where the idle consumption was around 1%, and the performance was poor.

Q1. Are we missing something when it comes to handling applications on Android? Is there any configuration we should be aware of?

Thank you.

Ivan Simonavicius

  • Extra information: we are currently using the automotive version.(am62p_car-userdebug)

  • Vishal,

    in reply  to your questions below

    On the touchlatency testaspp:

     Was the comparison done on same Android Versions? Jacinto6 last release was done with Android Oreo and we are currently on Android 14. They are 6 versions apart.

    Answer: J6 and Android Oreo. AM62 and Android 14 from our ti.com release

     Regarding map application:

    Can they share this app with us to try?

    answer: Free Releases — Android

  • Hi Raphael,

    Yes, just like you said, we are using Android 8 in our J6 board (we've never updated to Android 8.1) and Android 14 in the Am62p evm (Android compiled for automotive: am62p_car-userdebug). This is not straight forward comparisson because of the android versions but since we were seen slow performance in the evm we started using the J6 just as a comparison.

    To test this just like I mencioned before we used the TouchLatency app. This app is different in both versions, so we to make it a little more comparible we use the TouchLatency app from Android 8 and exported it to Android 14. This way even though we have different android versions we have the same test application.

    To test performance we used Systrace on both boards, and got the following results:

    This is the systrace of the EVM with Android 14.

    As you can see here, we've selected a time interval of 5 seconds to see how much each process was consumming.

    First of all, we can see that wall duration is also 5 seconds, therefore considering the 4 cpus, 25 % of the total processing power is being used (or 100% out of the 400% available).

    If we sum up touchlatency and surfaceflinger processes we get out of the total time: 

    (1841 ms + 1561 ms) / (4998 ms) = 68 %

    If we separate the processes we see that each one consumes:

    TouchLatency: 1841ms / 4998ms = 37%

    SurfaceFlinger: 1561ms / 4998ms = 31%

    The systrace in the J6 on the other hand gives us the following the result:

    Again, we've selected a time interval of 5 seconds.

    If we look at the wall duration here, we have 1836 ms out of 5004 ms total, that's 37% usage of total cpu. 

    If we sum up touchlatency and surfaceflinger processes we get out of the total time: 

    (632 ms + 592 ms) / (5004 ms) = 24 %

    If we separate the processes we see that each one consumes:

    TouchLatency: 632 ms / 5004 ms = 13%

    SurfaceFlinger: 592 ms / 5004 ms = 12%

    Sure, this is not  a very straight forward comparison. We are not too concerned about the J6 board in particular but we do worry that the application seem to be consuming too many resources. Also, besides this test application, we worry about performance in general. 

    I am attaching both systrace logs in case you'd like to check them. Again the one we worry most about is the evm. The J6 is just as a reference. 

    Thanks a lot for your support. Please let me know if you need any other measurements.

    Regards.

    Ivan Simonavicius.

    evm_am62p.perfetto_trace.gz

    trace_j6.zip

  • Hi Raphael, 

    We've done some new tests using the maps application.

    We are attahing a simple video where we are in Buenos Aires and we move the map around in a circle. This was done first in the evm and then in the J6 board.

    As you can see in the video, the map in the evm moves very laggy and the map in the J6 a lot smoother. 

    Again, we know the J6 has another android, we just put it for measure, but our main concern is the performance in the evm.

    Another thing to note is that not only are the android versions different but also the displays. In the J6 we are using a 1024x600 resolution display and in the evm we are using a monitor connected by HDMI with a 1920x1080 resolution. 

    Also, we are attaching of the "top" command as we were doing the test. You can see how the processors get loaded with work and the idle percentage drops.

    We would like to also measure ram throughput to see if this is what is affecting the performance. Do you know a way we can measure this?

    Please, let us know your comments.

    Regards.

    Ivan Simonavicius. 

    For confidentiality reasons, the videos are available upon request.

  • Hi Ivan,

    Sorry for delay , i will do some test and investigations in my side and i come back to you before end of week.

    Regards
    Guillaume

  • Hi Ivan,

    Because no, I don't have a special solution for you,

    hard to say if the difference is normal or not for several reasons, the first version of Android was not the same and unfortunately I cannot boot aosp Android 14 on the beagl x15 board (same soc as j6 evm) to compare.
    The second information is that J6 soc was created to be really optimized for the Android stack and it's not the same for am62x soc, it's a more generic soc and only to run Android 14, so some actions have been carried out by the processor and not by the hardware block.


    We will continue to improve performance in each release when it's possible 


    For DDR speed test with android it could be difficult but you can do it with linux release and you have some information in linux release  doc: 
    https://software-dl.ti.com/processor-sdk-linux/esd/AM62PX/09_02_01_09/exports/docs/devices/AM62PX/linux/Linux_Performance_Guide.html


    Guillaume

  • Hello, Guilherme

    doing some research, it seems that the issue could be the A53 core. Check below A Core comparison shared by Mirgor with me

    So when they compare J6 Core (A15) vs AM62P (A53) , it is aligned to what they found in the Android comparison. ..

    But they need to make sure they are properly using our dev Kit , setup and Android in order to extract the max performance from AM62P. Because if this test shows the best of the performance from AM62P, they may need to change the processor .

    If it is a GPU issue, we need to provide drivers for improving the performance. 

    If it is a CPU, how to improve the performance? Or this is a DDR4 throughput issue?

    Pls, can you propose a call so we can get togehter w Mirgor in order to make sure they are doing all the things correctly in order to extract the max peformance of our AM62P?


    Tks

    Raphael Marchi

    TI S America FAE