0% found this document useful (0 votes)
8 views

CENG400 Assignment 1

Uploaded by

medo.miso.2000
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
8 views

CENG400 Assignment 1

Uploaded by

medo.miso.2000
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

Problem 1:

Consider three different processors P1, P2 and P3 executing the same instruction set with clock
rates and CPI given in the following table:

Processor Clock Rate CPI


P1 2 GHz 1.5
P2 1.5 GHz 1.0
P3 3 GHz 2.5

a) Which processor has the highest performance?

b) If the processors each execute a program in 10 seconds, find the number of cycles and the
number of instructions.

c) We are trying to reduce the execution time by 30% but this leads an increase of 20% in
the CPI. What clock rate should we have to get this time reduction?
Problem 2:

You work at consultancy firm that advises customers on which computer they should buy. A
customer came to you for an advice about buying one of computers A, B, or C. To help make
your decision you ran the same test bench program on the three computers. The program
contains: 13 ADD/SUB operations, 3 multiplication operations and 17 Memory operations.
• Each ADD/SUB operations takes 2 clock cycles on Computer A, 3 clock cycles on
Computer B and 1 clock cycles on Computer C.
• Each Multiplication operations takes 6 clock cycles on Compute A, 8 clock cycles on
Computer B, and 5 clock cycles on Computer C.
• Each Memory operations takes 4 clock cycles on Compute A, 5 clock cycles on
Computer B, and 3 clock cycles on Computer C.
The test bench program needs 25 nanoseconds (ns) on Computer A, 20 nanoseconds on
Computer B and 30 nanoseconds on Computer C.

Which computer should the costumer buy?


Problem 3:

Computer A has an overall CPI of 1.3 and can be run at a clock rate of 600 MHz. Computer B
has a CPI of 2.5 and can be run at a clock rate of 750 MHz. We have a particular program we
wish to run. When compiled for computer A, this program has exactly 100000 instructions. How
many instructions would the program need to have when compiled for Computer B, in order for
the two computers to have exactly the same execution time for this program?
Problem 4:

Consider two different processors P1, and P2 executing the same instruction set. P1 has a 3
GHz clock rate and a CPI of 1.5. P2 has a 2.5 GHz clock rate and a CPI of 1.0.

i. Which processor has the highest performance expressed in instructions per


second?

ii. If the processors each execute a program in 10 seconds, find the number of cycles
and the number of instructions.

iii. We are trying to reduce the execution time by 30% but this leads to an increase of
20% in the CPI. What clock rate should we have for each of the two processors to
get this time reduction?

You might also like