Vision Apps User Guide
A72 Memory Test

Introduction

This application is a quick sanity test for allocating, accessing, and freeing memory blocks from the contiguous shared memory allocator, running fully on A72 HLOS (no remote cores are involved in this test).

Description

This test does the following:

  1. In a loop which iterates 16 times:
    • Allocates 128kB block from the APP_MEM_HEAP_DDR heap (which is the cached, shared memory region in DDR that all cores have access to).
    • Queries and reports the physical address, as well as the file descriptor handle
  2. In a loop which iterates over each of the 16 buffers:
    • Performs various simple read/write accesses
  3. Reports the time duration of the full sum of operations across all buffers (this can be used to get a relative performance delta if this region has the cache turned on or off or reconfigured).
  4. Frees all the buffers.

Supported plaforms

Platform Linux x86_64 Linux+RTOS mode QNX+RTOS mode SoC
Support NO YES YES J721e

Steps to run the application on J721e EVM (Linux + RTOS mode)

  1. Build the application and related libraries as mentioned in Build Instructions for Linux+TI-RTOS mode
  2. Run the app as shown below
    cd /opt/vision_apps
    ./vx_app_arm_mem.out
  3. Output will be sent to the terminal standard output.

Steps to run the application on J721e EVM (QNX + RTOS mode)

  1. Build the application and related libraries as mentioned in Build Instructions for QNX+TI-RTOS mode
  2. Run the app as shown below
    cd /ti_fs/vision_apps
    ./vx_app_arm_mem.out
  3. Output will be sent to the terminal standard output.

Sample Output

Shown below is a example output from running this utility:

root@j7-evm:/opt/vision_apps# ./vx_app_arm_mem.out -h
APP: Init ... !!!
MEM: Init ... !!!
MEM: Initialized DMA HEAP (fd=4) !!!
MEM: Init ... Done !!!
IPC: Init ... !!!
IPC: Init ... Done !!!
REMOTE_SERVICE: Init ... !!!
REMOTE_SERVICE: Init ... Done !!!
APP: Init ... Done !!!
APP_MEM: 0: Allocated memory @ 0xffff8d730000 of size 131072 bytes
APP_MEM: 0: Translated virtual addr = 0xffff8d730000 -> phyical addr = ae000000
APP_MEM: 0: Exported dmaBufId 16 with offset 0
APP_MEM: 1: Allocated memory @ 0xffff8d710000 of size 131072 bytes
APP_MEM: 1: Translated virtual addr = 0xffff8d710000 -> phyical addr = ae020000
APP_MEM: 1: Exported dmaBufId 17 with offset 0
APP_MEM: 2: Allocated memory @ 0xffff8d6f0000 of size 131072 bytes
APP_MEM: 2: Translated virtual addr = 0xffff8d6f0000 -> phyical addr = ae040000
APP_MEM: 2: Exported dmaBufId 18 with offset 0
APP_MEM: 3: Allocated memory @ 0xffff8d6d0000 of size 131072 bytes
APP_MEM: 3: Translated virtual addr = 0xffff8d6d0000 -> phyical addr = ae060000
APP_MEM: 3: Exported dmaBufId 19 with offset 0
APP_MEM: 4: Allocated memory @ 0xffff8d6b0000 of size 131072 bytes
APP_MEM: 4: Translated virtual addr = 0xffff8d6b0000 -> phyical addr = ae080000
APP_MEM: 4: Exported dmaBufId 20 with offset 0
APP_MEM: 5: Allocated memory @ 0xffff8d690000 of size 131072 bytes
APP_MEM: 5: Translated virtual addr = 0xffff8d690000 -> phyical addr = ae0a0000
APP_MEM: 5: Exported dmaBufId 21 with offset 0
APP_MEM: 6: Allocated memory @ 0xffff8d670000 of size 131072 bytes
APP_MEM: 6: Translated virtual addr = 0xffff8d670000 -> phyical addr = ae0c0000
APP_MEM: 6: Exported dmaBufId 22 with offset 0
APP_MEM: 7: Allocated memory @ 0xffff8d650000 of size 131072 bytes
APP_MEM: 7: Translated virtual addr = 0xffff8d650000 -> phyical addr = ae0e0000
APP_MEM: 7: Exported dmaBufId 23 with offset 0
APP_MEM: 8: Allocated memory @ 0xffff8d630000 of size 131072 bytes
APP_MEM: 8: Translated virtual addr = 0xffff8d630000 -> phyical addr = ae100000
APP_MEM: 8: Exported dmaBufId 24 with offset 0
APP_MEM: 9: Allocated memory @ 0xffff8d610000 of size 131072 bytes
APP_MEM: 9: Translated virtual addr = 0xffff8d610000 -> phyical addr = ae120000
APP_MEM: 9: Exported dmaBufId 25 with offset 0
APP_MEM: 10: Allocated memory @ 0xffff8d5f0000 of size 131072 bytes
APP_MEM: 10: Translated virtual addr = 0xffff8d5f0000 -> phyical addr = ae140000
APP_MEM: 10: Exported dmaBufId 26 with offset 0
APP_MEM: 11: Allocated memory @ 0xffff8d5d0000 of size 131072 bytes
APP_MEM: 11: Translated virtual addr = 0xffff8d5d0000 -> phyical addr = ae160000
APP_MEM: 11: Exported dmaBufId 27 with offset 0
APP_MEM: 12: Allocated memory @ 0xffff8d5b0000 of size 131072 bytes
APP_MEM: 12: Translated virtual addr = 0xffff8d5b0000 -> phyical addr = ae180000
APP_MEM: 12: Exported dmaBufId 28 with offset 0
APP_MEM: 13: Allocated memory @ 0xffff8d590000 of size 131072 bytes
APP_MEM: 13: Translated virtual addr = 0xffff8d590000 -> phyical addr = ae1a0000
APP_MEM: 13: Exported dmaBufId 29 with offset 0
APP_MEM: 14: Allocated memory @ 0xffff8d570000 of size 131072 bytes
APP_MEM: 14: Translated virtual addr = 0xffff8d570000 -> phyical addr = ae1c0000
APP_MEM: 14: Exported dmaBufId 30 with offset 0
APP_MEM: 15: Allocated memory @ 0xffff8d550000 of size 131072 bytes
APP_MEM: 15: Translated virtual addr = 0xffff8d550000 -> phyical addr = ae1e0000
APP_MEM: 15: Exported dmaBufId 31 with offset 0
APP_MEM: elasped time for data processing is 2655 usecs
APP_MEM: 0: Free'ed memory @ 0xffff8d730000 of size 131072 bytes
APP_MEM: 1: Free'ed memory @ 0xffff8d710000 of size 131072 bytes
APP_MEM: 2: Free'ed memory @ 0xffff8d6f0000 of size 131072 bytes
APP_MEM: 3: Free'ed memory @ 0xffff8d6d0000 of size 131072 bytes
APP_MEM: 4: Free'ed memory @ 0xffff8d6b0000 of size 131072 bytes
APP_MEM: 5: Free'ed memory @ 0xffff8d690000 of size 131072 bytes
APP_MEM: 6: Free'ed memory @ 0xffff8d670000 of size 131072 bytes
APP_MEM: 7: Free'ed memory @ 0xffff8d650000 of size 131072 bytes
APP_MEM: 8: Free'ed memory @ 0xffff8d630000 of size 131072 bytes
APP_MEM: 9: Free'ed memory @ 0xffff8d610000 of size 131072 bytes
APP_MEM: 10: Free'ed memory @ 0xffff8d5f0000 of size 131072 bytes
APP_MEM: 11: Free'ed memory @ 0xffff8d5d0000 of size 131072 bytes
APP_MEM: 12: Free'ed memory @ 0xffff8d5b0000 of size 131072 bytes
APP_MEM: 13: Free'ed memory @ 0xffff8d590000 of size 131072 bytes
APP_MEM: 14: Free'ed memory @ 0xffff8d570000 of size 131072 bytes
APP_MEM: 15: Free'ed memory @ 0xffff8d550000 of size 131072 bytes
APP: Deinit ... !!!
REMOTE_SERVICE: Deinit ... !!!
REMOTE_SERVICE: Deinit ... Done !!!
IPC: Deinit ... !!!
IPC: DeInit ... Done !!!
MEM: Deinit ... !!!
MEM: Alloc's: 16 alloc's of 2097152 bytes
MEM: Free's : 16 free's of 2097152 bytes
MEM: Open's : 0 allocs of 0 bytes
MEM: Deinit ... Done !!!
APP: Deinit ... Done !!!