base pointer (rbp)

What’s the point of it if we have stack pointer?

Well if we push stuff onto the stack, stack pointer moves.

If we wanted to reference function arguments for instance, we can’t use the stack pointer as is. We need to add an offset everytime it moves.

The base pointer on the other hand doesn’t change its position, so we can reference it statically!