所以,在这个函数中,我们使用了回链指针、链接寄存器保存区和一个本地变量。
So, in this function, we are using the back chain pointer, the link register save area, and one local variable.
本地变量空间用作该函数的通用存储空间,寄存器保存区用于保存函数所使用的非可变寄存器的值。
The local variable space is used as a general storage area for the function, and the register save area is used to save the values of non-volatile registers that the function USES.
例如,通过调用一个可以为SESSION_USER特殊寄存器提供值的函数来设置变量,使用它取回当前用户的部门编号。
For example, a variable could be set by invoking a function that supplies the value of the SESSION_USER special register to fetch the department number for the current user.
在生命范围之外,变量不再被使用,是死的,它的寄存器可以供其他变量使用,这样,编译器就可以安排更多的变量到寄存器当中。
In between live ranges, the value of a variable is not needed: it is dead, so its register can be used for other variables, allowing the compiler to allocate more variables to registers.
如果一个函数要频繁的使用全局变量,我们可以使用局部变量,作为全局变量的拷贝,这样就可以使用寄存器了。
If a function USES global variables heavily, it is beneficial to copy those global variables into local variables so that they can be assigned to registers.
在这种策略中,我们将采用与策略1中相同的方法来访问设备的寄存器,也就是使用本地寄存器变量。
In this strategy, you'll access the device's register the same way as in strategy 1 — using local register variables.
使用关键字register修饰最经常使用的变量:告诉编译器这个变量将会被经常用到,要求编译器使用非常高的优先级将此变量分配到寄存器中。
Using register for frequently-used variables: this tells the compiler that the register variable is going to be frequently used, so it should be allocated to a register with a very high priority.
最通常的分析是数据依存性分析,它用来确定指令使用的变量(寄存器或内存位置)是否被另一条指令修改。
The most common analysis is data dependence analysis, which is to determine the instructions that use the variable (register or memory location) modified by another instruction.
最通常的分析是数据依存性分析,它用来确定指令使用的变量(寄存器或内存位置)是否被另一条指令修改。
The most common analysis is data dependence analysis, which is to determine the instructions that use the variable (register or memory location) modified by another instruction.
应用推荐