Pipelined machine versus the single cycle machine

Assignment Help Basic Computer Science
Reference no: EM1352577

Problem 1

Consider two different machines. The first has a single cycle datapath (i.e., a single stage, non-pipelined machine) with a cycle time of 4ns. The second is a pipelined machine with four pipeline stages and a cycle time of 1ns.

Part (a) What is the speedup of the pipelined machine versus the single cycle machine assuming there are no stalls?

Part (b) What is the speedup of the pipelined machine versus the single cycle machine if the pipeline stalls 1 cycle for 30% of the instructions?

Part (c) [2 points] Now consider a 3 stage pipeline machine with a cycle time of 1.1ns. Again assuming no stalls, is this implementation faster or slower than the original 4 stage pipeline? Explain your answer.

Problem 2

Consider two different 5-stage pipeline machines (IF ID EX MEM WB). The first machine resolves branches in the ID stage, uses one branch delay slot, and can fill 60% of the delay slots with useful instructions. The second machine resolves branches in the EX stage and uses a predict-not-taken scheme. Assume that the cycle times of the machines are identical. Assume that 15% of the instructions are branches, 25% of branches are taken, and that stalls are due to branches alone. Which machine is faster? To get any credit, you must justify your answer. 

Problem 3

Consider a pipeline with the following structure: IF ID EX MEM WB. Assume that the EX stage is 1 cycle long for all ALU operations, loads and stores. Also, the EX stage is 3 cycles long for the FP add, and 6 cycles long for the FP multiply. The pipeline supports full forwarding. All other stages in the pipeline take one cycle each. The branch is resolved in the ID stage. WAW hazards are resolved by stalling the later instruction. Assume that there are different registers for FP and int data types, there are different multipliers for FP multiplication and int multiplication operations and there are different adders for FP Addition and int addition. Also assume that all functional units are pipelined. For the following code, list all the data hazards that cause stalls. State the type of data hazard and give a brief explanation why each hazard occurs.

 

loop:                L.D F0, 0(R1)                  #1

                        L.D F2, 8(R1)                 #2

                        L.D F4, 16(R1)               #3

                        L.D F6, 24(R1)               #4

                         ADD.D F10, F4, F0        #6

                         ADD.D F8, F2, F0          #7

                      S.D 0(R2), F8                  #8

                       DADDI R2, R2, 8            #9

                       S.D 8(R2), F10               #10

                       DSUBI R1, R1, 32            #11

 

                      BNEZ R1, loop                 #12

                        MULT.D F8, F6, F0           #5

 

Problem 4 For this problem, we will explore a pipeline for a register-memory architecture. The architecture has two instruction formats: a register-register format and a register-memory format. In the register-memory format, one of the operands for an ALU instruction could come from memory.

There is a single memory-addressing mode (offset + base register). The only non-branch register-memory instructions available have the format:

Op Rdest, Rsrc1, Rsrc2

or

Op Rdest, Rsrc1, MEM

where Op is one of the following: Add, Subtract, And, Or, Load (in which case Rsrc1 is ignored), or Store. Rsrc1, Rsrc2, and Rdest are registers. MEM is a (base register, offset) pair.

Branches compare two registers and, depending on the outcome of the comparison, move to a target address. The target address can be specified as a PC-relative offset or in a register (with no offset). Assume that the pipeline structure of the machine is as follows:

IF RF ALU1 MEM ALU2 WB

The first ALU stage is used for effective address calculation for memory references and branches. The second ALU stage is used for operations and branch comparison. RF is both decode and register-fetch stage. Assume that when a register read and a register write of the same register occur in the same cycle, the write data is forwarded.

(a) Find the number of adders, counting any adder or incrementor, needed to minimize the number of structural hazards. Justify why you need this number of adders.

(b) Find the number of register read and write ports and memory read and write ports needed to minimize the number of structural hazards. Justify why you need this number of ports for the register file and memory.

 (c) Will data forwarding from the ALU2 stage to any of ALU1, MEM, or ALU2 stages reduce or avoid stalls? Explain your answer for each stage.

 (d) [3 points] Will data forwarding from the MEM stage to any of ALU1, MEM, or ALU2 stages reduce or avoid stalls? Explain your answer for each stage.

Reference no: EM1352577

Questions Cloud

How fast did nicole throw the ball : A 50 hard-boiled egg moves on the end of a spring with force constant . It is released with an amplitude 0.300 . A damping force acts on the egg. After it oscillates for 5.00 , the amplitude of the motion has decreased to 0.100.
What is the yearly demand for coffee by us consumers : The yearly demand for coffee by U.S. consumers is given by the demand curve QD=250-10P, where Q is quantity.
Representing information by predicate-calculus sentences : Represent this information by predicate-calculus sentences in such a way that you can represent the question Is there a member of the alpine club
Determine the magnitude and direction of the resultant : A crate with a mass of 171.5 kg is suspended from the end of a uniform boom with a mass of 80.3 kg. The upper end of the boom is supported by a cable attached to the wall and the lower end by a pivot (marked X) on the same wall. compute the tensio..
Pipelined machine versus the single cycle machine : What is the speedup of the pipelined machine versus the single cycle machine assuming there are no stalls?What is the speedup of the pipelined machine versus the single cycle machine if the pipeline stalls 1 cycle for 30% of the instructions?
Cs433: computer architecture : CS433: Computer Architecture - Spring  2014,  Assume a new execution mode called "enhanced mode" provides a 1.5x speedup to the sections of programs where it applies. What percentage of a program (measured by original execution time) must run in en..
Define and explain the various forces that affect market : Define and explain the various forces that affect in international markets and What are the advantages and disadvantages of trade protectionism?
What would the largest cardholder fee that tuan will pay : what would the largest cardholder fee that Tuan will pay. If the rental store has a constant marginal cost of $2, which strategy is more profitable?
Whether attribution biases can be positive : Explain whether or not attribution biases can be positive and why.

Reviews

Write a Review

Basic Computer Science Questions & Answers

  Steps for company browse the site using this url

The static IP address of the server is 192.168.45.200. What steps do you take so that each computer in  company can browse site by using this URL?

  Find out product stream temperature and volume

Find out the product stream temperature and volume required to carry out reaction in a CSTR at 50 % conversion in adiabatic mode of operation.

  Explaining physical material on which computer keeps data

Storage is the physical material on which a computer keeps data, instructions, and information?

  Relationship between certifications and performance

Describe the relationship between certifications and performance? What does "performance" mean and how do you measure it?

  Explaining multicategory case a set of samples

In multicategory case a set of samples is said to be linearly separable if there exists linear machine which can classify them all correctly.

  The authentication process in a synchronous token system

Describe how the Kerberos authentication process work and outline the main components within the Kerberos environment, their respective functions and the level of security provided by Kerberos. Draw a diagram supporting your explanation Explain..

  Explaining organization management responsibilities

Describe in scholarly detail common organization management responsibilities.

  Describing dichotomy is not linearly separable

Let the d component of x be either 0 or 1. Assume we assign x to w1 if number of non-zero components of x is odd, and to w2 otherwise. Illustrate that this dichotomy is not linearly separable if d>1.

  Procedure for checking suitcases for secret compartments

You are responsible for checking suitcases for secret compartments in which bulky items like jewelry might be hidden. Explain procedure you would follow to check for these compartments.

  Explaining actionscript developer

What do you believe the following comment means for ActionScript developer: "you are used to having to define object methods and properties in class structure before using them in instance.

  Tools used to avoid losing passphrase

Are there any tools which someone can utilize safely, other than key recovery, to avoid losing his or her passphrase?

  Explain two standard apis supported by jaxp

Explain two standard APIs supported by JAXP (Java API for XML processing) and give a comprison between two mechanism.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd