What happens when you use a memory override prefix but all the operands are registers?

大兔子大兔子 提交于 2019-12-20 02:22:11

问题


What happens when you use a memory override prefix but all the operands are registers?

So, let's say you code mov eax, ebx or add eax, ebxand the default is 32-bit but you use a 67h override.

How does the processor handle that situation?


回答1:


The Intel Software Developer's Manual*, volume 2, section 2.1, details the behavior of each instruction prefix. It says use of the address-size prefix (67h) with an instruction that doesn't have a memory operand is reserved and may cause unpredictable behavior.

The operand-size prefix (66h) may be used to switch between 16- and 32-bit operand sizes and also as a mandatory prefix with certain SSE2/SSE3/SSSE3/SSE4 instructions. Other use is reserved and may cause unpredictable behavior.

The segment override prefixes are reserved with any branch instruction.

* https://software.intel.com/en-us/articles/intel-sdm



来源:https://stackoverflow.com/questions/46188388/what-happens-when-you-use-a-memory-override-prefix-but-all-the-operands-are-regi

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!