Question: Consider the below omp _ trap 1 . c implantation, modify the code so that: i . The time used by the parallel block is
Consider the below omptrapc implantation, modify the code so that: i The time used by the parallel block is timed using the OpenMP function ompgetwtime The syntax is double ompgetwtime void It returns the number of seconds that have elapsed since some time in the past. ii Now on a system with at least two cores, time the program with a one thread and a large value of n and b two threads and the same value of n Explain what happens? Then Do the same measurements for the omptrapc code. How does its performance compare with the performance of the omptrapc Explain your answers. provide with your answers the code and detailed screenshots showing how did you
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
