Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Exercise 1. [ 8 points] Write either a single program or two separate C/C++ programs that use(s) MPI blocking and non-blocking commands MPI_Send, MPI_Rcvd, MPI_Isend

Exercise 1. [ 8 points] Write either a single program or two separate C/C++ programs that use(s) MPI blocking and non-blocking commands MPI_Send, MPI_Rcvd, MPI_Isend and MPI_Ircvd to exchange one double value between process with rank 0 and process with rank 1. Calculate the execution time using MPI_Wtime to compute the execution time and write it down in the table below as follows:

Execution Time

A single transmission using blocking communication

A single transmission using non blocking communication

Two transmissions (round trip) using blocking communication

Two transmissions (round trip) using non blocking communication

Exercise 2. [ 4 points] Modify the ring example given in class to calculate the execution time using MPI_Wtime of the transmission of the value 5 from process with rank 0 to process with rank 1, etc. until the value 5 is received back at the process with rank 0. Use only blocking communication. Launch the execution of the program with a varied number of parallel processes (mpirun -n 10 ./a.out to launch the executable a.out for 10 processes) and write down the execution time of the ring example as follows:

Execution Time

Ring with 4 nodes

Ring with 8 nodes

Ring with 10 nodes

Ring with 12 nodes

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

More Books

Students also viewed these Databases questions