What do parentheses surrounding a register mean?

Viewed 2131

What exactly is the difference resulting from a register being surrounded in parentheses in an operation?

For example:

movl (%edx), %eax

versus

movl %edx, %eax

Thank you in advance!

2 Answers

Means "the memory at the address that's stored in the register".

Move from one register to another, eax to edx edx to eax.

movl %edx, %eax

Move from eax to memory address contained in edx.
Move from memory address contained in edx to eax.

movl (%edx), %eax

How you could find out by youself: search for 'x86 assembly syntax' This page was one of the results.

Related