在指令序列中使用仅引用一次的局部变量。
Using a local variable declared inside a sequence of instructions that is referenced only once.
如果对代码进行向量化,由于您正在将这些值当作字节进行处理,这意味着每条指令都要一次操作 16 个值!
If you vectorize this code, since you are treating the values as bytes, that means that each instruction will operate on 16 values at once!
这提供了一个很好的机会,可以只执行一次操作,而不必每次都执行相关指令。
This offers a great opportunity to do things once only rather than doing them each time the relevant instructions are executed.
Well at most, I'm going to execute each instruction once. All right?
那么至多的话,我会执行,每个指令一次,对不对?
Remember last time, I said that there's different kinds of complexity in our code, and I suggested for simple branching programs, the amount of time it takes to run that program is, in essence, bounded by the number of instructions, because you only execute each instruction at most once.
但是这里有个很重要的点,记得上节课,我提过在我们的代码中,有不同种类的复杂度,而且我还说了对于简单的分支程序,运行这种程序需要的总体时间,大体上,是和指令的数目相关的,因为每个指令只会被执行最多一次。
应用推荐