Question: Question 1. 1. Consider the program below The initial value of the stack pointer ESP = 1000 1200. What is the value of the STACK

Question 1.1. Consider the program below The initial value of the stack pointer ESP = 1000 1200. What is the value of the STACK POINTER (ESP) after the each CALL instruction and each RET instruction. INCLUDE Irvine32.inc .DATA val1 DW 78h val2 DW 40h val3 DW 5Fh .CODE Main PROC mov ax,val1 call proc1 (1) ESP=____________(AFTER the CALL) 11FC exit main ENDP proc1 PROC ;Begin Procedure nop call proc2 (2) ESP=___________(AFTER the CALL) 11F8 nop ret (3) ESP=____________(AFTER the RET) 1200 proc1 ENDP proc2 PROC ;Begin Procedure nop call proc3 (4) ESP=___________(AFTER the CALL) 11F4 nop ret (5) ESP=___________(AFTER the RET) 11FC proc2 ENDP proc3 PROC ;Begin Procedure nop nop ret (6) ESP=____________(AFTER the RET) 11F8 proc3 ENDP END

(Points : 10)
(1) 1000 11F8 (2) 1000 11FC (3) 1000 11F4 (4) 1000 1200 (5) 1000 11FC (6) 1000 11F8 (1) 1000 11FC (2) 1000 11F8 (3) 1000 1200 (4) 1000 11F4 (5) 1000 11FC (6) 1000 11F8 (1) 1000 11F8 (2) 1000 11FC (3) 1000 11F4 (4) 1000 1200 (5) 1000 11F8 (6) 1000 11FC (1) 1000 11FC (2) 1000 11F4 (3) 1000 1200 (4) 1000 11F4 (5) 1000 11F8 (6) 1000 11FC (1) 1000 11F8 (2) 1000 11FC (3) 1000 11F4 (4) 1000 1200 (5) 1000 11F8 (6) 1000 11FC

Question 2.2. After running this Assembly language program below, what will be the value in AX _____________? BX _____________? CX _____________? mov ax, AAAAh mov bx, BBBBh mov cx, CCCCh push cx push ax push bx pop ax pop cx pop bx (Points : 10)

AX=BBBB BX=CCCC CX=AAAA

AX=CCCC BX= AAAA CX=BBBB

AX=CCCC BX= BBBB CX=AAAA

AX=BBBB BX= AAAA CX=CCCC

Question 3.3. After running this Assembly language program below, give the values in AX,BX,and CX. mov bx, BBBBh mov ax, AAAAh mov cx, CCCCh push bx push cx push ax pop bx pop ax pop cx

(Points : 10)

AX=BBBB BX=CCCC CX=AAAA

AX=CCCC BX= AAAA CX=BBBB

AX=CCCC BX= BBBB CX=AAAA

AX=BBBB BX= AAAA CX=CCCC

(I believe this one may have no right answers in multiple choice)

Question 4.4. After running this Assembly language program below, give the final values in EAX, EBX, and ECX. MOV EAX, AAAAAAAA MOV EBX, BBBBBBBB MOV ECX, CCCCCCCC PUSH AX PUSH BX PUSH CX PUSH BX PUSH AX PUSH CX POP EAX POP EBX POP ECX

(Points : 10)
EAX=CCCCBBBB EBX=AAAABBBB ECX=CCCCAAAA EAX=CCCCAAAA EBX=AAAABBBB ECX=CCCCBBBB EAX=CCCCBBBB EBX=AAAABBBB ECX=CCCCBBBB EAX=AAAACCCC EBX=CCCCBBBB ECX=AAAABBBB EAX=CCCCAAAA EBX=CCCCBBBB ECX=AAAACCCC

Question 5.5. The value of ESP is 2000 00FAh. The STACK has the following values: | 2 B | 2000 00F4 | 0 0 | 2000 00F5 | 1 F | 2000 00F6 | 2 A | 2000 00F7 | F F | 2000 00F8 | 1 0 | 2000 00F9 | 5 5 | 2000 00FA <-ESP | A 7 | 2000 00FB | B 8 | 2000 00FC | 8 B | 2000 00FD | E 0 | 2000 00FE | E 2 | 2000 00FF | 0 A | 2000 0100 |_____| After the following instructions are performed, what is the value in AX and in ESP? POP AX POP AX POP AX PUSH AX (Points : 10)
AX= E0E2 ESP=2000 00FE AX=B88B ESP=2000 00FC AX=55A7 ESP=2000 00FA AX=FF10 ESP=2000 00FD AX=FF10 ESP=2000 00FC

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!