What is the role of stack in a microprocessor?

后端 未结 10 858
-上瘾入骨i
-上瘾入骨i 2020-12-10 08:34

What is the role of stack in a microprocessor?

10条回答
  •  Happy的楠姐
    2020-12-10 08:37

    Just to add to some of these answers, some lower-end micros such as the PIC line have a hardware callstack, which means it can not be dynamically allocated as it is in hardware.

    The implications of this are that you can only go so many function calls deep before you run out of stack; this is true of software also of course, but often the hardware based stack can be very limiting, and can require you to rethink your program in order to 'flatten' out your function calls.

提交回复
热议问题