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.

AM572x GP EVM ALSA Latency Performance

Hello,

I'm interested in an extremely low-latency embedded audio solution.  The AM57XX boards look awesome, but I can't seem to find any specs on the latency of the audio drivers.  I've found the following table:

processors.wiki.ti.com/.../Processor_SDK_Linux_Kernel_Performance_Guide

However, I'm not sure how to deduce the latency from this, or if that information is somehow related through the table at all.

I wonder if it's possible for a dev or someone else with the same board to run an alsa loopback test similar to here:

e2e.ti.com/.../428628

But with rate 96kHz, frame size 96 samples, single channel, and desired latency of <= 5ms.  At the highest level, I would like to see if the AM57XX is capable of < 5ms round-trip latency, and what impact it has on the CPU load.  Even a general latency to CPU load measurement is fine enough to get started.

I would also be interested on this might theoretically change, or actually will change with an RTOS, or if there are alternative solutions such as grabbing PCM data before it hits the ARM similar to Snapdragon platforms, etc (I'm not extremely familiar with the AM57X architecture at this point.

Sorry for the extremely general question.  This platform looks really amazing, but I just need a little more information.


  • Hi,

    I will forward this to the software team. They will respond here.
  • latency_test.zip

    Hi Justyn,

    I'm attaching the results & also the compiled latency test binary, with which I did the tests. The latency test is cross compiled against the latest SKD03.01.00.06 (kernel 4.4.19).

    Best Regards,

    Yordan

  • Thank you. I assume the "total latency" I should be looking at is the 2666.667us, 2.666667ms value, which would fit my purposes perfectly. I was wondering if you had some sort of CPU load figure? It doesn't have to be exact, but just like a "top" while the loopback is running would be nice.

    Again, it doesn't have to be exact, but I want to know if this is a process that takes .5% of the CPU cycles, or 50%.
  • Hi Justyn,

    I am starting the test for 100s:

    root@am57xx-evm:~# ./latency -P hw:0,0 -C hw:0,0 -r 96000 -m 4 -M 4 -p -s 100 > log.txt &

    Then execute top & the results are:

    Of course during the 100s latency test the top command refreshes its output, but the figures revolve around 2.3% and 2.6%: 

    root@am57xx-evm:~# ./latency -P hw:0,0 -C hw:0,0 -r 96000 -m 4 -M 4 -p -s 100 > log.txt &
    [1] 1207
    root@am57xx-evm:~# top | grep latency
    1207    root     rt    0     2956    1764    1604    S    2.6    0.1     0:00.21     latency
    1207    root     rt    0     2956    1764    1604    S    2.6    0.1     0:00.29     latency
    1207    root     rt    0     2956    1764    1604    S    2.3    0.1     0:00.36     latency
    1207    root     rt    0     2956    1764    1604    S    2.6    0.1     0:00.44     latency
    1207    root     rt    0     2956    1764    1604    S    2.3    0.1     0:00.51     latency
    1207    root     rt    0     2956    1764    1604    S    2.6    0.1     0:00.59     latency
    1207    root     rt    0     2956    1764    1604    S    2.6    0.1     0:00.67     latency
    1207    root     rt    0     2956    1764    1604    S    2.3    0.1     0:00.74     latency
    1207    root     rt    0     2956    1764    1604    S    2.6    0.1     0:00.82     latency
    1207    root     rt    0     2956    1764    1604    S    2.6    0.1     0:00.90     latency
    1207    root     rt    0     2956    1764    1604    S    2.3    0.1     0:00.97     latency
    1207    root     rt    0     2956    1764    1604    S    2.6    0.1     0:01.05     latency
    1207    root     rt    0     2956    1764    1604    S    2.3    0.1     0:01.12     latency
    1207    root     rt    0     2956    1764    1604    S    2.6    0.1     0:01.20     latency
    1207    root     rt    0     2956    1764    1604    S    2.6    0.1     0:01.28     latency
    1207    root     rt    0     2956    1764    1604    S    2.3    0.1     0:01.35     latency

    Hope this helps. 

    Best Regards, 
    Yordan

  • That is exactly what I'm looking for.  Thank you, your help has been top-notch, and the board seems perfect.