Answer to Question #198006 in C for Unknown255319

Question #198006

Suppose you need to solve a problem that is comprised of N independent tasks, each of which takes the same time to complete. You want to execute these in parallel using p processing units. However, N is not a multiple of p.


It is suggested that the N tasks can be distributed over the p processing units as follows: p−1 processing units are allocated ⌈N/p⌉ tasks, where ⌈N/p⌉ is N/p rounded up to the nearest integer, and the final processing unit then takes all remaining tasks. What problem or problems can you see with this suggestion?


It is now proposed to allocate the tasks to processes in a ‘round-robin’ manner, cycling through all processing units, allocating one task to each in turn before moving onto the next unit. Provide some pseudo-code for a loop that implements this allocation of tasks.





1
Expert's answer
2021-05-25T13:04:14-0400
Dear chimmpy1010, your question requires a lot of work, which neither of our experts is ready to perform for free. We advise you to convert it to a fully qualified order and we will try to help you. Please click the link below to proceed: Submit order

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS