我需要做这样的事情
#pragma omp parallel{
#pragma omp for
for_1(){
for_2(){
do_something();
}
#pragma omp barrier //wait for all threads to finish after the inner for
continue_with_something_else_in parallel();
}
}
编译器告诉我我不能在那里设置障碍。有谁知道我该如何解决这个问题?