1

I am trying to answer a school assignment but i am getting confused to what the question is trying to ask.

A design optimization was applied to a computer system in order to increase the performance of a given execution mode by a factor of 10. The optimized mode is used 50% of the time, measured as a percentage of the execution time after the optimization has been applied.

(a)
What is the global speedup value that is achieved with this optimization?
Remind:
Amdahl’s law defines the global speedup as a function of the optimized fraction before the optimization is applied. As a consequence, the 50% ratio cannot be directly used to evaluate this speedup value.

(b)
What is the percentage of the original execution time that is affected by this optimization?

(c)
How much should such execution mode be optimized in order to achieve a global speedup of 5?
Can a global speedup of 12 be achieved?
And 11?

When trying to calculate answer A) i came to the answer 1.81 ( 20/11 )

T' = 0.5 * T + 0.5 * T / 10 = T / 2 + ( 1 / 20 ) T = ( 11 / 20 ) * T

Speedup = T / T' = T / ( ( 11 / 20 ) * T = 20 / 11 = 1.81

For me this answer makes sense but in the professor's solutions say otherwise:

(a) 5.5

(b) 91%

(c)
Yes it can with an optimization by a factor of 25 / 3.
No, because the factor can’t be negative, so it is impossible.
Also no, because ∞ optimization → impossible

I can't solve the other ones because I am confused with the first one.

Why is 5.5 the correct answer?

user3666197
  • 1
  • 6
  • 50
  • 92
iron bets
  • 11
  • 1
  • That being said, I think your problem is not in understanding but in carrying out the arithmetic. Maybe try a visual solution by drawing some boxes representing the computation times. – mkrieger1 Jan 10 '22 at 19:51
  • The math is wrong? In what way? Maybe i have a typo – iron bets Jan 10 '22 at 19:51
  • I can't quite put my finger on it, but my solution is that now the system spends 1 time unit doing one task and 1 time unit doing a second task, where before the optimization the second task took 10 time units. So the speedup is (1+10)/(1+1) = 11/2 = 5.5. – mkrieger1 Jan 10 '22 at 19:55
  • 1
    I think your mistake is trying to express T' in terms of T while the given information actually leads to expressing T in terms of T': T = T'/2 + 10 T'/2 = 11/2 T', from which the solution follows immediately. – mkrieger1 Jan 10 '22 at 20:05
  • Oh i see!! Your second comment made a lot of sense. I still can't figure out the second and the third question. Thanks! – iron bets Jan 10 '22 at 20:19
  • 2
    I suggest you draw some boxes. – mkrieger1 Jan 10 '22 at 20:53

3 Answers3

0

Let's suppose a computer has two states A and B, and after whatever optimization, it spends 0 ≤ p ≤ 1 of its time in state A, and q = 1 - p of its time in state B. (So p is something like .5, or .27).

State A was sped up by a factor of X. State B was sped up by a factor of Y.

So before, it was spending time p * X + q * Y time that it can now do in p + q = 1 unit of time. So its speed up is p * X + q * Y.

Applying this to the problem you were given: p = q = .5, X=10, Y=1 (no speedup). 10 * (.5) + 1 * (.5) = 5.5

This easily generalizes.

mkrieger1
  • 19,194
  • 5
  • 54
  • 65
Frank Yellin
  • 9,127
  • 1
  • 12
  • 22
0

After optimization, time = x minutes optimized mode + x minutes other = 2x.

Before optimization, time = 10x minutes unoptimized mode + x minutes other = 11x.

Speedup = 11x/2x = 5.5

Matt Timmermans
  • 53,709
  • 3
  • 46
  • 87
0

I love Amdahl's argument, incl. "improvers", so let's start from facts

I will not answer the assignment questions directly, yet will help you learn the know-why, which is to my deepest belief & decades of joy to experience working with the most skilled people the core of what education should promote in our knowledge

( introducing text, decomposed )

A design optimization was applied to a COMPUTER SYSTEM ___ [Fig.1:A]
                      in order
                      to increase the performance
                      of a given
                           EXECUTION MODE_________________ [Fig.1:B]
                      by a FACTOR
                           of 10._________________________ [Fig.1:C]

Fig.1 :

BEFORE  
      +------------------------------------------------------------A: SYSTEM
      |  +----------------------------------------------------B    |
      |  |                                                    |    |
      |  |                                                    |    |
      |  |                                                    |    |
      |  +----------------------------------------------------+    |
      +--:----------------------------------------------------:----+
         :                                                    :
         :                                                    :
         :           C: FACTOR ~ 10 x_________________________/
         :          /
AFTER    :         /
      +--:--------/--A*
      |  +------B*   |
      |  | 10x  |    |
      |  | less |    |
      |  | time |    |
      |  +123456+    |
      +12+------+3456+

D:         in smarter, optimised  "EXECUTION MODE",
  the 50% was duration of the said EXECUTION MODE, whereas
      50% was duration of the original, not modified, part

( ... text continued, decomposed )

The optimized mode is used 50% of the TIME,__________ [FACT Fig.1:D]
                                      measured
                                   as 
                                    a percentage of the execution time
                                AFTER the optimization
                                      has been applied.

( ... first question, decomposed )

  (a) What is the global SPEEDUP value
                                 that is achieved
                                             with ( AFTER )
                                             this optimization?

Remind: Amdahl’s law defines the global speedup as a function of the optimized fraction before the optimization is applied. As a consequence, the 50% ratio cannot be directly used to evaluate this speedup value.

( ... second question )
(b) What is the percentage of the original execution time that is affected by this optimization?

full-A-duration ~  10 x duration-of-B* // == duration-of-B         as was BEFORE
                  + 1 x duration-of-B* // == duration-of-( A - B ) as is
                                       // == duration-of-( A*- B*)    the same
( ref: FACT [Fig.1:D] )

Since here,
the classics apply

--- just do not forget what to compare to what ( and keep in mind, that one and the very same word may bear quite different actual meanings - just compare the original paper with Dr. Gene M. AMDAHL's ( IBM Research ) argument with the E. BARSIS' ( Sandia Natl. Lab.s ) "scaled speedup" and the later John L. GUSTAFSON's presented ( reversed optics or "opposite point of view" ) speedup - all use the same word S-P-E-E-D-U-P, yet their respective definitions differ ( and a lot )


You might like to read the very original, authentic, Dr. Gene M. AMDAHL's paper, to see the actual argument wording as was archived in FAQs, the file is in section "FAQ part 20: IBM and Amdahl", where the paper is on the very bottom of that text ). Alan KARP's price ( and also its winners ) is also a delightful part of this part of the computing history :o)

( ... third, fourth and fifth questions )
(c) How much should such EXECUTION MODE (improving just the block B-to-B* ) be optimized in order to achieve a global speedup of 5?


Can a global speedup
here not restricted to touch only B, so can be smart in improving A-to-A* :P professor will either accept and warmly appreciate your skills and insightful argumentation on doing this, or punish you to dare use crystal-clear logic of the task to the limits the text was not prohibiting us from doing so ;) -- [ SAFETY WARNING ] best not to use this skilled strategy on auto-grader(s) or Artificial-"Intelligence"-powered grading Bots... for obvious reasons these rigid, pre-wired or LSqE-penalised algorithms will hardly award you any extra points for innovative thinking, as thinking is "not included" there, while batteries might 've been, might've been not? )
of 12 be achieved?

And 11?

user3666197
  • 1
  • 6
  • 50
  • 92