Академический Документы
Профессиональный Документы
Культура Документы
College of engineering
Electrical and computer
Department
Operating system
HW
Threads and Concurrency
Group (b)
4.2: Using Amdahl’s Lawcalculate the speedup gain of an
application that has a 60 percent parallel component for (a) two
processing cores and (b) four processing cores.
Ans
Amdahl’s Law is speedup <= 1 / (S + (1 –S) / N) where S is the portion of the application
that must be performed serially, and N is the number of processing cores.
(a) For 2 processing cores and 60 percent parallel component S is 40 percent or 0.4
and N is 2. So, speedup is <= 1/ (0.4 + (1 –0.4)/2) -> speedup <= 1.428571 ->
Speedup gain is 1.428 times.
(b) For 4 processing cores and 60 percent parallel component S is 40 percent or 0.4
and N is 4. So, speedup is <= 1/ (0.4 + (1 –0.4)/4) -> speedup <= 1.81-> Speedup
gain is 1.81 times.
Concurrency:
Concurrency means where two different tasks or threads start working together in an
overlapped time period, however, it does not mean they run at same instant