Ask Question, Ask an Expert

+61-413 786 465

info@mywordsolution.com

Ask Computer Engineering Expert

1. Consider the following code fragment for the MIPS five stage pipelined processor:

instruction1 add $1, $8, $3 //$1 = $8 + $3

instruction2 sub $2, $1, $8 //$2 = $1 - $8

instruction3 add $3, $2, $1 //$3 = $2 + $1

instruction4 sub $5, $1, $2 //$5 = $1 - $2

instruction5 add $4, $2, $1 //$4 = $2 + $1

instruction6 add $9, $12, $11 //$9 = $12 + $11

a) You are to identify the problems, if any, which may be encountered in the pipeline. If you do identify any problems you are to explain them by using the instruction format terms , , for those instructions where there are problems.

b) At the end of clock cycle 6, which registers are being read and which register is being written. You must also identify which registers belong to which instruction in your answer.

b) Explain what the forwarding unit is doing during clock cycle 6. You are to identify which, if any, comparisons are being made in the instruction format terms , , for those instructions where there might be comparisons.

d) The code fragment is now changed to:

instruction1 add $1, $2, $3 //$1 = $2 + $3

instruction2 sub $4, $1, $6 //$4 = $1 - $6

instruction3 add $3, $2, $1 //$3 = $2 + $1

instruction4 lw $6, 8($3) //$6 = Memory[$3 + 8]

instruction5 sub $5, $1, $6 //$5 = $1 - $6

instruction6 add $9, $12, $11 //$9 = $12 + $11

Explain what the hazard detection unit is doing, for this new code fragment, during clock cycle 6 of execution. You are to state any comparisons that are being made in the instruction format terms , , for those instructions that might be compared. You are to state what the hazard unit will do in this case.

 

2. The following diagram reproduces the MIPS Single Cycle Datapath (Figure 5.1) from Computer Organization & Design: The Hardware Software Interface by Patterson and Hennessy.

a) In this representation every instruction takes at most 4 steps to complete a clock cycle. Explain what happens in each step of the clock cycle.

b) Clock cycle time = delay through combinational logic + register setup time + clock skew + delay through register. Briefly explain:

i) Why there is a delay through combinational logic.

ii) What the register setup time is.

iii) What clock skew is.

iv) What the delay through register is.

c) What type of MIPS instruction is represented by the diagram below? Provide two examples of this type of MIPS instruction.

Op

Rs

Rt

Rd

Shamt

funt

d) Explain what each field represents in the diagram from part c of this question (except the shamt field). In your explanation include the number of bits that each field requires and show each field's bit representation in the instruction format.

3)

a) Given the following MIPS machine instructions:

(i) 00010010111110010111111010111001

(ii) 00000000110010010111100000101010

For each machine instruction:

a) What is the instruction format class and why?

b) What operation will be performed and how did you identify the operation?

c) In decimal and in instruction format order, what registers (if any) represent rd, rs, rt? Hint rd is not always used. If you think no registers are used, state it.

d) What MIPS registers, if any, are used? In the case that MIPS registers are used, name them instruction format order and in terms of $at, $v0, $t0 etc. Hint rd is not always used. If you think no registers are used, state so.

e) In the case that an immediate value or an address is used, express it in hex. If you think the instruction does not use an immediate or an address, state so.

b) Explain the operation of the 'MIPS andi ' instruction. Illustrate your answer with an appropriate example. In your answer you must provide details of the andi instruction format and of what each field in that instruction format does and how an andi instruction is identified.

4)

Explain the operation of the following MIPS assembler instruction as it passes through each stage of the MIPS pipeline. You are to highlight any parallelism and redundancy that may occur as the instruction passes through the various pipeline stages. You are to assume there is no impact on this instruction by previously executed instructions. A diagram is not required.

Computer Engineering, Engineering

  • Category:- Computer Engineering
  • Reference No.:- M9750020

Have any Question?


Related Questions in Computer Engineering

Please respondwhat are some other ways to troubleshoot

PLEASE RESPOND What are some other ways to troubleshoot reduced speed or latency? Or to find out what is using all the bandwidth? Perhaps might incorporate parts of this into own three issues.

Assignmentyou have been requested to develop a healthcare

Assignment You have been requested to develop a healthcare system with the following characteristics: A hospital plans to build a healthcare system, which manages patient information. A hospital has a CEO, 5 doctors, 5 n ...

According to a recent article the average number of babies

According to a recent article the average number of babies born with significant hearing loss (deafness) is approximately four per 1,000 babies in a healthy baby nursery. The number climbs to an average of 30 per 1,000 b ...

Question the below table shows the instruction count ic for

Question : The below table shows the instruction count (IC) for programs running on three processors P1, P2, and P3 with the clock rates 1.0 GHz, 2.5 GHZ, and 2.0 GHz respectively. Each program consists of only Load/stor ...

What is the name of the text file on a windows computer

What is the name of the text file on a Windows computer that may store DNS to IP address mappings?

In class i described the methods used to create gas and

In class, I described the methods used to create gas and gasoline from the carbon in coal. The other ingredients were water and heat energy. First we made 'coal gas' from the carbon in coal  C + H2O → H2 + CO  Then we us ...

Question specify design implement im c a class for a card

Question : Specify, design implement im c++ a class for a card in a deck of playing cards. The object should contain methods for setting and retrieving the suit and rank of the card. Make sure to separate your work on s ...

Question set up geometric data tables for a unit cube using

Question ; Set up geometric data tables for a unit cube using only vertex and polygon tables and a single polygon table. Compare the two methods for representing the unit cube with a representation using three data table ...

A company that supplies batteries for watches guarantees

A company that supplies batteries for watches guarantees that 95% of the batteries it ships will be free from defects. You test a sample of 50 batteries you received. You find that fewer than 10 have defects. Does this l ...

Given a list of numbers l a value x is said to be a

Given a list of numbers L, a value x is said to be a majority value if the value of over half the elements in L is x; in other words, if L has n elements and nx is the number of elements in L with value x, then x is a ma ...

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

Why might a bank avoid the use of interest rate swaps even

Why might a bank avoid the use of interest rate swaps, even when the institution is exposed to significant interest rate

Describe the difference between zero coupon bonds and

Describe the difference between zero coupon bonds and coupon bonds. Under what conditions will a coupon bond sell at a p

Compute the present value of an annuity of 880 per year

Compute the present value of an annuity of $ 880 per year for 16 years, given a discount rate of 6 percent per annum. As

Compute the present value of an 1150 payment made in ten

Compute the present value of an $1,150 payment made in ten years when the discount rate is 12 percent. (Do not round int

Compute the present value of an annuity of 699 per year

Compute the present value of an annuity of $ 699 per year for 19 years, given a discount rate of 6 percent per annum. As