Tool/software: Code Composer Studio
Hii All,
I am working on messageQ communication between ARM to DSP. I am creating two tasks in DSP, in first task MessageQ_get is placed in while loop. In second task I have MessageQ_free, messageQ_alloc and MessageQ_put. Dsp load i am building with the CCS v6.
ARM code has one thread, inside the thread i have messageQ_get and messageQ_put and ARM load is building in linux terminal.
I have declared messageQ variable as follow
#define MSGQ_ALLOC_SIZE 16
MessageQ_Msg aAllocBuf[MSGQ_ALLOC_SIZE];
NOTE: I have allocated a 512 bytes of heap for messages.
I have a buffer of 16 which is used to allocate, put and free the message. When I am trying to allocate for aAllocBuf [0] , aAllocBuf [1] and so till aAllocBuf [15] it is allocating with the same address for all the indexes of a buffer. After four allocations, I am freeing the buffer and it is freeing the allocated memory for some random messages and DSP core0 is crashing by throwing an error as follow
ti.sysbios.heaps.HeapBuf: line 297: assertion failure: Cannot call HeapBuf_free when no blocks have been allocated
xdc.runtime.Error.raise: terminating execution
ccsv6
bios_6_41_01_36
ipc_3_36_01_11
xdctools_3_31_00_24_core
TCI6638K2K platform
windows10
Thanks n Regards
Mohan