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.

CCS/TMS570LS3137: How to chage stack size

Part Number: TMS570LS3137

Tool/software: Code Composer Studio

Hi

     Customer would like to increase stack size. 

1) In CCS there are two  position relay to stack size, as below picture one is in cmd file another one is in Project Properties -> Build -> ARM Linker -> Basic option -> Set C system stack size.

    I don't know which one is the right position to set stack pointer size.

2) What is the maximum stack size? 

Thanks

     

    


   

  • Hi Jeff,

    1. --stack_size=0x800 is defined in CCS linker options (your 2nd picture)
    2. The memory section used for stack is defined in cmd file (your 1st picture). This region should be >= --stack_size defined in CCS linker options
    3. The starting address of stack in cmd file should be consistent with the starting address defined in sys_core.asm:

    userSp .word 0x08000000+0x00001000
    svcSp .word 0x08000000+0x00001000+0x00000100
    fiqSp .word 0x08000000+0x00001000+0x00000100+0x00000100
    irqSp .word 0x08000000+0x00001000+0x00000100+0x00000100+0x00000100
    abortSp .word 0x08000000+0x00001000+0x00000100+0x00000100+0x00000100+0x00000100
    undefSp .word 0x08000000+0x00001000+0x00000100+0x00000100+0x00000100+0x00000100+0x00000100