[Omp] omp parallel sections and omp parallel for what are differences?
Alexander Bubnov
alexander.bubnov at gmail.com
Tue Jul 31 06:12:08 PDT 2007
Hello, all!
I have questions for you.
FIRST CASE:
#pragma omp parallel sections
{
#pragma omp single
func1();
#pragma omp single
func2();
#pragma omp single
func3();
}
SECOND CASE:
{
void (*f[])() = {func1,func2,func2};
#pragma omp parallel for
for(i=0; i<3; ++i)
{
f[i]();
}
}
Are these cases same or different from each other by performance?
Which of them is better and why? Or do they depend on?
--
/BR, Alexander
More information about the Omp
mailing list