Advanced Multicore Homework 3 - MPI Programming
The goal of this assignment is to learn basic message passing programming using MPI and
to develop a program using simple partitioning.
For this assignment you are to write programs in either C or C++ using
the MPI message passing libraryP. Your programs must compile without warnings
and execute correctly for full credit. Also, for full credit use good programming
style, including the use of an appropriate amount of comments. In
addition to the source code, your submission must also include the answers
to the questions.
You should run the programs on nodes of gandalf.midearth.cs.kent.edu given by nodes
This will use the gigabit ethernet network.
Instructions for compiling and running on gandalf are given in MPIcommands
-
Implement an algorithm to do a matrix-matrix product C= A*B of a 960x480
matrix A with a 480x960 matrix B of floats, to produce a 960x960 matrix C.
Assume that the matrices A and B have been distributed by block rows, and that the matrix C
is to stored using the same block row distribution. You should generate the entries of A and B in the program and
not include the time for this in any of the timings below.
Time the performance on 2,4 and 8 processors using MPI and the timer function MPI_Wtime()
- of the product itself (not including the redistribution of the columns of B, or the result matrix C
- and of the algorithm including the redistribution of the columns of B, or the result matrix C
One can write the algorithm from scratch or use the matrix-vector multiplication code from
parallel_mat_vect.c
to compute the matrix-matrix product AB by:
for each column of B
{Compute the parallel matrix-vector product Ax}.
Note that this requires the redistribution of the entries of the columns of B so that each processor has
an entire column of B.
Due Date : Tuesday December 8, 2009
Extension Date: Sunday December 13, 2009