LOGBOOK

HELP

Quiz Entry - updated: 2026.07.14

What does mov (%rsp), %eax vs mov %rsp, %rax mean?

Parentheses mean "dereference" — (%rsp) reads memory at that address; without them, %rsp is just the register's value (the address itself).

# eax = value stored at address rsp points to (reads memory)
mov (%rsp), %eax

# rax = the address itself (rsp's value, no memory read)
mov %rsp, %rax
Instruction Meaning Analogy in C
mov (%rsp), %eax Read memory at rsp eax = *rsp
mov %rsp, %rax Copy the pointer itself rax = rsp
mov 8(%rsp), %eax Read memory at rsp+8 eax = *(rsp + 8)
lea 8(%rsp), %rax Compute address rsp+8 rax = rsp + 8 (no read)

This is the most fundamental distinction in assembly: parentheses = memory access, no parentheses = register-to-register.

Go deeper:

From Quiz: REVE1 / Assembly Patterns & GDB | Updated: Jul 14, 2026