Exam 2 Solved Problems - Advanced Computer Architecture | ECE 4100, Exams of Computer Architecture and Organization

Material Type: Exam; Class: Adv Computer Architecure; Subject: Electrical & Computer Engr; University: Georgia Institute of Technology-Main Campus; Term: Summer 2004;

Typology: Exams

Pre 2010

Uploaded on 08/05/2009

koofers-user-6sk
koofers-user-6sk 🇺🇸

4.3

(4)

9 documents

1 / 3

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
SCORE:________ Name:__________________________________________
ECE 4100/6100 Advanced Computer Architecture
Test II – Summer 2004
1. (20 points) A program executes a loop twenty times. If a 2-bit predictor is assigned to
this loop and no aliasing occurs in the BHT with another branch, calculate the
prediction accuracy. Assume all of the predictors are initialized to not taken the 00
state at power up and this is the first time the loop is executed and the first time this
2-bit predictor is accessed after power up. The conditional branch is at the bottom of
the loop.
2 initial incorrect + 1 final = 17/20
Branch Prediction Rate = ___85_________%
What would happen if static branch prediction (like the PIV) was used to initially set the
2-bit predictor to the taken 11 state initially after power up whenever it first sees a
conditional branch that jumps backwards? (Note: This would likely require some extra
hardware in the BHT, but just assume it can do it)
Only final prediction would be incorrect = 19/20
Branch Prediction Rate = ___95_________%
2. (20 points) A single-issue processor has a pipeline CPI of 1.5 and a cache miss rate of
5% per instruction and a 4Ghz clock. A dual-issue version of the processor from another
company has a pipeline CPI of 0.8 and a clock rate of 3Ghz, but with a cache miss rate of
7%. The main memory access time is 10ns for a miss. Compute the MIPS performance of
the two processors including both pipeline and cache CPI effects.
CPIs = 1.5 +.05*10ns/.25ns = 3.5 overall
CPId = .8 +.07*10ns/.33ns = 2.9 overall
4Ghz/3.5 = 1142 MIPS
3Ghz/2.9 = 1034 MIPS
Single-Issue execution rate = ____1142______ MIPS
Dual-Issue execution rate = ____1034______ MIPS
pf3

Partial preview of the text

Download Exam 2 Solved Problems - Advanced Computer Architecture | ECE 4100 and more Exams Computer Architecture and Organization in PDF only on Docsity!

SCORE:________ Name:__________________________________________

ECE 4100/6100 Advanced Computer Architecture

Test II – Summer 2004

  1. (20 points) A program executes a loop twenty times. If a 2-bit predictor is assigned to this loop and no aliasing occurs in the BHT with another branch, calculate the prediction accuracy. Assume all of the predictors are initialized to not taken the 00 state at power up and this is the first time the loop is executed and the first time this 2-bit predictor is accessed after power up. The conditional branch is at the bottom of the loop. 2 initial incorrect + 1 final = 17/ Branch Prediction Rate = ___85_________% What would happen if static branch prediction (like the PIV) was used to initially set the 2-bit predictor to the taken 11 state initially after power up whenever it first sees a conditional branch that jumps backwards? (Note: This would likely require some extra hardware in the BHT, but just assume it can do it) Only final prediction would be incorrect = 19/ Branch Prediction Rate = ___95_________%
  2. (20 points) A single-issue processor has a pipeline CPI of 1.5 and a cache miss rate of 5% per instruction and a 4Ghz clock. A dual-issue version of the processor from another company has a pipeline CPI of 0.8 and a clock rate of 3Ghz, but with a cache miss rate of 7%. The main memory access time is 10ns for a miss. Compute the MIPS performance of the two processors including both pipeline and cache CPI effects. CPIs = 1.5 +.0510ns/.25ns = 3.5 overall CPId = .8 +.0710ns/.33ns = 2.9 overall 4Ghz/3.5 = 1142 MIPS 3Ghz/2.9 = 1034 MIPS Single-Issue execution rate = ____1142______ MIPS Dual-Issue execution rate = ____1034______ MIPS
  1. (30 points) Show how the following program with execute on this dual-issue dynamically scheduled processor with speculation for two loop iterations. Fill in the information and clock cycles in the table below. The machine has six reservation stations on each functional unit, branch prediction, two CDBs, and a reorder buffer that holds 16 instructions. The I cache can read a pair of instructions per clock assuming that they are from sequential even and odd addresses. Assume in-order commit and two integer ALUs for L/S/Bxx. The floating point units must wait several clocks as seen in the table below before handling another operation (i.e. not fully pipelined). Loop: L.D F0, 0(R1) MUL.D F4, F0, F S.D F4, 0(R1) DADDIU R1, R1#- BNE R1, R2, Loop Instruction Execute Stage Clocks Integer Ops 1 FP Multiply 5 FP Add 2 Load 1 Store 1 Iteration Instruction Issue Execute Read Write CDB Commits 1 L.D 1 2 3 4 5 1 MUL.D 1 5-9 10 11 1 S.D 2 3 12 1 DADDUI 2 3 4 12 1 BNE 3 5 13 2 L.D 4 5 6 7 13 2 MUL.D 4 11-15 16 17 2 S.D 5 17 18 2 DADDUI 5 6 7 18 2 BNE 6 8 19 What would happen differently in this program, if the processor did not speculate? The processor would have to stall until each branch is complete – slowing down the code be several clocks.