Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
AT&T 汇编中的含义是什么(register1, register2, 4)?
(register1, register2, 4)
例如:
cmp %eax, (%esi, %ebx, 4)
完整的 AT&T 基址/索引寄存器语法是:
offset(base, index, multiplier)
你的offset领域是0,所以你只是有(base, index, multiplier)一部分。在您的情况下,您将eax寄存器的内容与位于的 32 位值进行比较esi + (ebx * 4)。
offset
0
(base, index, multiplier)
eax
esi + (ebx * 4)
在您可能更熟悉的 Intel 语法中,可以这样写:
cmp [ebx*4 + esi], eax