Question

. (10 pt) Registers R1 and R2 hold the values given below. Write down the values in R3 and R4 after executing each group of i

0 0
Add a comment Improve this question Transcribed image text
Answer #1

Group 1

multu R1, R2 => Unsigned multiplication of 32 bits registers which outputs 64 bit value

  • (HI, LO) = R1 * R2
  • (HI, LO) = (00AABB11)16 * (00000100)16
  • (HI, LO) = (00000000 AABB1100)16

mfhi R3 => move from HI

  • R3 = 0000000016

mflo R4   => move from LO

  • R4 = AABB110016

Group 2

divu R1, R2 => Unsigned division of 32 bits registers

  • HI = Remainder of R1 divided by R2,
  • LO = Quotient of R1 divided by R2
  • HI = (00AABB11)16 % (00000100)16 =  0000001116
  • LO = (00AABB11)16 / (00000100)16 = 0000AABB16

mfhi R3 => move from HI

  • R3 = 0000001116

mflo R4   => move from LO

  • R4 = 0000AABB16
Add a comment
Know the answer?
Add Answer to:
. (10 pt) Registers R1 and R2 hold the values given below. Write down the values...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • 8. (8 pt) After executing each group of instructions, write down if the branch is taken...

    8. (8 pt) After executing each group of instructions, write down if the branch is taken or not-taken (i.e., write down if the branch condition is true (taken branch) or false (not-taken branch). Each group of instructions is independent of each other and each group uses the register values given below. Show your work. R1 = FFFF FFFF16 R2 = 0000 0000116 slt R3, R1, R2 beq R3, RO, target Branch outcome = sltu R3, R1, R2 beq R3, RO,...

  • Stack Operation 10. (10 pts.) Show the contents of the stack and affected registers at the two marked points in the exe...

    Stack Operation 10. (10 pts.) Show the contents of the stack and affected registers at the two marked points in the execution of the followin code. Assume RO-0, R1-1, R2-2, R3-3, R4-4, R5-5, and R6-6. The initial value for stack pointer (prior to executing this code block) is given as SP-0x20001000 PUSH R2,R3) ADD R4, R1, Re ;<---A POP R5, R6) ADD R5, R5, R4 ADD R6, R6, R5 PUSH (R4-R6); SUBS Re, RO,R1-B a) Show the contents of Stack,...

  • Q4 (10 marks): What are the values in registers R1, R2 and R3 at the end...

    Q4 (10 marks): What are the values in registers R1, R2 and R3 at the end of this ARMv7 assembly program? MOV R1, #2 MOV R2, #10 MOV R3, #10 L1: CMP R1, R3 BGE L3 BL L2 ADD R1, R1, #3 BL1 L2: ADD R2, R2, #3 MOV R15, R14 L3: MUL R3, R1, R2 Q5 (10 marks): Please write ARMv7 assembly program for following C programs. Assume that variables are stored in memory and their addresses can be...

  • Section B - ARM Assembly Language (25 marks) An ARM instruction set summary is provided at...

    Section B - ARM Assembly Language (25 marks) An ARM instruction set summary is provided at the end of this paper 1. (5 marks) Consider the following assembly instruction STMFD r13!, (r5-6} Before executing this instruction, registers hold the following values: Register Value Register r9 Value r4 0x00400040 0x00000000 r5 r10 0x11223344 0x00800080 r6 0x55667788 r11 0x10001000 r7 0x99aabbcc r12 0x20002000 r8 exddeeff00 r13 ex40004000 What memory locations are affected after executing the above instruction? In a table, with a...

  • Refer to Figure 71. Assume all values are in Ohms. Given R1= 5, R2= 9, R3=14,...

    Refer to Figure 71. Assume all values are in Ohms. Given R1= 5, R2= 9, R3=14, R4=10, R5=16, R6=13, & R7= 3. Determine the equivalent Resistance (Req). Answer only. . R1 R2 +---/\/\/\-----/\/\/\---+ | | | R3 R4 | +---/\/\/\--+--/\/\/\---+ | | | | | R5 | | +--/\/\/\---+ | | | --|-- | | | | |R6 | | |___| | R7 | +--------/\/\/\---------+ | | | | +----x y------|

  • Given the following values in the indicated bases: R1=(7460)_8, R2=(A8D)_16, and R3=(000)_16. a- Convert R1, R2...

    Given the following values in the indicated bases: R1=(7460)_8, R2=(A8D)_16, and R3=(000)_16. a- Convert R1, R2 and R3 into binary values (the sign bit is included in the above values where negative numbers are already in 2's complement) b- Use sign extension rules to double the size of each register c- Select the most economical multiplier from R1 and R2 for Booth's algorithm d- Use Booth's algorithm to multiply multiplier by multiplicand indicating all intermediate values R1 R2

  • Registers R1 and R2 of a computer contain the decimal values 12000 and 6000 respectively. What...

    Registers R1 and R2 of a computer contain the decimal values 12000 and 6000 respectively. What is the Effective Address of the memory operand in each of the following instructions?             i) MOV 20(R1), R5           ii) STORE R5, 30(RF1,R2)              iii) LOAD #3000, R5        iv) ADD -(R2),R5

  • In the circuit below given that R1 = 500 Ohm, R2 = 820 Ohm, R3 =...

    In the circuit below given that R1 = 500 Ohm, R2 = 820 Ohm, R3 = 830 Ohm, R4 = 240 Ohm, E = 7 V. Find the power dissipated by resistor R4. R4 E R3 R2 R1

  • You are given a homework processor (HPro) capable of addressing 32 8-bit (1 byte) wide registers....

    You are given a homework processor (HPro) capable of addressing 32 8-bit (1 byte) wide registers. However, it has only 29 physical registers. Register RO, R1 and R31 are not physically implemented. Instead, every read from RO, R1 and R31 will return a constant zero (00000000), constant one (00000001) and all ones (11111111), respectively. Every write to RO, R1 and R31 will go to null (dummy write). Assume that all other registers have initially unknown (X) state (This in fact...

  • In the circuit shown below, the values for each resistor are: R1 = 6 ohm R2...

    In the circuit shown below, the values for each resistor are: R1 = 6 ohm R2 = 3 ohm R3 = 8 ohm R4 = 5.67 ohm R5 = 2 ohm R6 = 5 ohm R7 = 25 ohm Based on these values: a) What is the total resistance between points a and d? b) If the circuit is connected to a 25.24 volt battery, what is the current through R1? c) What is the current through R6? d) What...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT