Sei sulla pagina 1di 21

Performance metrics and

measures

Parallelism profiles
Asymptotic speedup factor
System efficiency, utilization and quality
Standard performance measures

Degree of parallelism
Reflects the matching of software and
hardware parallelism
Discrete time function measure, for each
time period, the # of processors used
Parallelism profile is a plot of the DOP as a
function of time
Ideally have unlimited resources
2

Factors affecting parallelism


profiles

Algorithm structure
Program optimization
Resource utilization
Run-time conditions
Realistically limited by # of available
processors, memory, and other
nonprocessor resources
3

Average parallelism variables


n homogeneous processors
m maximum parallelism in a profile
- computing capacity of a single
processor (execution rate only, no
overhead)
DOP=i # processors busy during an
observation period
4

Average parallelism
Total amount of work performed is
proportional to the area under the profile
curve
t2

W DOP(t )dt
t1

W i ti
i 1

Average parallelism

1 t2
A
DOP
(
t
)
dt

t 2 t1 t 1
m
m

A i ti / ti
i 1
i 1
6

Example: parallelism profile and


average parallelism

Asymptotic speedup
m

Wi
T (1) ti (1)
i 1
i 1
m

Wi
T ( ) ti ( )
i 1
i 1 i

T (1)
S

T ( )

i 1
m

W / i
i

i 1

= A in the ideal case

(response time)

Performance measures
Consider n processors executing m
programs in various modes
Want to define the mean performance of
these multimode computers:
Arithmetic mean performance
Geometric mean performance
Harmonic mean performance
9

Arithmetic mean performance


m

Ra Ri / m
i 1
m

R ( f i Ri )
*
a

Arithmetic mean execution rate


(assumes equal weighting)

Weighted arithmetic mean


execution rate

i 1

-proportional to the sum of the inverses of


execution times
10

Geometric mean performance


m

Rg R
i 1
m

1/ m
i

R Ri
*
g

i 1

fi

Geometric mean execution rate

Weighted geometric mean


execution rate

-does not summarize the real performance since it does


not have the inverse relation with the total time
11

Harmonic mean performance


Ti 1 / Ri

Mean execution time per instruction


For program i

1 m
1 m 1
Ta Ti
m i 1
m i 1 Ri

Arithmetic mean execution time


per instruction

12

Harmonic mean performance


Rh 1 / Ta

m
m

(1 / R )
i 1

R
*
h

1
m

( f
i 1

Harmonic mean execution rate

Weighted harmonic mean execution rate

/ Ri )
-corresponds to total # of operations divided by
the total time (closest to the real performance)
13

Harmonic Mean Speedup


Ties the various modes of a program to the
number of processors used
Program is in mode i if i processors used
Sequential execution time T1 = 1/R1 = 1

S T1 / T
*

i 1

f i / Ri
14

Harmonic Mean Speedup


Performance

15

Amdahls Law
Assume Ri = i, w = (, 0, 0, , 1- )
System is either sequential, with probability
, or fully parallel with prob. 1-

n
Sn
1 (n 1)
Implies S 1/ as n
16

Speedup Performance

17

System Efficiency
O(n) is the total # of unit operations
T(n) is execution time in unit time steps
T(n) < O(n) and T(1) = O(1)

S ( N ) T (1) / T (n)
S (n) T (1)
E ( n)

n
nT (n)
18

Redundancy and Utilization


Redundancy signifies the extent of
matching software and hardware parallelism

R (n) O(n) / O(1)


Utilization indicates the percentage of
resources kept busy during execution
O ( n)
U ( n) R ( n) E ( n)
nT ( n)
19

Quality of Parallelism
Directly proportional to the speedup and
efficiency and inversely related to the
redundancy
Upper-bounded by the speedup S(n)
3

S ( n) E ( n)
T (1)
Q ( n)

2
R ( n)
nT (n)O(n)
20

Example of Performance
Given O(1) = T(1) = n3, O(n) = n3 + n2log n,
and T(n) = 4 n3/(n+3)
S(n)
E(n)
R(n)
U(n)
Q(n)

=
=
=
=
=

(n+3)/4
(n+3)/(4n)
(n + log n)/n
(n+3)(n + log n)/(4n2)
(n+3)2 / (16(n + log n))
21

Potrebbero piacerti anche