So, heres how I interpet the stack, let me know what is wrong/right. This is for any sort of assembly.
So it goes:
Directives
Bytecode with instructions
A 'stack' of added bytes added to the end of the instructions (these are set to 0 if I recall correctly, doesnt matter)
With this stack, we have a stack pointer that will look at the exact point of the most recenetly pushed byte. Then we'll have a stack base that is the very bottom of the stack (this value never changes). So if the length of the instructions and directives is 5000 bytes, the stack base will be the 50001st byte. If the stack is an extra 2500 bytes, then the stack limit will be byte 7500.
Let me know if thats correct. Now for the question:
What exactly is the frame or frame pointer? I know a frame is a frame of the stack (so a specific portion of the stack), but that is really confusing to me. How is a frame set? why do we need one? Is the frame pointer the exact byte position of where that frame is? If so, how do we know how long it is?
I looked up a few articles on frames and frame pointers and got many confusing answers. Wondering if we could take about it in plain english, haha.