Understand and monitor the stack for system reliability

all-you-need-to-know...jpg

Nov 2, 2021

The stack is a fixed block of continuous memory and has to be allocated statically by the developer. It can contain interrupt contexts and local data like variables and parameters for C/C++ functions, which are not stored in registers among other information. The main advantage of stack is that functions in different parts of the application can share the same memory space to store their data.

A proper configuration of the stack is essential to your system stability and reliability. If the stack size is too small, an overflow situation could occur. On the other hand, setting the stack size too large means a waste of RAM resource, which could be very limited in MCU-based embedded systems. The handling of the stack is one of the major challenges for embedded software developers. A good practice is to employ static stack usage analysis and runtime stack usage tracking.

On top, it is recommended to take advantage of guarding against stack overflow with the use of stack canaries (stack protection).

Watch on-demand webinar

If you are interested in learning more, watch our on-demand webinar.

죄송하지만, 이 콘텐츠는 한국어로 제공되지 않습니다.

당사 웹 사이트 중 한국어가 제공되는 않는 페이지는 기본적으로 영어로 제공됩니다. 보다 정확한 정보를 위해 영어로 제공되는 글로벌 웹 사이트를 방문하실 것을 권장합니다.

죄송하지만, 당사 사이트에서는 Internet Explorer를 지원하지 않습니다.보다 편안한 사이트를 위해 Chrome, Edge, Firefox 등과 같은 최신 브라우저를 사용해 주시길 부탁드립니다.