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.

MEM_check



Hi

I have an existing code-base in which the API MEM_check is used. I have tried searching for the usage of the API but cannot find it anywhere.

Could someone post the functionality of the API?

-Dushyant

  • Hi Dushyant --

    MEM_check() does some basic validation of the free list managed by the MEM module.  It prints and error message using SYS_printf() if it detects a problem.  It checks to make sure that the list is in address-order and also verifies that the base address for each block is at an even address.   It also prints the max length of the free list if it is longer than the last time it was called. 

    MEM_check() returns '0' if no problems were found.  Non-zero otherwise.

    MEM_check() was intended for internal use as part of the test framework for DSP/BIOS.  I'm not sure how the author of the code you are working with knew about this API.  They might have contacted TI for some support sometime along the way and someone suggested that they use this API.  In any case, it is not documented or included in the <mem.h> header file.

    Regards,
    -Karl-

  • Is there a API available in Sys/Bios which performs similar functionality?

    -Dushyant

     

  • Dushyant,

    Unfortunately this functionality is not available in SYS/BIOS.

    However, SYS/BIOS is an open source software product.  You are free to study the code and add such an API if so desired.

    Steve