【发布时间】:2015-03-05 11:20:11
【问题描述】:
我需要在程序集中设置零标志,但它不应该更改任何其他标志。 所以我想做 pushf,把它弹出到 eax 但我不知道如何给标志 reg 它的新值。 我能想到的:
pushf
pop eax,
or eax , 000..1..00 // set the location of zf to 1
从这里我不知道该怎么做。
【问题讨论】:
-
有一条
popf指令。 -
但它会恢复寄存器的原始值,不是吗?
-
它将堆栈中的任何内容弹出到标志寄存器中。