Hardware Reference
In-Depth Information
proved by making that case faster. A fundamental law, called Amdahl's law , can be used to
quantify this principle.
Amdahl's Law
The performance gain that can be obtained by improving some portion of a computer can be
calculated using Amdahl's law. Amdahl's law states that the performance improvement to be
gained from using some faster mode of execution is limited by the fraction of the time the
faster mode can be used.
Amdahl's law defines the speedup that can be gained by using a particular feature. What is
speedup? Suppose that we can make an enhancement to a computer that will improve per-
formance when it is used. Speedup is the ratio:
Alternatively,
Speedup tells us how much faster a task will run using the computer with the enhancement
as opposed to the original computer.
Amdahl's law gives us a quick way to find the speedup from some enhancement, which de-
pends on two factors:
1. The fraction of the computation time in the original computer that can be converted to take advant-
age of the enhancement —For example, if 20 seconds of the execution time of a program that
takes 60 seconds in total can use an enhancement, the fraction is 20/60. This value, which
we will call Fraction enhanced , is always less than or equal to 1.
2. The improvement gained by the enhanced execution mode, that is, how much faster the task would
run if the enhanced mode were used for the entire program —This value is the time of the original
mode over the time of the enhanced mode. If the enhanced mode takes, say, 2 seconds for a
portion of the program, while it is 5 seconds in the original mode, the improvement is 5/2.
We will call this value, which is always greater than 1, Speedup enhanced .
The execution time using the original computer with the enhanced mode will be the time spent
using the unenhanced portion of the computer plus the time spent using the enhancement:
The overall speedup is the ratio of the execution times:
Search WWH ::




Custom Search