Question: Consider the following program for a hypothetical machine which supports 3 address format. The program has 5 instructions (11 to 15 ) and is stored

 Consider the following program for a hypothetical machine which supports 3

Consider the following program for a hypothetical machine which supports 3 address format. The program has 5 instructions (11 to 15 ) and is stored in main memory with starting memory location at 1000H. 11: ADDAX,BX,CX#AX=CX+DX 12: CMP CX, DX \#Compare CX with DX, affects the zero flag in the flag register 13: BEQ LABEL \#If CX and DX are equal, then branch to instruction pointed by LABEL 14: ADD AX, BX, BX 15: SUB BX, AX, DX Assume that the memory is byte addressable and the contents of various registers are as follows: AX=5H,BX=02H,CX=02H,DX=04H. LABEL is an offset which is equal to 01H and PC is pointing to starting address of the program stored at main memory. i. What are the contents of the registers AX,BX,CX, and DX after executing the above program? [2 Marks] ii. What is the addressing mode of the instruction 13 ? [1Mark] iii. What is value of zero flag of flag register before and after executing the instruction I2? [1 Mark]

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!