
CPSC2105 Introduction to Computer Organization
Homework Set 10 Answer Key
1. Question: Is a computer with a 1GHz CPU more than 3 times faster than one with
a 300 MHz CPU?
Answer: The book correctly says to consider Amdahl’s law.
The speedup of the new component is 1000 / 300 = 10 / 3.
Amdahl’s Law states that 1 / S = (1 – f) + f / k where
S is the speedup,
f is the fraction of work performed by the faster component (0.0 f 1.0), and
k is the speedup of the new component. Here 1 / k = 3 / 10, so f / k = (3f) / 10.
If f 1, then we have 1 / S 3 / 10 or S 10/3. This might be true for “compute bound”
jobs. However, if about 50% of the work is CPU and 50% is I/O, then we have
1 / S = 1/2 + 1/2 (3 / 10) = 10 / 20 + 3 / 20 = 13 / 20, and S = 20 / 13 1.54.
2. 60% CPU activity and 40% Disk activity.
Option 1 calls for new disks. k = 2.5 for a cost of $8,000.
Option 2 calls for a new CPU. k = 1.4 for a cost of $5,000.
Answers:
a) Option 1 improves the new disks. Here f = 0.4 and (1 – f) = 0.6
The speedup is given by 1 / S = 0.6 + (0.4 / 2.5) = 0.6 + 0.16 = 0.76, so S 1.32.
Option 2 improves the CPU. Here f = 0.6 and (1 – f) = 0.4
The speedup is given by 1 / S = 0.4 + 0.6 / 1.4 = 0.4 + 0.428 = 0.828, so S 1.21.
Option 1 gives 32% improvement for $8,000 or 4% per thousand.
Option 2 gives 21% improvement for $5,000 or 4.2% per thousand.
Option 2 (the $5,000 upgrade) is slightly better.
b) I would choose both options were I to want the fastest system.
However, having to choose 1, I would choose option 1 – the $8,000 upgrade.
c) ??? NOTE: This question is too vague, so I give full credit for any answer.
3. Same problem, but with 55% CPU and 45% disk.
Answers:
a) Option 1 improves the new disks. Here f = 0.45 and (1 – f) = 0.55
The speedup is given by 1 / S = 0.55 + (0.45 / 2.5) = 0.55 + 0.18 = 0.73, so S 1.37.
Option 2 improves the CPU. Here f = 0.55 and (1 – f) = 0.45
The speedup is given by 1 / S = 0.45 + 0.55 / 1.4 = 0.45 + 0.393 = 0.828, so S 1.19.
Option 1 gives 37% improvement for $8,000 or 4.6% per thousand.
Option 2 gives 19% improvement for $5,000 or 3.8% per thousand.