Hi all ,
I was use alloc and free function to implement dynamic memory management .
But when I stress the code , the program is hung in sysbios api :HeapMem_free .
I have 2 questions .
1.Can I use alloc/ free to do dynamic memory management or need to use HeapMem_alloc/HeapMem_free
2.Can you provide some hint why the program is in follow while loop ?
sysbios version : bios_6_35_01_29
Here is the hang area
/* Go down freelist and find right place for buf */ while (nextHeader != NULL && nextHeader < newHeader) { /* Make sure the addr is not in this free block */ Assert_isTrue(((UArg)newHeader >= (UArg)nextHeader + nextHeader->size), HeapMem_A_invalidFree); curHeader = nextHeader; nextHeader = nextHeader->next; }