Using the stack pointer is fine. He always points to the stack in the end. It's a little difficult to track offsets from the stack pointer to function arguments if the function has any push or pop commands. And it's really hard to move the stack back to the debugger when there is no pointer to the frame.
Using a frame pointer makes it easier for the debugger and compiler writer to work, but it is not necessary to have one.
Setting the frame pointer takes an instruction, and it uses a register that could potentially be used for other purposes. Therefore, using a stack pointer is a general method for optimizing code. Microsoft compilers even have a name for this optimization, they call it Frame Pointer Failure
source share