Question: Please make sure that you show how the answer should correctly be done for both parts and explain in a separate area how to go

Please make sure that you show how the answer should correctly be done for both parts and explain in a separate area how to go about everything step-by-step
How to solve
(7 points)
(a) Given a program which searches the target data in a sequence of 6 data, assume (l) without knowing the location of the target data, the CPU will examine the data one by one; (ii) the whole program can be executed parallelly and the program will stop immediately once the target data is found; and (iii) the program's running time except data searching can be ignored, please calculate:
(1) If the target data is the 3ro in the sequence, what is the speedup gained by running the program using 2 CPUs over running the program using 1 CPU. Note: by default, the data will be equally dispatched to the CPUs (i.e., CPU 1 processes data 1,2,3: CPU 2 processes data 4,5,6, etc.)
(2) If the target data is the 4th in the sequence, what is the speedup by running the programing using 2 CPUs?
(3) If the target data is the 4In in the sequence, what is the speodup by running the programing using 3 CPUs?
(b) If the program of (a) can be executed completely parallelly, according to the Amdahl's law, what will be the speedup if we run it parallelly using 2 threads (i.e., two processors)? Comparing it with the calculated results of the three cases above, do you see superlinear speedup in any of the three? If yes, which one(s)?
Please make sure that you show how the answer

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!