Implement and test the OpenMP program for computing a matrix-matrix product (part of the code that computes the matrix-matrix product is given below). Vary the number of threads for 4, 8, 12, 16, 20,...

Implement and test the OpenMP program for computing a matrix-matrix product (part of the code that computes the matrix-matrix product is given below). Vary the number of threads for 4, 8, 12, 16, 20, 24, and 32. You can also use the OMP_NUM_THREADS environment variable to control the number of threads. Run the code for varied number of threads and plot the performance with varying numbers of threads. Consider three cases in which (i) only the outermost loop is parallelized; (ii) the outer two loops are parallelized; and (iii) all three loops are parallelized. What is the observed result from these three cases? Analyze your result. You should submit your c code, your report that includes your plots and analysis. You should submit to [email protected]


Document Preview:

ECE520 ADVANCED TOPICS IN PARALLEL AND DISTRIBUTED COMPUTING Homework 2, Due date: 15/04/2016 Implement and test the OpenMP program for computing a matrix-matrix product (part of the code that computes the matrix-matrix product is given below). Vary the number of threads for 4, 8, 12, 16, 20, 24, and 32. You can also use the OMP_NUM_THREADS environment variable to control the number of threads. Run the code for varied number of threads and plot the performance with varying numbers of threads. Consider three cases in which (i) only the outermost loop is parallelized; (ii) the outer two loops are parallelized; and (iii) all three loops are parallelized. What is the observed result from these three cases? Analyze your result. You should submit your c code, your report that includes your plots and analysis. You should submit to [email protected] #pragmaompparalleldefault(private)shared(a,b,c,dim) num_threads(4) #pragmaompforschedule(static) for(i=0;i<><><>



May 12, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here