w05-quiz1-solution

w05-quiz1-solution - ECE 30 Introduction to Computer...

Info iconThis preview shows pages 1–3. Sign up to view the full content.

View Full Document Right Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: ECE 30 Introduction to Computer Engineering Quiz 1 January 19, 2005 Name Solution Student ID Signature Your score out of 1 6 2 6 3 8 Total 20 You may only use the MIPS assembly instructions listed below. Do not use any other instructions! arithmetic add add sub subtract addi add immediate special lui load upper immediate slt set if less than data lw load word from memory transfer sw store word in memory lb load byte from memory sb store byte in memory branch beq branch if equal bne branch if not equal jump j jump jal jump and link jr jump register 1. Performance measurement (6 points) The machine P is a 4 GHz implementation of the MIPS R2000 instruction set. Using a large set of scientific computation benchmarks, we have obtained the CPI as follows. frequency CPI Integer arithmetic 30% 0.5 Floating-point arithmetic 20% 3 Load/Store 30% 1.5 Branch/Jump 20% 2 (a) (1 point) What is the average CPI of P ? CPI = . 3 . 5 + 0 . 2 3 + 0 . 3 1 . 5 + 0 . 2 2 = . 15 + 0 . 6 + 0 . 45 + 0 . 4 = 1 . 6 (b) (1 point) If the total execution time of the benchmark program is 1 second, what is the total number of instructions executed for this benchmark? Recall that the clock ratethe total number of instructions executed for this benchmark?...
View Full Document

This note was uploaded on 06/09/2008 for the course ECE 30 taught by Professor Gert during the Spring '08 term at UCSD.

Page1 / 5

w05-quiz1-solution - ECE 30 Introduction to Computer...

This preview shows document pages 1 - 3. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online