[Openmp-commits] [openmp] r322178 - [OMPT] Fix ompt_task_data handling in implicit barriers
Joachim Protze via Openmp-commits
openmp-commits at lists.llvm.org
Wed Jan 10 04:51:27 PST 2018
Author: jprotze
Date: Wed Jan 10 04:51:27 2018
New Revision: 322178
URL: http://llvm.org/viewvc/llvm-project?rev=322178&view=rev
Log:
[OMPT] Fix ompt_task_data handling in implicit barriers
Changes to task_data in barrier-begin were not visible at barrier-end
Differential Revision: https://reviews.llvm.org/D41176
Modified:
openmp/trunk/runtime/src/kmp_barrier.cpp
openmp/trunk/runtime/src/kmp_runtime.cpp
Modified: openmp/trunk/runtime/src/kmp_barrier.cpp
URL: http://llvm.org/viewvc/llvm-project/openmp/trunk/runtime/src/kmp_barrier.cpp?rev=322178&r1=322177&r2=322178&view=diff
==============================================================================
--- openmp/trunk/runtime/src/kmp_barrier.cpp (original)
+++ openmp/trunk/runtime/src/kmp_barrier.cpp Wed Jan 10 04:51:27 2018
@@ -1623,6 +1623,8 @@ void __kmp_join_barrier(int gtid) {
ompt_sync_region_barrier, ompt_scope_begin, my_parallel_data,
my_task_data, codeptr);
}
+ if (!KMP_MASTER_TID(ds_tid))
+ this_thr->th.ompt_thread_info.task_data = *OMPT_CUR_TASK_DATA(this_thr);
#endif
this_thr->th.ompt_thread_info.state = omp_state_wait_barrier_implicit;
}
Modified: openmp/trunk/runtime/src/kmp_runtime.cpp
URL: http://llvm.org/viewvc/llvm-project/openmp/trunk/runtime/src/kmp_runtime.cpp?rev=322178&r1=322177&r2=322178&view=diff
==============================================================================
--- openmp/trunk/runtime/src/kmp_runtime.cpp (original)
+++ openmp/trunk/runtime/src/kmp_runtime.cpp Wed Jan 10 04:51:27 2018
@@ -5669,7 +5669,6 @@ void *__kmp_launch_thread(kmp_info_t *th
__ompt_get_task_info_object(0)->frame.exit_frame = NULL;
this_thr->th.ompt_thread_info.state = omp_state_overhead;
- this_thr->th.ompt_thread_info.task_data = *OMPT_CUR_TASK_DATA(this_thr);
}
#endif
/* join barrier after parallel region */
More information about the Openmp-commits
mailing list