Problem 1consider two different machines the first has a

Assignment Help Computer Engineering
Reference no: EM13365506

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: EM13365506

Questions Cloud

Business question organizational behaviororganizational : business question organizational behaviororganizational behavior classes are useful only to people who will pursue a
Failing to get permissionshow the impact of failing to get : failing to get permissionshow the impact of failing to get permission before taking an action with a customer e.g.
History of the organizational behavior fieldshow the : history of the organizational behavior fieldshow the history of the organizational behavior field with four
What are some common problems when administering employee : what are some common problems when administering employee policies in an organization and what are the controversies
Problem 1consider two different machines the first has a : problem 1consider two different machines. the first has a single cycle datapath i.e. a single stage non-pipelined
Problem 0choose the correct answer for the following : problem 0choose the correct answer for the following multiple-choice questions0.0 you are offered old homework
Learning organizational behaviorhow can learning about : learning organizational behaviorhow can learning about organizational behavior give a person a better understanding of
Performance appraisal systemsexplain what are some : performance appraisal systemsexplain what are some advantages and disadvantages of various types of performance
Determine the business implications of your pr : determine the business implications of your pr campaignnbspunfortunately my fellow team mates are waiting to the last

Reviews

Write a Review

Computer Engineering Questions & Answers

  Declare a class with name cubicle

Declare a class with name Cubicle. The name stands for any rectangular prismatic solid body having three dimensions, i.e. length, width, and height.

  Show output from the amazon web service

make Use of Visual Studio.NET 2005 to create an ASP.NET application that displays output from the Amazon web service. Add good documentation to the code. Furthermore, create a user-friendly interface.

  Getting smaller potential impact on american culture

express transitors getting smaller potential impact on American culture include the positive and negative implications that this discovery/breakthrough may have on your everyday life.

  Make a list of files that are world-writable

make a crontab to perform the tasks listed below at the frequencies specified. Note that you do NOT need to write the actual scripts.

  Write a java program that prints all real solutions

make a class QuadraticEquation whose constructor receives the coefficients a, b, c of the quadratic equation. Supply methods getSolution1 and getSolution2 that get the solutions, using the quadratic formula, or 0 if no solution exists. The getSolu..

  Questionwireless technologywrite down a three to four page

questionwireless technologywrite down a three to four page paper in which you-1. compare pros and cons of 3g and 4g

  How to write a complete interactive java gui program

Write down a complete interactive Java GUI program that requests two numbers from the user. The first number is the row dimension and second number is the column dimension

  Choose the employee''s last name

Group employees by salary within their job code: choose the employee's last name and group them by salary within their job_title_code.

  Comprise an explanation of functions and grouping

define the key concepts that are involved in summarizing data in a query. Include an explanation of functions and grouping. Please provide some examples to illustrate your points.

  Create a shippedorder class that derives from order

Create a ShippedOrder class that derives from Order.

  What is the history of osi model and benefits

Why you will recommend either asymmetric key encryption, symmetric key encryption, or no encryption at all for the Email correspondence.

  The main reasons for it project failures

Statistics show that most projects fail for some reason or other. What are the key reasons for IT project failures?

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