Skip to content
Free public beta until December 4, 2026: every course is open, no card needed. After that, the first chapter of each course stays free and full access is a one-time $39 ($19 for up to 100 founding members chosen for helpful feedback). Your progress is kept. How the beta works

PC-relative addressing

Naming a piece of data by its distance from the current instruction, so the program works wherever it is loaded in memory.

PC-relative addressing forms an address as the program counter plus a constant fixed at link time; x86-64 writes [rip + symbol] (relative to the next instruction), ARM64 uses adrp plus add, RISC-V auipc plus addi.

Examples

  • lea rax, [rip + table] finds table by its distance from the next instruction, so it works wherever the program is loaded.

Read the full section →