What does lea 0xY(%esp), %esi do?

爱⌒轻易说出口 提交于 2019-12-13 08:55:55

问题


I dont understand what this code will do

lea   0x13(%esp), %esi

%esp is a stack pointer, %esi is index register.

Is 0x13 offset?


回答1:


I'm used to the Intel syntax, so I believe this is what's happening:

lea esi, [esp+13h]

Say esp is 0x18000 - the result of this operation will be 0x18013, since you're not actually accessing any memory with lea.

Again, I only have experience with the Intel syntax, so my answer may be incorrect. Hopefully this has helped you!



来源:https://stackoverflow.com/questions/23869183/what-does-lea-0xyesp-esi-do

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