Other Parts Discussed in Thread: HALCOGEN
Hello,
I want to implement and test stack overflow.
What I need to do?
please help.
Regards,
Rohini.
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.
Hello,
I want to implement and test stack overflow.
What I need to do?
please help.
Regards,
Rohini.
Hi Rohini,
Instead of implementing separate algorithm you can easily find amount of stack used by each function in CCS studio itself.

In CCS there is a window called "Stack Usage", which will show the stack utilized by each function.
Ignore the colors here there is a bug in colors
(+) CCS/TMS320F280049: How Stack Usage of CCS judge for making color bar(Yellow, green and so on) - C2000 microcontrollers forum - C2000︎ microcontrollers - TI E2E support forums
But you can verify the maximum stack utilized function values with HALCoGen configured values to find out stack overflow

For example in above case gioHighLevelInterrupt and gioLowLevelInterrupt IRQ interrupt functions consumes 112 bytes of stack and for IRQ we configured 0x100(256bytes) of stack in HALCoGen so which is 43% of allocated stack so no overflow issues.
similarly for normal functions(Nither IRQ's or FIQ's) you can compare value with user stack length.
--
Thanks & Regards,
Jagadish.