Answered step by step
Verified Expert Solution
Question
1 Approved Answer
This is a subjective question, hence you have to write your answer in the Text-Field given below. Consider the following program for a hypothetical machine
This is a subjective question, hence you have to write your answer in the Text-Field given below. Consider the following program for a hypothetical machine which supports 3 address format. The program has 5 instructions (I1 to 15 ) a 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. ADDAX,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. 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? ii. What is the addressing mode of the instruction 13 ? [1Mark] [2 Marks] iii. What is value of zero flag of flag register before and after executing the instruction I 2 ? [1 Mark]
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started