Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

9. (M/C) After the following set of operations: push 100 push 200 push 300 pop e

ID: 3543735 • Letter: 9

Question

                    9. (M/C) After the following set of operations:                 

                    push 100                 

                    push 200                 

                    push 300                 

                    pop eax                 

                    push 400                 

                    EAX will contain_________.                 

                    a. 400 c. 200                 

                    b. 300 d. 100                 

                    (M/C) After the set of operations in question 9, the top of the stack will contain________.                 

                    a. 400 c. 200                 

                    b. 300 d. 100                 

                    
                

                    11. (M/C) If the address in ESP is 050H and we perform the following operations:                 

                    pop AX                 

                    pop EBX                 

                    the contents of ESP will be ___________.                 

                    a. 058H c. 052H                 

                    b. 056H d. 048H                 

                    12. (M/C) A stack frame may contain ______.                 

                    a. parameters c. local variables                 

                    b. return address d. all of the above                 

                    13. (M/C) If the calling procedure passes a variable number of parameters, the cleanup must be                     done by the .                 

                    a. Calling procedure c. either of the above                 

                    b. Called procedure d. neither of the above                 

                    14. (M/C) As an auxiliary pointer to a stack frame, we generally use .                 

                    a. ESP c. ESI or EDI                 

                    b. EBX d. EBP                 

                    15. (M/C) The 2 instructions which facilitate allocation and release of stack frames are                     .                 

                    a. call and ret c. push and pop                 

                    b. enter and leave d. none of the above                 

Explanation / Answer

9 EAX will contain_________.400,200,100
10 the top of the stack will contain________a. 400
11 the contents of ESP will be ___________.d 048H
12 A stack frame may contain ______d. all of the above
13 If the calling procedure passes a variable number of parameters, the cleanup must be done by the c. either of the above //it depend on calling convention
14 As an auxiliary pointer to a stack frame, we generally use .b. EBX
15. (M/C) The 2 instructions which facilitate allocation and release of stack frames are .c. push and pop