8
votes

I've always wondered what the difference between

mov esi,eax

and

mov [esi],eax

was.

Any help is appreciated.

1

1 Answers

16
votes

mov esi,eax writes the contents of register eax to register esi.

mov [esi],eax writes the contents of register eax to the memory address specified by register esi (for example, if esi contained the value 0x1234, eax would be written to address 0x1234).