Assembly
x86 and amd64 instruction reference
Registers & Function Call
Instructions & Note
MOV
mov ebp, 0x1000
mov eax, ebp
; move the value 0x1000 in eax
Dereferencing []
mov eax, [ebp]
; if ebp = 0x1000, move the value in memory 0x1000 in eax
mov eax, [ebp-0x8]
; if ebp = 0x1000, move the value in memory 0x0FF8 (0x1000 - 0x8) in eax
LEA
lea eax, [ebp-0x8]
; if ebp = 0x1000, move the value 0x0FF8 (0x1000 - 0x8) in eax
; get a pointer to a memory region
ADD
add eax, ebx
; add ebx in eax (eax = eax + ebx)
SUB
sub eax, ebx
; sub ebx from eax (eax = eax - ebx)
PUSH
push eax
; add eax on the stack (decrease esp)
POP
pop eax
; remove top element from the stack and store it in eax (increase esp)
CMP
cmp eax, ebx
; sub ebx from eax and set FLAGs accordingly
JMP
label:
jmp 0x1000
jmp eax
jmp [eax]
jmp label
; set next instruction to address eax
JE/JNE/JG/JL/JZ/JNZ
je label
; if equals
jne label
; if not equals
jg label
; if greater
jl label
; if less
jz label
; if zero
jnz label
; if not zero
XOR/AND/OR
xor eax, ebx
; eax = eax XOR ebx
and eax, ebx
; eax = eax AND ebx
or eax, ebx
; eax = eax OR ebx
Last updated
Was this helpful?