Question: 5 . . . . . Consider the following pseudo assembly code for computing cab, Assume that a , b , and care assigned to

5.....Consider the following pseudo assembly code for
computing cab, Assume that a, b, and care assigned to consecutive memory "words" (memory is generally addressed byte by byte and assume that a word s4 bytes) and address for "a" is 0x0000ec00. Also, we have a =24, b =110, and c =20 at the starting time. Assume that the first instruction of the code is stored in 0x00000128. Also, each instruction has the opcode in the first byte (most significant byte) and the remaining 3 bytes specify the corresponding address. The opcode for store is 1, load is 2, and add is 3.
0x00006128 load a
0x0000612c add b
Oxx000b 130 store c
a.Show the memory addresses and contents for all the instructions and data involved. Use the format as follows to express your answer (but the following is not the anower). For all data, use hexadecimal representation.
Addresses contents
01000021040x00000001
0x000021080x00000002(3+3=6 marks)
b. Write the micro instructions for the code segment Assume that current PC (program counter) is 0x0000b128. For each micro-instruction, also indicate the data that is transferred (if it is a memory access). For all data, use the hexadecimal representation. The following are the first two micro-instructions and the data transferred. Complete the rest
Micro-instructions
PC-MAR
M-MBR
Data
0x0000b128
0x0200ec00(2+2+2=6 marks)

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 Programming Questions!