Then you restore the stack frame and return.
之后再恢复堆栈框架并返回。
The prologue sets up the stack frame for the function.
序言为函数设置堆栈框架。
For right now, just know that it sets up the stack frame.
就目前而言,只需知道它将设置堆栈框架就可以了。
LR_OFFSET is the offset into the stack frame of the return address.
LR_OFFSET是返回地址的堆栈框架的偏移量。
The first part of the stack frame is the non-volatile register save area.
堆栈帧的第一个部分是非易失性寄存器保存区。
You can construct the object on the heap or on the stack frame of a function.
可以在堆或函数的堆栈帧上构造对象。
If the stack frame is active, this address is the next instruction to execute.
如果堆栈帧处于活动状态,则此地址是要执行的下一条指令。
It displays the stack frame for the suspended threads for each target you're debugging.
它可以显示每个调试目标中挂起线程的堆栈框架。
The computer refers to this point as the return address and keeps track of it in the stack frame.
计算机引用这一点作为返回地址,会在堆栈框架中跟踪它。
The final item in the stack frame is a pointer to the previous stack frame, often called the back pointer.
堆栈帧中的最后一个条目是一个指向前一堆栈帧的指针,通常被称为后向指针(back pointer)。
You load register 3 with the return value and perform the function epilogue to restore the stack frame and return.
需要用返回值加载寄存器3并执行函数尾声(epilogue)来恢复堆栈框架并返回。
If the stack frame is not active, this address is the next instruction to execute when the stack frame is reactivated.
如果堆栈帧未处于活动状态,则此地址是在重新激活堆栈帧时要执行的下一条指令。
If this stack frame is not active, the offset is the address of the next instruction to be executed when the stack frame is reactivated.
如果此堆栈帧处于非活动状态,则该偏移量将是在重新激活该堆栈帧后要执行的下一条指令的地址。
In practice this is easy; just don't write code that does low-level manipulations of the stack frame or makes assumptions about the stack layout.
这在实践上是很容易的;只要不编写对堆栈桢执行低级操作或对堆栈的布局作假设的代码就行了。
However, since the base case doesn't call any other functions, you don't need to load the link register from the stack frame — the value is still there.
但由于基线条件并不调用任何其他函数,所以无需从堆栈框架加载链接寄存器——值还在原处。
The epilogue will be discussed in the analysis of the factorial code, but it basically just takes down the stack frame and returns to the previous function.
该段代码的尾声(epilogue)将在分析factorial 代码时再作讨论,但总的来说,它的作用是结束堆栈框架并返回到先前的函数。
The most difficult part is determining the different offsets of the different parts of the stack frame, knowing where each piece should go, and what size it should be.
最困难的部分是确定堆栈帧不同部分的不同偏移量,了解每个部分应该放到哪里,以及大小应该是多少。
Functions create the stack frame during the beginning of the function (called the function prologue) and tear it down at the end of a function (called the function epilogue).
函数在函数开始过程中(称为函数序言(function prologue))创建堆栈帧,并在函数结束时(称为函数尾声(functionepilogue))销毁它。
Next, the current stack frame pointer is stored as the back pointer for the next stack frame, even though you haven't established the stack frame yet (this is done through negative offsets).
接下来,当前堆栈框架指针会被存储为指向下一个堆栈框架的后向指针,虽然尚未建立堆栈框架(这是通过负的偏移量实现的)。
This mechanism is used to resolve resource-name conflicts: if two library JAR files define a resource with the same global name, the local names will be used based on the stack-frame of the caller.
用来解析资源名称冲突的机制是:如果两个库jar文件都用相同的全局名称定义一个资源,那么则根据调用程序的堆栈帧来采用局部名称。
This mechanism is used to resolve resource-name conflicts: if two library JAR files define a resource with the same global name, the local names will be used based on the stack-frame of the caller.
用来解析资源名称冲突的机制是:如果两个库jar文件都用相同的全局名称定义一个资源,那么则根据调用程序的堆栈帧来采用局部名称。
应用推荐