Use this forum to discuss the book: Using OpenMP - Portable Shared Memory Parallel Programming, by Barbara Chapman, Gabriele Jost and Ruud van der Pas Read the viewtopic.php?f=8&t=465
for book info and to download the examples. Post your feedback about the book and examples to this forum
in this function omp_get_wtime
For example if two treads A and B, A takes 5 and the other 5 and running at the same time, it will get 5 or 10?
you get two times 5 for the two threads.
It all depends on how you use this function. The most common use is something like this:
- Code: Select all
t_start = omp_get_wtime();
#pragma omp parallel
t_end = omp_get_wtime() - t_start;
That will give you the elapsed time of the parallel region.
Kind regards, Ruud
Return to Using OpenMP - The Book and Examples
Who is online
Users browsing this forum: No registered users and 2 guests