In page 181, the draft says: "The following example(A.13.6c) is the same as the previous one (A.13.5c), except that the tasks are generated in an untied task. "
The example is VERY,VERY, VERY confusing to dumb people like me.
Do you want to say that there are three levels of tasks?
1. an implicit task of "#pragma omp single " with a default tied property
2. an explicit tasks for "#pragma omp task \n process()", and
3. a new level of explicit, untied task added in between, a trick to make a untied task within a tied task.
If my understanding is right, I would expect a more elegant way to express the same idea, allowing "untied" clause to be used with "omp single".
It is not reasonable to only allow the "untied" clause to be used with explicit tasks, and ban its use with implicit tasks like, omp section, omp single, even omp master etc.
----------page 181 : example A.13.5c-------
#pragma omp parallel
{
#pragma omp single
{
int i;
for (i=0; i<LARGE_NUMBER; i++)
#pragma omp task // i is firstprivate, item is shared
process(item[i]);
}
}
}
----------example A.13.6c-------
#pragma omp parallel
{
#pragma omp single
{
int i;
#pragma omp task untied // i is firstprivate, item is shared
{
for (i=0; i<LARGE_NUMBER; i++)
#pragma omp task
process(item[i]);
}
}
}
