Performance Evaluation of Parallel Computers
Performance Evaluation of Parallel Computers
Parallel Computers
NARENDRA KUMAR
Basics of
Performance Evaluation
A sequential algorithm is evaluated in terms of its execution time which is
expressed as a function of its input size.
For a parallel algorithm, the execution time depends not only on input size but
also on factors such as parallel architecture, no. of processors, etc.
Performance Metrics
Parallel Run Time Speedup Efficiency
Parallel Runtime
The parallel run time T(n) of a program or application is the time required to
run the program on an n-processor parallel computer.
When n = 1, T(1) denotes sequential runtime of the program on single
processor.
Speedup
Speedup S(n) is defined as the ratio of time taken to run a program on a single
processor to the time taken to run the program on a parallel computer with
identical processors
It measures how faster the program runs on a parallel computer rather than on
NARENDRA KUMAR
a single processor.
3
Performance Metrics
Efficiency
The Efficiency E(n) of a program on n processors is defined as the ratio of
speedup achieved and the number of processor used to achieve it.
4
Performance Metrics
<<<IMAGES>>>
NARENDRA KUMAR
5
Performance Metrics
<<<IMAGES>>>
NARENDRA KUMAR
6
Performance Metrics
<<<IMAGES>>>
NARENDRA KUMAR
7
Performance Measures
8
Performance Measures
Benchmarks
Machines are exposed to these benchmark tests and tested for performance.
When it is not possible to test the applications of different machines, then the
results of benchmark programs that most resemble the applications run on
those machines are used to evaluate the performance of machine.
NARENDRA KUMAR
9
Performance Measures
Benchmarks
Kernel Benchmarks
[Program fragments which are extracted from real programs]
[Heavily used core and responsible for most execution time]
Synthetic Benchmarks
[Small programs created especially for benchmarking purposes]
[These benchmarks do not perform any useful computation]
EXAMPLES
LINPACK LAPACK Livermore Loops SPECmarks
NAS Parallel
NARENDRA KUMAR Benchmarks Perfect Club Parallel Benchmarks
10
Parallel Overhead
• Inter-processor Communication
• Load Imbalance
• Inter-Task Dependency
• Extra Computation
• Parallel Balance Point
NARENDRA KUMAR
11
Speedup
Performance Laws
Speedup Performance Laws
Amdahl’s Law
[based on fixed problem size or fixed work load]
Gustafson’s Law
[for scaled problems, where problem size increases with
machine size
i.e. the number of processors]
12
Speedup
Performance Laws
Amdahl’s Law (1967)
For a given problem size, the speedup does not increase linearly as the number
of processors increases. In fact, the speedup tends to become saturated.
This is a consequence of Amdahl’s Law.
13
Speedup
Performance Laws
Amdahl’s Law
T(n) = Ts + Tp/n =
14
Speedup
Performance Laws
Amdahl’s Law
As n ∞, S(n) 1/α
This means, no matter how many processors are employed, the speedup in
this problem is limited to 1/α.
This is known as sequential bottleneck of the problem.
15
Speedup
Performance Laws
Amdahl’s Law
A major shortcoming in applying the Amdahl’s Law: (is its own characteristic)
The total work load or the problem size is fixed
Thus, execution time decreases with increasing no. of processors
NARENDRA KUMAR
16
Speedup
Performance Laws
Amdahl’s Law
<<<GRAPH>>>
NARENDRA KUMAR
17
Speedup
Performance Laws
Gustafson’s Law (1988)
It relaxed the restriction of fixed size of the problem and used the notion of
fixed execution time for getting over the sequential bottleneck.
18
Speedup
Performance Laws
Gustafson’s Law
As the machine size increases, the work load (or problem size) is also increased
so as to keep the fixed execution time for the problem.
NARENDRA KUMAR
19
Speedup
Performance Laws
Gustafson’s Law
<<<IMAGES>>>
NARENDRA KUMAR
20
Speedup
Performance Laws
Gustafson’s Law
NARENDRA KUMAR
21
Speedup
Performance Laws
Sun & Ni’s Law (1993)
This law defines a memory bounded speedup model which generalizes both
Amdahl’s Law and Gustafson’s Law to maximize the use of both processor and
memory capacities.
The idea is to solve maximum possible size of problem, limited by memory capacity
22
Speedup
Performance Laws
Sun & Ni’s Law
According to this law, the speedup S*(n) in the performance can be defined by:
23
Speedup
Performance Laws
Sun & Ni’s Law
Special Cases:
• G(n) = 1
Corresponds to where we have fixed problem size i.e. Amdahl’s Law
• G(n) = n
Corresponds to where the work load increases n times when memory is increased n
times, i.e. for scaled problem or Gustafson’s Law
• G(n) ≥ n
Corresponds to where computational workload (time) increases faster than memory
requirement.
Comparing
NARENDRA KUMAR speedup factors S*(n), S’(n) and S’(n), we shall find S*(n) ≥ S’(n) ≥ S(n)
24
Speedup
Performance Laws
Sun & Ni’s Law
<<<IMAGES>>>
NARENDRA KUMAR
25
Scalability Metric
Scalability
– Increasing the no. of processors decreases the efficiency!
+ Increasing the amount of computation per processor, increases the efficiency!
To keep the efficiency fixed, both the size of problem and the no. of processors
must be increased simultaneously.
26
Scalability Metric
Isoefficiency Function
The isoefficiency function can be used to measure scalability of the parallel
computing systems.
It shows how the size of problem must grow as a function of the number of
processors used in order to maintain some constant efficiency.
Where, U is the time taken to do the useful computation (essential work), and
O is the parallel overhead. (Note: O is zero for sequential execution).
NARENDRA KUMAR
27
Scalability Metric
Isoefficiency Function
A small isoefficiency function means that small increments in the problem size (U),
are sufficient for efficient utilization of an increasing no. of processors, indicating
high scalability.
ANARENDRA
largeKUMAR
isoeffcicnecy function indicates a poorly scalable system.
28
Scalability Metric
Isoefficiency Function
NARENDRA KUMAR
29
Performance
Measurement Tools
Performance Analysis
30
Performance
Measurement Tools
NARENDRA KUMAR
31
Performance
Measurement Tools
NARENDRA KUMAR
32
Performance
Measurement Tools
NARENDRA KUMAR
33
Performance
Measurement Tools
NARENDRA KUMAR
34
Performance
Measurement Tools
NARENDRA KUMAR
35
Performance
Measurement Tools
Instrumentation
Ways to do instrumentation:
By inserting it into the application source code directly, or
By placing it into the runtime libraries, or
By modifying the linked executable, etc.
37