英特尔 IA32 架构中的堆栈宽度是多少?英特尔、堆栈、宽度、架构

2023-09-08 08:45:52 作者:奔跑吧暖男

对于 IA32 架构和所有类型的微处理器/微控制器,堆栈的宽度是 8 位宽.

Is the width of the stack 8 bit wide for IA32 architecture and for all types microprocessors/microcontrollers.

我目前正在阅读 http://ozark.hendrix.edu/~burch/csbsju/cs/350/handouts/x86.html 关于汇编语言.在调用"的解释中,它说堆栈指针正在减少 4,并且程序计数器被推入堆栈.这是否意味着堆栈缓冲区的宽度是 8 位宽,因为程序计数器是 32 位长?我尝试在英特尔 IA32 架构软件开发手册中找到它,但似乎无法确认.

I am currently reading http://ozark.hendrix.edu/~burch/csbsju/cs/350/handouts/x86.html about assembly language. At the explanation of "call" it says that the stack pointer is being decreased by 4 and the program counter is push into the stack. Does this mean that the width of the stack buffer is of 8bit wide because the program counter is 32 bit long? I tried finding it in the intel IA32 architecture software development manual but can't seems to confirm it.

谢谢思乡

推荐答案

在 IA32 架构中,内存以字节为单位.

In the IA32 architecture, memory is addressed in bytes.

因此,为了将另外 4 个字节放入堆栈,您需要将堆栈指针移动 4.

Hence, in order to put another 4 bytes on the stack, you need to shift your stack pointer by 4.