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.

DSP algorithm heap for the DM8148

I have successfully allocated more DSP algorithm heap on the DM8148 EVM 512 Meg version by modifying the linker command file c6run.cmd like this
MEMORY
{
OCMC (RWX) :
org = 0x40300000, len = 0x20000
DSPMEM :
org = 0x98000000, len = 0x2000000
SR0 :
org = 0x9f700000, len = 0x200000
SR1 :
org = 0x9a100000, len = 0x100000
}

However if I try to get more memory like this

MEMORY
{
OCMC (RWX) :
org = 0x40300000, len = 0x20000
DSPMEM :
org = 0x88c00000, len = 0x2500000
SR0 :
org = 0x9f700000, len = 0x200000
SR1
org = 0x9a100000, len = 0x100000
}

The algorithm crashes.  What's the correct way to get ~40 Meg of heap for the DSP algorithm? 

  • I found this link http://processors.wiki.ti.com/index.php/EZSDK_Memory_Map#DSP_for_OMX
    which guided me to a spreadsheet
    http://processors.wiki.ti.com/images/e/e3/EZSDK_MemCfg.zip
    that helps to map out the memory
    However the starting memory address for heap in the spreadsheet

    DSP_ALG_HEAP 20 1400000 98000000

    is different from the starting address in the linker command file.  Perhaps the memory map Spreadsheet is outdated? 

    MEMORY
    {
    OCMC (RWX) :
    org = 0x40300000, len = 0x20000
    DSPMEM :
    org = 0x98c00000, len = 0x1500000
    SR0 :
    org = 0x9f700000, len = 0x200000
    SR1 :
    org = 0x9a100000, len = 0x100000
    }

  • Michael,

               Which DSP example you are using, Just for your info there are many DSP examples available in EZSDK.It is possible that few DSP examples do not stick to this memory map, so they are meant to be running with out the other M3 binaries. If you want them to run together with other M3s, please use the memory map defined in above wiki & .xls

              This .xls and http://processors.wiki.ti.com/index.php/EZSDK_Memory_Map wiki page explains the memory map to be used when you develop any DSP based application.

             The easier way to get more memory for DSP is to reduce the memory allocation to Linux and assign them to DSP appropriately and use the above docs for calculation. In case your memory requirement caters to M3 memory regions, then you need to modify them appropriately and rebuild as per the procedure explained in http://processors.wiki.ti.com/index.php/EZSDK_Memory_Map

    Thanks & Regards,

    Velan

  • I'm not using a DSP example.  I have written my own algorithm code for the DSP which I have gotten to run with less heap but now I need more. 

    Thanks for the response.  I did read the wiki you mentioned in fact I mentioned that in my post.
    That's where I got the spreadsheet.  What I'm asking is how the map in the spreadsheet corresponds to the linker command file. 
    As I mentioned the easy way to get more DSP algorithm heap is to modify this linker command file as I have shown. 
    However I ran into a problem when I tried to get more heap memory.

    So again, can you explain how the linker command file relates to the memory map in the spreadsheet and this wiki?

  • Did you mean to say that I should not be modfying the linker command file directly although that seems to hae worked until now?

  • You modified linker command file as below should work fine, I see problem only with memory allocated for linux, can you share the bootargs

    org = 0x9a100000, len = 0x100000

    DSPMEM :
    org = 0x88c00000, len = 0x2500000

    To answer other question

    DSPMEM ==> sum of DSP_DATA, DSP_CODE, Since you have not defined heap explicitly your heap might get allocated from here.

    SR0 ==> IPC_SR_COMMON

    SR1 ==> You should not have this, why do you have it.

    For easy way, can you run the DSP app without running M3 dependent (do not load M3) applications, this way there is no memory overlap region in the system.

    Thanks & Regards

    Velan