【发布时间】:2012-05-19 10:11:24
【问题描述】:
如果我像这样使用嵌套的并行循环:
#pragma omp parallel for schedule(dynamic,1)
for (int x = 0; x < x_max; ++x) {
#pragma omp parallel for schedule(dynamic,1)
for (int y = 0; y < y_max; ++y) {
//parallelize this code here
}
//IMPORTANT: no code in here
}
这是否等同于:
for (int x = 0; x < x_max; ++x) {
#pragma omp parallel for schedule(dynamic,1)
for (int y = 0; y < y_max; ++y) {
//parallelize this code here
}
//IMPORTANT: no code in here
}
除了创建新任务之外,外部并行是否可以做任何事情?
【问题讨论】:
标签: c++ parallel-processing openmp