Question: Assembly Language 6. Consider the following code. The line sub esp, 8 is making space on the stack for two local integer variables. Normally when
Assembly Language

6. Consider the following code. The line sub esp, 8" is making space on the stack for two local integer variables. Normally when we modify the stack with a push or pop, we need to make sure they are "balanced". Why do we NOT need to "balance" it with a subsequent "add esp, 8" in this particular case? Why does it still work? my_function: push ebp mov ebp, esp sub esp, 8 ;do stuff... mov pop ret esp, ebp ebp
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
