summaryrefslogtreecommitdiffstats
path: root/openmp/runtime/src/kmp_csupport.c
diff options
context:
space:
mode:
authorJonas Hahnfeld <Hahnfeld@itc.rwth-aachen.de>2016-03-24 12:52:20 +0000
committerJonas Hahnfeld <Hahnfeld@itc.rwth-aachen.de>2016-03-24 12:52:20 +0000
commite46a494a50561fca91600852da2a3a4e765713bf (patch)
tree888e49cb93425cd81de68ddeea67db84576c27ed /openmp/runtime/src/kmp_csupport.c
parent801fe9bbe2952a189e63ae47e064673b8afd4448 (diff)
downloadbcm5719-llvm-e46a494a50561fca91600852da2a3a4e765713bf.tar.gz
bcm5719-llvm-e46a494a50561fca91600852da2a3a4e765713bf.zip
[OMPT] Fix parallel_id and task_id in loop_end with schedule static
For serialized parallel regions, wrong ids were reported. Now the same code is used as in kmp_dispatch.cpp which emits the correct ids. Differential Revision: http://reviews.llvm.org/D18348 llvm-svn: 264266
Diffstat (limited to 'openmp/runtime/src/kmp_csupport.c')
-rw-r--r--openmp/runtime/src/kmp_csupport.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/openmp/runtime/src/kmp_csupport.c b/openmp/runtime/src/kmp_csupport.c
index 456cb6bbee8..bd048f18f6c 100644
--- a/openmp/runtime/src/kmp_csupport.c
+++ b/openmp/runtime/src/kmp_csupport.c
@@ -1559,13 +1559,10 @@ __kmpc_for_static_fini( ident_t *loc, kmp_int32 global_tid )
#if OMPT_SUPPORT && OMPT_TRACE
if (ompt_enabled &&
ompt_callbacks.ompt_callback(ompt_event_loop_end)) {
- kmp_info_t *this_thr = __kmp_threads[ global_tid ];
- kmp_team_t *team = this_thr -> th.th_team;
- int tid = __kmp_tid_from_gtid( global_tid );
-
+ ompt_team_info_t *team_info = __ompt_get_teaminfo(0, NULL);
+ ompt_task_info_t *task_info = __ompt_get_taskinfo(0);
ompt_callbacks.ompt_callback(ompt_event_loop_end)(
- team->t.ompt_team_info.parallel_id,
- team->t.t_implicit_task_taskdata[tid].ompt_task_info.task_id);
+ team_info->parallel_id, task_info->task_id);
}
#endif
OpenPOWER on IntegriCloud