Developer Guide

  • 2021.1
  • 11/03/2021
  • Public
Contents

Troubleshooting

This topic covers troubleshooting for the cache allocation library.
Problem
Possible Cause / Solution
Cache allocation library does not show performance.
Check your system configuration: Run the real-time readiness checker
tcc_rt_checker
and make sure that the real-time BIOS capabilities checkers have status RT_READY, software SRAM dependencies checkers have statuses:
Hypervisor is on
,
Current boot is RTCM
and
Real-time configuration driver exists
. Also, check that software SRAM buffers exist.
tcc_rt_checker | more
Run the following command to configure software SRAM. If the script cannot detect the CPU automatically, it will list possible supported CPUs, and you can specify the CPU model name by passing the
--cpu
option. The target system will reboot after script execution.
/usr/share/tcc_tools/scripts/setup_ssram/tcc_setup_ssram.sh enable
A
tcc_cache_init
function returns status
TCC_BUFFER_NOT_FOUND
.
The real-time configuration driver does not exist. As a result, the cache allocation library will use malloc to allocate memory. To enable the real-time configuration driver, run the following command:
/usr/share/tcc_tools/scripts/setup_ssram/control_tcc_driver.sh enable
A
tcc_cache_init
function fails with error
TCC_E_NOT_AVAILABLE
.
See the log for possible causes and solutions. For more information about logging, see Enable Log Output. One of the possible reasons for this issue is you already have called the
tcc_cache_init
function. Make sure you call the initialization function only once.
A
tcc_cache_init
function fails with error
TCC_E_ERROR
.
See the log for possible causes and solutions. For more information about logging, see Enable Log Output.
  • Log contains “Unable to set affinity:…” This means the affinity parameter is incorrect. Check that you set the correct affinity index.
  • Log contains “Unable to allocate memory for state.” This means there is a lack of memory in the system. Check that your system has a sufficient amount of memory.
  • Log contains “Unable find available config:…” This means the
    .tcc.config
    file was not found. Check that the configuration file is present and accessible.
  • Log contains “Unable to read config file…” This means the
    .tcc.config
    file was found but cannot be read. Check that the configuration file is accessible.
  • Log contains “Unable to create region_manager: ” This means there is a a lack of memory in the system. Check that your system has a sufficient amount of memory. Another possible reason is not enough software SRAM. Use the cache configurator to check that the target system has suitable software SRAM configured for your operations.
  • Log contains “Unable to create allocators_manager:…” This means there is a lack of memory in the system. Check that your system has a sufficient amount of memory.
Memory allocation functions returns
NULL
See the log for more details. For more information about logging, see Enable Log Output.
Possible reasons for
NULL
pointer:
  • Log contains “Unable to allocate cache”
    • There is not enough software SRAM. Use the cache configurator to check that target system has suitable software SRAM configured for your operations.
    • The specified latency requirement is too small. Consider using higher latency requirements for your application.
    • The buffer size in the
      .tcc.config
      file is too small. Check the
      .tcc.config
      file and adjust the buffer size accordingly.
    • Another application has allocated software SRAM so there is not enough left for your application. You can increase the buffer size in the
      .tcc.config
      file or use the cache configurator to increase the total amount of software SRAM configured for your operations.
    • If the buffer size in the
      .tcc.config
      file was increased between runs of the application calling cache allocation library, subsequent allocations may fail. To resolve this issue, reboot the system after changing the buffer size in the
      .tcc.config
      file.
  • Log contains “allocators_manager_get_alloc_by_ptr(…) failed:…”
    • Cache memory is fragmented due to multiple alloc/free operations. You can optimize cache memory usage in your application or use the cache configurator to increase the total amount of software SRAM configured for your operations.

Product and Performance Information

1

Performance varies by use, configuration and other factors. Learn more at www.Intel.com/PerformanceIndex.