The Stack & Calling Conventions
Go deeper into how functions pass arguments, return values, and manage the stack frame, the knowledge that makes disassembled code readable.
Beyond a Single Call
You can read basic x86/x64 instructions and follow control flow. To truly understand function calls you must know the stack and calling conventions.
These rules govern how arguments arrive and how cleanup happens.
What the Stack Is
The stack is a region of memory that grows downward (toward lower addresses). It stores return addresses, saved registers, and local variables.
pushdecrements RSP and writespopreads and increments RSP
push rax ; rsp -= 8, [rsp] = rax
pop rbx ; rbx = [rsp], rsp += 8All lessons in this course
- x86/x64 Assembly Basics
- Registers and Memory Operations
- Control Flow and Function Calls
- The Stack & Calling Conventions