Hello, dear friend, you can consult us at any time if you have any questions, add WeChat: daixieit

CSE 560 – Practice Problem Set 2 Solution

Both of these problems come from Hennesy & Patterson’s Computer Architecture: A Quantitative Approach, 3rd  edition.

1.    Sometimes we have a set of performance measurements that vary from very small to very large. A single statistic, such as a mean, may not do a very good job of representing a useful sense of    the data as a whole.  For example, the processor’s ALU and disk subsystem perform primitive      operations at speeds that differ by a factor of up to 107 .  This is a speed difference in excess of    that between a jet airliner (~1000 kilometers per hour) and a snail gliding on a leaf (~ 1 meter      per hour). This problem examines the what happens when measurements with such a large        range are summarized by a single number.

(a)  What are the arithmetic means of two sets of benchmark measurements, one set with nine

values of 107  and one value of 1 and the other set with nine values of 1 and one value of       107 ?  How do these means compare with the data set medians?  Which outlying data affects the arithmetic mean more, a large or a small value?

Let the data value sets be

A = {107, 107, 107, 107, 107, 107, 107, 107, 107, 1}

and

B = {1, 1, 1, 1, 1, 1, 1, 1, 1, 107}

Arithmetic mean (A) = 9 X 106

Median (A) = 107

Arithmetic mean (B) = 1 X 106

Median (B) = 1

Set A mean and median are within 10% in value, but set B mean and median are far apart.  A large outlying value seriously distorts the arithmetic mean, while a small outlying value has a lesser effect.

(b)  What are the harmonic means of the two sets of measurements specified in part (a)?  How

do these means compare with the data set medians?  Which outlying data point affects the harmonic mean more, a large or a small value?

Harmonic mean (A) = 10.0

Harmonic mean (B) = 1.1

In this case the set B harmonic mean is very close to the median, but set A harmonic mean is much smaller that the set A median. The harmonic mean is more affected by a small              outlying value than a large one.

(c)  Which mean, arithmetic or harmonic, produces a statistic closest to the median?

Which is closest depends on the nature of the outlying data point(s).  Neither mean  produces a statistic that is representative of the data values under all circumstances.

(d)  Repeat parts (a) and (b) for two sets of 10 benchmark measurements with the outlying value only a factor of 2 larger or smaller.  How representative of the entire set do the arithmetic     and harmonic mean statistics seem for this narrow range of performance values?

Let the new data value sets be

C = {1, 1, 1, 1, 1, 1, 1, 1, 1, 2}

and

D = {107, 107, 107, 107, 107, 107, 107, 107, 107, 5 X 106}

Arithmetic mean (C) = 1.1

Harmonic mean (C) = 1.05

Median (C) = 1

Arithmetic mean (D) = 9.5 X 106

Harmonic mean (D) = 9.1 X 106

Median (D) = 107

In both cases, the means and medians are close.  Summarizing a set of data values that has less disparity among the values by stating a statistic, such as mean or median, is intrinsically more meaningful.

2.    Dhrystone is a well-known integer benchmark.  Computer A is measured to perform DA                         executions of the Dhrystone benchmark per second, and to achieve a millions per second           instruction rate of MIPSA while doing Dhrystone.  Computer B is measured to perform DB                    executions of the Dhrystone benchmark per second.  What is the fallacy in calculating the MIPS rating of computer B as MIPSB  = MIPSA X (DB / DA )?

As a hint, do some dimensional analysis (i.e., reason about the units).

The proposed formulation of MIPSB  can be rewritten as follows:

 =

Examining the units of each factor, we have

 = 

The time units factor out, revealing that the formulation has the implicit assumption that Computer A instructions/Dhrystone = Computer B instructions/Dhrystone

Unless Computer A and Computer B have the same instruction set architecture and execute        identically compiled Dhrystone executables, this assumption is likely false.  If so, the formulation for MIPSB  is also incorrect.