Real Program · Real Disassembly · Real Addresses

Stack & Heap, For Realclang -g -O0 · x86-64 Mach-O

Every line in the three panels below is copied from an actual compile-and-run of playground.c: clang -g -O0 -o playground playground.c, disassembled with llvm-objdump -d --x86-asm-syntax=intel, then run once to capture real addresses. Nothing here is illustrative.

Step 1 / 1
...
Loading...
RSP-
RBP-
RAX-
RDI-
H-TOP-
playground.creal source, unedited
x86-64 Disassemblyreal llvm-objdump, Intel syntax
Process Memory Frameone real address space, high → low
main() frame
function_a() frame + Block A (its own heap alloc)
function_b() frame + Block B (relayed to main via out-param)
function_c() frame + Block C
Verified from the real run: rbp(function_a) = 0x...e830 rbp(function_c) = 0x...e830 — identical, frame genuinely reused Block A 0x600003c401c0 vs Block B 0x600002b44050 — different malloc zones entirely Block B ...44050 → Block C ...44060 — same zone, later block is +16 higher
What’s Actually Happening
-
What’s happening
-
CPU & memory
-
Real takeaway
-